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

Fix serde not in scope error. #355

Merged
merged 1 commit into from
Sep 19, 2024

Conversation

brocaar
Copy link
Contributor

@brocaar brocaar commented Sep 19, 2024

As serde is an optional dependency, the #[serde(default)] must be behind a cfg_attr to make sure it is only applied in case the serde feature is enabled.

As serde is an optional dependency, the #[serde(default)] must be behind
a cfg_attr to make sure it is only applied in case the serde feature is
enabled.
@brocaar
Copy link
Contributor Author

brocaar commented Sep 19, 2024

Example error:

    Checking deadpool-redis v0.17.1
error: cannot find attribute `serde` in this scope
  --> /home/brocaar/.cargo/registry/src/index.crates.io-6f17d22bba15001f/deadpool-redis-0.17.1/src/cluster/config.rs:62:7
   |
62 |     #[serde(default)]
   |       ^^^^^

error: could not compile `deadpool-redis` (lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...

@bikeshedder bikeshedder merged commit 685c7a3 into bikeshedder:master Sep 19, 2024
64 checks passed
@bikeshedder
Copy link
Owner

Whopsies! Thank you for the fix! 👍

@bikeshedder
Copy link
Owner

I just released deadpool-redis 0.17.2 at crates.io which includes this fix:

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 this pull request may close these issues.

2 participants