Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile error in 0.11.0 #121

Closed
Jake-Shadle opened this issue Jul 28, 2020 · 3 comments · Fixed by #122
Closed

Compile error in 0.11.0 #121

Jake-Shadle opened this issue Jul 28, 2020 · 3 comments · Fixed by #122

Comments

@Jake-Shadle
Copy link
Contributor

Getting an extremely strange compile error, strange as in it seems it should happen all of the time, but only happens when this crate is a transitive dependency?

error[E0252]: the name `Deserialize` is defined multiple times
 --> /home/jake/.cargo/registry/src/github.com-1ecc6299db9ec823/cargo_metadata-0.11.0/src/dependency.rs:5:20
  |
4 | use serde::{Deserialize, Deserializer};
  |             ----------- previous import of the macro `Deserialize` here
5 | use serde_derive::{Deserialize, Serialize};
  |                    ^^^^^^^^^^^--
  |                    |
  |                    `Deserialize` reimported here
  |                    help: remove unnecessary import
  |
  = note: `Deserialize` must be defined only once in the macro namespace of this module

This error seems to be completely valid, but doesn't appear when you just compile this crate alone or when it's a direct depdency, as far as I can tell.

I'll open up a PR to fix it.

@oli-obk
Copy link
Owner

oli-obk commented Jul 28, 2020

ooh... yea, this happens when some other crate in the dep graph enables the derive feature of serde

@oli-obk
Copy link
Owner

oli-obk commented Jul 28, 2020

I yanked 0.11 and published 0.11.1

@Jake-Shadle
Copy link
Contributor Author

Great, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants