Deprecated `Interaction` component cannot be used in 0.20.
Maintainers usually reply within 2 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 72/100
Research direction
The error points at the bevy::bevy_ui::focus module, so read the type declaration of DeprecatedInteraction in crates/bevy_ui/src/focus.rs and the deprecated pub use alias that re-exports it as Interaction (check the module's mod.rs/lib.rs exports). Making the underlying struct pub while keeping #[deprecated] should turn the hard compile error into a warning; confirm with cargo check -p bevy_ui and a small crate that queries Interaction. Done means downstream code using the deprecated name compiles with a deprecation warning rather than a private-type error.
Written by the indexing model from the issue text.
Description
Despite the fact that the Interaction component was deprecated (not removed) in 0.20, it isn't really possible to use. If I have a system that names Interaction, I get the following error:
error: type `bevy::bevy_ui::focus::DeprecatedInteraction` is private
--> crates/bevy_rerecast_editor/src/theme/interaction.rs:5:5
|
5 | app.add_systems(Update, apply_interaction_palette);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ private type
error: type `bevy::bevy_ui::focus::DeprecatedInteraction` is private
--> crates/bevy_rerecast_editor/src/theme/interaction.rs:21:24
|
21 | mut palette_query: Query<
| ________________________^
22 | | (
23 | | &Interaction,
24 | | &InteractionPalette,
... |
28 | | Or<(Changed<Interaction>, Changed<Pickable>)>,
29 | | >,
| |_____^ private type
So we should either make this type pub (and deprecated) so that the deprecation actually works (instead of being a hard error), or we should just delete this type entirely and force a migration.
- Dominant language
- Rust
- Stars
- 49.2k
- Forks
- 5k
- Avg merge
- 3d 11h
- Merged PRs (30d)
- 136
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from bevyengine/bevy
-
A-Camera C-Docs D-Straightforward S-Ready-For-Implementation
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
bevyengine/bevy#26309 ·
Maintainers usually reply within 2 days
-
A-Rendering C-Bug C-Performance S-Ready-For-Implementation
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
bevyengine/bevy#26283 · 3 comments ·
Maintainers usually reply within 2 days
-
A-Dev-Tools C-Bug D-Straightforward S-Ready-For-Final-Review X-Uncontroversial
Difficulty 1/5 Under an hour Newbie friendliness 87/100
bevyengine/bevy#26275 · 1 comment ·
Maintainers usually reply within 2 days
-
Feathers number input keeps its editing text when editing ends without a changePossibly taken @femii1234 claimed this 2 days ago. OpenA-UI C-Bug D-Trivial S-Needs-Review
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
bevyengine/bevy#26202 · 1 comment ·
Maintainers usually reply within 2 days
-
C-Feature S-Needs-Triage
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
bevyengine/bevy#26153 ·
Maintainers usually reply within 2 days
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 67/100
rust-bitcoin/rust-bitcoin#7089 · 1 comment · 1 reaction ·
Maintainers usually reply within 2 days
-
area/tools bug session-analysis
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
[Bug]: Python OpenTelemetrySectionConfig has no file_sinksMay be free again A pull request for this issue was closed without being merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
NVIDIA/NeMo-Relay#1514 ·
Maintainers usually reply within 1 day
-
prompting proposal tool triaged
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
can1357/oh-my-pi#17041 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 84/100
nix-community/fenix#262 ·