GitHub30 / win11toast

Toast notifications for Windows 10 and 11 based on WinRT
https://pypi.org/project/win11toast/
MIT License
227 stars 15 forks source link

Support usage of toast function within an existing event loop #35

Closed superleesa closed 6 months ago

superleesa commented 6 months ago

I am using Jupyter Notebook to train some ML models and want to use the toast function to notify when the model finished training. However, when I tried to use it on Jupyter Notebook, I got an error stating "asyncio.run() cannot be called from a running event loop". This error makes sense because your toast function assumes there is no existing event loop, but there is, if I am using Jupyter Notebook / Lab.