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

Introduce an app::run_system_set() function #12717

Open
cBournhonesque opened this issue Mar 25, 2024 · 3 comments · May be fixed by #12726 or #13219
Open

Introduce an app::run_system_set() function #12717

cBournhonesque opened this issue Mar 25, 2024 · 3 comments · May be fixed by #12726 or #13219
Labels
A-ECS Entities, components, systems, and events C-Enhancement A new feature

Comments

@cBournhonesque
Copy link
Contributor

cBournhonesque commented Mar 25, 2024

What problem does this solve or what need does it fill?

For testing or benchmarking purposes, I would like to run a bunch of systems of my App that are all in the same SystemSet.
Bevy currently provides a function app.run_schedule(schedule) and app.run_system() (for registered one-shot systems) but there is no helper to run an entire system set.

What solution would you like?

Have an api app.run_system_set(schedule_name, system_set_name) which runs all the systems inside a SystemSet once.

What alternative(s) have you considered?

I could try to put all those systems in a separate Schedule, but:

  • from what I understand, two schedules cannot run in parallel, and I would like those systems to run in parallel with other PostUpdate systems
  • it would be a big refactoring of my app to just gain some testing capabilities
@cBournhonesque cBournhonesque added C-Enhancement A new feature A-ECS Entities, components, systems, and events S-Needs-Triage This issue needs to be labelled labels Mar 25, 2024
@alice-i-cecile alice-i-cecile removed the S-Needs-Triage This issue needs to be labelled label Mar 25, 2024
@alice-i-cecile
Copy link
Member

I'm on board with this feature. It's calling convention should mirror the run_schedule API.

@ItsDoot
Copy link
Contributor

ItsDoot commented Mar 26, 2024

How would this work with regards to individual systems that have ordering constraints outside the specified system set? Should they be ignored, or should it include all of them? Currently feels like a footgun to me when app.run_schedule() is an option.

@cBournhonesque
Copy link
Contributor Author

It would just skip any system that is not in the SystemSet.
It seems strange to me that i'm forced to create a different schedule just to test run a subpart of my app

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-Enhancement A new feature
Projects
None yet
3 participants