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

dbus_utils.py: adjust use of get_event_loop for its deprecation #329

Merged
merged 1 commit into from
Jan 29, 2025

Conversation

antonlacon
Copy link
Contributor

@antonlacon antonlacon commented Jan 26, 2025

This is my understanding of what the addon needs for Python 3.13: LibreELEC/LibreELEC.tv#9374

asyncio.get_event_loop() raises a RuntimeError if there isn't a loop running when it's called. This handles that error by creating a loop when it doesn't find one.

This is my best guess at the correct thing to do. I'm not familiar with asyncio. However, the addon Works For Me.

Copy link
Contributor

@heitbaum heitbaum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have tested and it works for me too with 3.13.1, makes sense based on https://docs.python.org/3/library/asyncio-eventloop.html

@heitbaum
Copy link
Contributor

@antonlacon
Copy link
Contributor Author

Sounds reasonable.

@heitbaum heitbaum merged commit 1eaa10a into LibreELEC:master Jan 29, 2025
@antonlacon antonlacon deleted the py313-compat branch February 4, 2025 08:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants