You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I created a project that displays a Windows toast notification. When I run my code in PyCharm, the script executes normally until completion. After compiling using PyInstaller and running the generated exe, I get an error for one of the 'winrt' imports:
Traceback (most recent call last):
File "notification.py", line 1, in<module>
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
File "PyInstaller\loader\pyimod03_importers.py", line 546, in exec_module
File "message.py", line 1, in<module>
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
File "PyInstaller\loader\pyimod03_importers.py", line 546, in exec_module
File "winrt\__init__.py", line 4, in<module>
RuntimeError: Cannot change thread mode after it is set.
[9720] Failed to execute script 'notification' due to unhandled exception!
I created a project that displays a Windows toast notification. When I run my code in PyCharm, the script executes normally until completion. After compiling using PyInstaller and running the generated exe, I get an error for one of the 'winrt' imports:
My imports for 'winrt' are:
If anyone one knows why I get this error, I would appreciate any help!
The text was updated successfully, but these errors were encountered: