-
Notifications
You must be signed in to change notification settings - Fork 118
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
Asynchronous idle #194
Comments
@aurieh just as a comment - I'm using PySide2 (Qt5 for now) and asyncio and python-mpd2 quite happily with https://github.com/CabbageDevelopment/qasync Overall I don't find it at all burdensome to use asyncio with Qt (it actually fits very nicely indeed) The reason I'm here btw is because I've started an asyncio listen task (on a QObject method):
But sometimes I lose the mpd connection and the async mdp.idle() does not notice and therefore does not exit allow a reconnection to occur. |
In the asyncio variant usually after a timeout, the library switches to an "idle" mode: Line 302 in 9161f30
This is to prevent MPD from closing the connection, which it does if there is no activity. |
But it is unclear to me why "idle()" doesn't pick up if the connection is lost. |
OK, old thread I know but on a related topic... |
Please forget/forgive my previous comment/query. |
Is there still a way to, without going through private APIs, send the
idle
command and not wait for its results? The docs mentionsend_idle
/fetch_idle
, but I see the support for them was deprecated in f3864ac and removed in 3a73454. The changelog lists asyncio and twisted as alternatives, but these are not an option for us as we're already dealing with the Qt event loop: pulling in asyncio on top would be a tremendous burden.The text was updated successfully, but these errors were encountered: