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

Implement game generation timeout #18

Open
SteffenBauer opened this issue May 14, 2021 · 2 comments
Open

Implement game generation timeout #18

SteffenBauer opened this issue May 14, 2021 · 2 comments
Labels
enhancement New feature or request

Comments

@SteffenBauer
Copy link
Owner

As reported by TZornG in #17 , Puzzles with custom game parameters might not be possible for certain parameter values; causing the app to hang in an infinite loop. The app must then be terminated manually via the task manager, which is quite bad.

To be checked how to introduce a timeout; either directly in the generation loop of every game; or high-level by moving game generation to a separate thread. Quick-fix is to introduce more parameter limitation checks in affected puzzles.

@SteffenBauer SteffenBauer added the enhancement New feature or request label May 14, 2021
@Skeeve
Copy link

Skeeve commented Sep 18, 2023

Is there really a loop? Can't it just check on each iteration the time passed and bail out if it was too long?

@SteffenBauer
Copy link
Owner Author

SteffenBauer commented Sep 18, 2023

(edit) Introducing a check inside game generation might be possible, but would take modifying every single game. Furthermore, for certain game parameters even a single generator loop might be too long.

I'm thinking of displaying a button during game generation where pressing it will cancel the game generator. Putting game generation into a thread might be the better solution here, but this is technically more challenging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants