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

Replace Printer's boolean flags with threading.Event #146

Open
CRImier opened this issue Nov 29, 2018 · 0 comments
Open

Replace Printer's boolean flags with threading.Event #146

CRImier opened this issue Nov 29, 2018 · 0 comments
Labels
good first issue New contributors should be able to tackle this help wanted reliability

Comments

@CRImier
Copy link
Member

CRImier commented Nov 29, 2018

Printer.skip_screen_flag = False #A flag which is set for skipping screens and is polled while printer is displaying things

This solution is old. Now I see that:

  • Any simultaneously running Printers will probably interfere
  • It's not thread-safe - so, we might miss the changes when the CPU load is too high (as it used to happen with Refreshers and other UI elements).

We can use threading.Event instead, just like we do in BaseUIElements.

@CRImier CRImier added help wanted reliability good first issue New contributors should be able to tackle this labels Nov 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue New contributors should be able to tackle this help wanted reliability
Projects
None yet
Development

No branches or pull requests

1 participant