-
Notifications
You must be signed in to change notification settings - Fork 262
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
Support for upcoming release / main branch #189
Comments
Hey, there's a fork maintaining the 0.11 support: #188 |
@mvlabat @Vrixyz How would one utilize the Vrixyz fork in Cargo.toml?
Is there an example Cargo.toml I look at to understand how to properly specify the right dependencies in the right way? |
I tested against bevyengine/bevy@cdaae01c. If you have more dependencies, you might want to patch rather than specifying the dependency directly: Keep: bevy_egui = "*" But add a patch: [patch.crates-io]
bevy_egui = { git = 'https://github.com/Vrixyz/bevy_egui', branch = 'bevy-main' } I'll update my fork eventually :) edit: I updated the fork against bevy as of 10f5c9206847ae01b8dc833c2680562e7bd46664 |
@Vrixyz fwiw, I'm getting the same error against bevy's main branch with the modifications you referenced
[dependencies]
bevy = { git = "https://github.com/bevyengine/bevy", rev = "10f5c9206847ae01b8dc833c2680562e7bd46664" }
bevy_egui = "*"
# other stuff
[patch.crates-io]
bevy_egui = { git = 'https://github.com/Vrixyz/bevy_egui', branch = 'bevy-main' }
[workspace]
resolver = "2"
# Enable a small amount of optimization in debug mode
[profile.dev]
opt-level = 1
# Enable high optimizations for dependencies (incl. Bevy), but not for our code:
[profile.dev.package."*"]
opt-level = 3 |
Thanks for providing the logs, you're not testing with my latest commit, https://github.com/Vrixyz/bevy_egui?branch=bevy-main#473ceb60 should be https://github.com/Vrixyz/bevy_egui?branch=bevy-main#74c11d35 |
running |
@Vrixyz I'm getting a new error when trying to use the plugin. I tried both the old and new syntax of
Edit: I was using the wrong version of your code, I switched back to the Edit2: @Vrixyz |
Sorry I don't have particular example repository for you to study, you can check the updated examples on my branch though. |
@Vrixyz I believe I have some confusion on my end on how this works. I am able to run: If I try to take the ui.rs code in examples and run with my own Cargo.toml with main.rs, I'll get errors like this:
My My [package]
name = "testegui"
version = "0.1.0"
edition = "2021"
[dependencies]
bevy = { git = "https://github.com/bevyengine/bevy", rev = "10f5c9206847ae01b8dc833c2680562e7bd46664" }
bevy_egui = { git = 'https://github.com/Vrixyz/bevy_egui', rev = "74c11d35469d6ee35279b49a773946f7b638e568" }
[patch.crates-io]
[workspace]
resolver = "2"
[profile.dev]
opt-level = 1
[profile.dev.package."*"]
opt-level = 3 My [target.wasm32-unknown-unknown]
runner = "wasm-server-runner"
[build]
rustflags = ["--cfg=web_sys_unstable_apis"] I don't believe me targeting wasm is an issue here, as my rust analyzer/compiler is complaining. I feel I'm missing a key idea with how dependencies work with rust, perhaps you could help educate on how I can minimumally config a Cargo.toml to run an example independent of the repo? |
From your info, I can reproduce the issue 👍 : I suspected multiple bevy version being used, to make sure I ran: It confirmed my suspicion:
maybe the [package]
name = "testegui"
version = "0.1.0"
edition = "2021"
[dependencies]
bevy = "0.11.0-dev"
bevy_egui = "*"
[patch.crates-io]
bevy = { git = 'https://github.com/bevyengine/bevy.git', branch = 'main' }
bevy_egui = { git = 'https://github.com/Vrixyz/bevy_egui', branch = 'bevy-main' } |
@Vrixyz Thanks for updating this! Using the patch in your post, I get the following error in my project: This is my Cargo.toml:
Any clues? Edit: Solved it. I didn't realize I had to put the patch snippet in the root Cargo.toml. Thanks again for this! |
Released as part of 0.21.0 |
Is there any plans to support 0.11 before it's released?
.add_plugin(EguiPlugin)
doesn't work with the main branch of bevy currently.The text was updated successfully, but these errors were encountered: