Skip to content

lambda_http isn't compatible with serde features = ["derive"] #102

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

Closed
iliana opened this issue Apr 29, 2019 · 2 comments
Closed

lambda_http isn't compatible with serde features = ["derive"] #102

iliana opened this issue Apr 29, 2019 · 2 comments

Comments

@iliana
Copy link

iliana commented Apr 29, 2019

Current documentation instructs users of Serde to use the derive feature in Cargo.toml:

serde = { version = "1.0", features = ["derive"] }

This is incompatible with lambda_http which uses separate serde and serde_derive crates.

error[E0252]: the name `Deserialize` is defined multiple times
  --> /home/ilianaw/.cargo/registry/src/git.colasdn.top-1ecc6299db9ec823/lambda_http-0.1.0/src/request.rs:17:5
   |
15 |     Deserialize, Deserializer,
   |     ----------- previous import of the macro `Deserialize` here
16 | };
17 | use serde_derive::Deserialize;
   | ----^^^^^^^^^^^^^^^^^^^^^^^^^-
   | |   |
   | |   `Deserialize` reimported here
   | help: remove unnecessary import
   |
   = note: `Deserialize` must be defined only once in the macro namespace of this module

error: aborting due to previous error

For more information about this error, try `rustc --explain E0252`.
error: Could not compile `lambda_http`.

If a user switches back to the old serde_derive crate, lambda_http successfully builds.

serde = "1.0"
serde_derive = "1.0"
@softprops
Copy link
Contributor

Hi @iliana! Long time no see :)

This may be related to #97 I believe there's an incompatibility that may be fixed with a publish of lambda_http mentioned in #97 (comment)

cc @davidbarsky

@iliana
Copy link
Author

iliana commented May 11, 2019

This seems to be fixed with the most recent release (#103).

@iliana iliana closed this as completed May 11, 2019
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

No branches or pull requests

2 participants