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: Derive macro requiring backend crate as dependency #30

Merged
merged 1 commit into from
Apr 23, 2023

Conversation

MrGVSV
Copy link
Owner

@MrGVSV MrGVSV commented Apr 23, 2023

Problem

Fixes a bug found by @Tsudico on Discord:

I'm trying to figure out the basic schematic example. It runs as an example in a cloned bevy_proto, but when I copy the code into a new project it fails with the following error for any derived Schematic:

message: bevy_proto_backend is present in Cargo.toml: CrateNotFound { crate_name: "bevy_proto_backend", path: "f:\Repositories\rust\projects\bevy_proto_test\Cargo.toml" }

Cargo.toml has this under dependencies:

[dependencies]
bevy = "0.10.1"
bevy_proto = "0.8"

Am I missing something in the Cargo.toml?

Solution

Since bevy_proto and bevy_proto_backend need to use the derive macro, we can't just use a feature to swap between sources. Instead, we search for one and then the other if not found.

Since this is a very problematic bug that makes bevy_proto unusable (at least, the macros), I'm going to publish this version right away and yank the previous version.

Unverified

This user has not yet uploaded their public signing key.
@MrGVSV MrGVSV merged commit 5701889 into main Apr 23, 2023
@MrGVSV MrGVSV deleted the fix-derive-backend-dependency branch April 23, 2023 22:04
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.

None yet

1 participant