-
-
Notifications
You must be signed in to change notification settings - Fork 4k
Re-export uuid crate to use bevy_reflect's uuid version #18723
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
base: main
Are you sure you want to change the base?
Conversation
Welcome, new contributor! Please make sure you've read our contributing guide and we look forward to reviewing your pull request shortly ✨ |
Note to maintainers: please feel free to shuffle things around if the final-resting place of my changes is not preferred. I am not married to any of these changes, I just wanted the dependency fix on my end, that's all :) |
uuid 1.16 is semver compatible with uuid 1.13, cargo does version unification between the twos and uses uuid 1.16 having as dependencies:
compiles fine for me, and uses uuid 1.16. Could you share more about your other dependencies? |
My deps, only using uuid = { version = "~1.16", features = ["v4"] }
bevy_ecs = "~0.15"
bevy_time = "~0.15" I moved some code around and just imported However, this still doesnt solve the core part of the problem. In a scenario where I want: uuid = { version = "0.9", features = ["v4"] }
bevy = "0.16.0-rc.3" Because my project needs a specific
And this is solely because when using the
and it uses the parent crates
So yes: the temporary fix is for me to use And I'm not even using |
Objective
uuid
dependency inbevy_reflect
call herebevy/crates/bevy_reflect/src/impls/uuid.rs
Line 4 in 78d5c50
::uuid
, which is the parents crateuuid
crate version, rather than I assume the intendeduuid
version defined herebevy/crates/bevy_reflect/derive/Cargo.toml
Line 26 in 78d5c50
As a result,
rust-analyzer
for a project which requiresuuid = "~1.16"
:Solution
uuid
definitions out ofbevy_reflect/derive/Cargo.toml
(since they do nothing here) tobevy_reflect/Cargo.toml
pub use uuid
tobevy_reflect::__macro_exports
impl_reflect_opaque!(::uuid::Uuid(
call toimpl_reflect_opaque!(::bevy_reflect::__macro_exports::uuid::Uuid(
Testing
bevy_reflect
without errorsuuid = "~1.16"
without therust-analyzer
message see above:bevy
expert, I just wanted to fix this dependency issue, so I would prefer more testing, but I did run the following:bevy
usingcargo test --doc --workspace
: all passedbevy_reflect
usingcargo test --doc
: all passedbevy_reflect
usingcargo test
: all passedbevy_reflect
tests I didnt see any tests for it, so I would rather have someone triple-check