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

Deprecate and remove insert_or_spawn_batch #15704

Open
alice-i-cecile opened this issue Oct 7, 2024 · 0 comments
Open

Deprecate and remove insert_or_spawn_batch #15704

alice-i-cecile opened this issue Oct 7, 2024 · 0 comments
Labels
A-ECS Entities, components, systems, and events C-Usability A targeted quality-of-life change that makes Bevy easier to use D-Straightforward Simple bug fixes and API improvements, docs, test and examples M-Needs-Migration-Guide A breaking change to Bevy's public API that needs to be noted in a migration guide S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it! X-Contentious There are nontrivial implications that should be thought through

Comments

@alice-i-cecile
Copy link
Member

Just like in #15459 / #15652 for get_or_spawn, insert_or_spawn_batch is an anti-pattern: it uses entity IDs in a non-opaque way, attempting to assign specific meaning to certain entities. With the retained rendering world in place, we should remove it to discourage this pattern and enforce the ECS invariants more strongly.

#15702 should be merged first, to ensure that the migration path for the non-footgunny part of this API is smooth.

@alice-i-cecile alice-i-cecile added A-ECS Entities, components, systems, and events M-Needs-Migration-Guide A breaking change to Bevy's public API that needs to be noted in a migration guide C-Usability A targeted quality-of-life change that makes Bevy easier to use D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Blocked This cannot move forward until something else changes X-Contentious There are nontrivial implications that should be thought through labels Oct 7, 2024
@BenjaminBrienen BenjaminBrienen added S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it! and removed S-Blocked This cannot move forward until something else changes labels Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-ECS Entities, components, systems, and events C-Usability A targeted quality-of-life change that makes Bevy easier to use D-Straightforward Simple bug fixes and API improvements, docs, test and examples M-Needs-Migration-Guide A breaking change to Bevy's public API that needs to be noted in a migration guide S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it! X-Contentious There are nontrivial implications that should be thought through
Projects
None yet
Development

No branches or pull requests

2 participants