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

Schedule causes a panic when run criteria returns NoAndCheckAgain #3144

Closed
vmednis opened this issue Nov 17, 2021 · 2 comments
Closed

Schedule causes a panic when run criteria returns NoAndCheckAgain #3144

vmednis opened this issue Nov 17, 2021 · 2 comments
Labels
A-ECS Entities, components, systems, and events C-Bug An unexpected or incorrect behavior S-Needs-Investigation This issue requires detective work to figure out what's going wrong

Comments

@vmednis
Copy link

vmednis commented Nov 17, 2021

Bevy version

0.5.0, looking at the code still happens at main

Operating system & version

N/A will happen on all Operating Systems

What you did

Had a run criteria returning NoAndCheckAgain in some cases on a Schedule

What you expected to happen

I expected the run criteria to be reevaluated immediately

What actually happened

The code panicked

Additional information

The panic is raised in bevy_ecs/src/schedule/mod.rs with text "NoAndCheckAgain would loop infinitely in this situation.". I believe that this is an incorrect assumption as the state may be modified (in my case I change a resource) by the run criteria and go down a different code path on the rerun of it. This would make some code easier to read.

@vmednis vmednis added C-Bug An unexpected or incorrect behavior S-Needs-Triage This issue needs to be labelled labels Nov 17, 2021
@alice-i-cecile alice-i-cecile added A-ECS Entities, components, systems, and events S-Needs-Investigation This issue requires detective work to figure out what's going wrong and removed S-Needs-Triage This issue needs to be labelled labels Nov 17, 2021
@alice-i-cecile
Copy link
Member

Related to #2841.

@james7132
Copy link
Member

With stageless merged, run conditions no longer return an enum but a single boolean. Closing as this issue is no longer actionable.

@james7132 james7132 closed this as not planned Won't fix, can't repro, duplicate, stale Feb 16, 2023
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-Bug An unexpected or incorrect behavior S-Needs-Investigation This issue requires detective work to figure out what's going wrong
Projects
None yet
Development

No branches or pull requests

3 participants