davidhewitt / pythonize

MIT License
200 stars 27 forks source link

Not all trait items implemented, missing: `collect_str` #8

Closed kivo360 closed 3 years ago

kivo360 commented 3 years ago

When trying to install pythonize I run into the error:

    Blocking waiting for file lock on build directory
   Compiling pyo3 v0.12.4
   Compiling pyo3 v0.12.4 (https://github.com/PyO3/pyo3#92b7a973)
   Compiling pythonize v0.12.0
 error[E0046]: not all trait items implemented, missing: `collect_str`
  --> /home/***/.cargo/registry/src/github.com-1ecc6299db9ec823/pythonize-0.12.0/src/ser.rs:49:1
   |
49 | impl<'py> ser::Serializer for Pythonizer<'py> {
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `collect_str` in implementation
   |
   = help: implement the missing item: `fn collect_str<T>(self, _: &T) -> std::result::Result<<Self as Serializer>::Ok, <Self as Serializer>::Error> where T: std::fmt::Display { todo!() }`

What could be the source of this problem?

davidhewitt commented 3 years ago

Thanks @kivo360 for the bug report. I think pythonize will require the std feature of serde but by accident does not enable it. I will soon release pythonize 0.12.1 which will contain a fix for this.