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

Issue a warning when using threads #180

Closed
fmagin opened this issue Dec 19, 2020 · 1 comment
Closed

Issue a warning when using threads #180

fmagin opened this issue Dec 19, 2020 · 1 comment

Comments

@fmagin
Copy link

fmagin commented Dec 19, 2020

Talon has excellent support for reloading plugins on change as long as threads aren't used. If threads are used this doesn't work well anymore and a warning making this explicit could prevent confusion and possibly direct to the appropriate documentation to implement the desired behavior in a way that still works well with the reloading support.

@lunixbochs
Copy link

In next beta:

2020-12-24 15:10:31 WARNING User script 'repl' started a thread.
User threads do not have resource tracking or autoreload support.
   13:    lib/python3.9/threading.py:912| 
   12:    lib/python3.9/threading.py:954| 
   11:    lib/python3.9/threading.py:892| 
   10: lib/python3.9/socketserver.py:650| 
    9: lib/python3.9/socketserver.py:360| 
    8: lib/python3.9/socketserver.py:720| 
    7:      talon_plugins/00_repl.py:198| shell.interact()
    6:      talon_plugins/00_repl.py:156| more = self.push(m['text'])
    5:         lib/python3.9/code.py:258| 
    4:         lib/python3.9/code.py:74 | 
    3:         lib/python3.9/code.py:90 | 
    2:                     <console>:1  | 
    1:    lib/python3.9/threading.py:874| 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants