-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
BRP strict field in query #16725
BRP strict field in query #16725
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice addition! 👍
- Maybe we should also change the response to a
Lenient
/Strict
enum, witherrors
list included for the Lenient response. That way the client is not kept in the dark about any skipped components. (look atbevy/get
) - Documentation needs to be updated as well.
It looks like your PR is a breaking change, but you didn't provide a migration guide. Could you add some context on what users should update when this change get released in a new version of Bevy? |
@alice-i-cecile is there anything missing now? |
Objective
bevy/query
request.Solution
Testing
My naive approach boils down to:
Before that change I end up with bunch of
Component xxx isn't used in the world
because some of the components wasn't spawned at any moment yet in the game. Now it should work.Migration Guide
BrpQueryParams
now hasstrict
boolean field. It serfs as a flag to fail when encountering an invalid component rather than skipping it. Defaults to false.