Closed waymost closed 7 years ago
No problem! Regarding your comment in the serde issue you referenced, I think the problem in this instance is the difference in semantics stemming from the rust and python type systems.
You're right that it's a bit of a gotcha for b"12345"
to convert to a python tuple not list. Fortunately, the fix is relatively simple as b"12345".to_vec()
returns a Vec<u8>
, which then results in a list on the python side.
Thanks for the patch! I was working on this as well, but hit an annoyance with respect to tuples/lists, see https://github.com/serde-rs/serde/issues/883#issuecomment-299778813. It seems that this is intentional, so I'll add a warning to the docs and merge this.