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

[rust] figure out how to deal with serde-derive #19362

Closed
nbdd0121 opened this issue Aug 4, 2023 · 1 comment · Fixed by #19581
Closed

[rust] figure out how to deal with serde-derive #19362

nbdd0121 opened this issue Aug 4, 2023 · 1 comment · Fixed by #19581

Comments

@nbdd0121
Copy link
Contributor

nbdd0121 commented Aug 4, 2023

Description

In #19203 it was discovered that serde-derive 1.0.172 starts to use precompiled binary, but the precompiled file is not considered as data file in Rust rules, so Bazel excludes them from sandbox.

There is some ways to fix it:

  1. Pin serde-derive to 1.0.171, which is the last version without precompiled binary
  2. Patch serde-derive to remove precompiled binary (see using serde_derive without precompiled binary serde-rs/serde#2538, there is also a patch in the comments by Fedora people)
  3. Add data_attr so that the precompiled binary can be used (e.g. https://github.com/google/cargo-raze/blob/afe9b483b0449eb043f3fa8aa08f62afffcfa2ed/impl/Cargo.toml#L138)
  4. (?) Wait until a solution is provided by serde-derive to not use precompiled binary?

Personally I don't like the idea of depending on a precompiled binary, so I don't want to pursue (3). For now I opted for (1) in #19203.

@jwnrt
Copy link
Contributor

jwnrt commented Aug 21, 2023

The precompiled binary has been removed in serde_derive 1.0.184.

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