-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Missing migration: mention features to enable for reflection registration to work #21092
Copy link
Copy link
Closed
Labels
A-ReflectionRuntime information about typesRuntime information about typesC-DocsAn addition or correction to our documentationAn addition or correction to our documentationD-StraightforwardSimple bug fixes and API improvements, docs, test and examplesSimple bug fixes and API improvements, docs, test and examplesM-Migration-GuideA breaking change to Bevy's public API that needs to be noted in a migration guideA breaking change to Bevy's public API that needs to be noted in a migration guideS-Ready-For-ImplementationThis issue is ready for an implementation PR. Go for it!This issue is ready for an implementation PR. Go for it!
Milestone
Description
What problem does this solve or what need does it fill?
Porting Tnua, I got this:
thread 'main' (253822) panicked at /home/hhh/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/bevy_scene-0.17.0-rc.1/src/scene_spawner.rs:621:35:
scene contains the unregistered type `bevy_transform::components::transform::Transform`. consider reflecting it with `#[derive(Reflect)]` and registering the type using `app.register_type::<T>()`
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_scene::scene_spawner::scene_spawner_system`!
Encountered a panic in system `bevy_app::main_schedule::Main::run_main`!
error: command `cargo run --bin platformer_3d --features avian3d,bevy/debug --profile dev` exited with status code exit status: 101
This happened because bevy_tnua depends on Bevy without default features enabled. Turns out you need to enable reflect_auto_register for that to work. Also, the new reflect_auto_register_static feature is not mentioned either.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
A-ReflectionRuntime information about typesRuntime information about typesC-DocsAn addition or correction to our documentationAn addition or correction to our documentationD-StraightforwardSimple bug fixes and API improvements, docs, test and examplesSimple bug fixes and API improvements, docs, test and examplesM-Migration-GuideA breaking change to Bevy's public API that needs to be noted in a migration guideA breaking change to Bevy's public API that needs to be noted in a migration guideS-Ready-For-ImplementationThis issue is ready for an implementation PR. Go for it!This issue is ready for an implementation PR. Go for it!