Kodi 19 Beta 2, Fedora 33, Python 3.9.0, I'm getting the following when attempting a sync.
2020-12-15 17:24:41.552 T:3080 DEBUG <general>: [script.trakt] resources.lib.service: Dispatch: {'action': 'manualSync', 'silent': False, 'library': 'all'}
2020-12-15 17:24:41.553 T:3080 FATAL <general>: [script.trakt] resources.lib.service: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <type 'AttributeError'>
Error Contents: ("'syncThread' object has no attribute 'isAlive'",)
Traceback (most recent call last):
File "/home/kodi/.kodi/addons/script.trakt/resources/lib/service.py", line 71, in _ dispatch
if not self.syncThread.isAlive():
AttributeError: 'syncThread' object has
I've confirmed that the following code change fixes the issue for me, but I'm not sure how best to avoid breaking backwards compatibility?
diff --git a/resources/lib/service.py b/resources/lib/service.py
index dff7871..757972d 100644
--- a/resources/lib/service.py
+++ b/resources/lib/service.py
@@ -68,7 +68,7 @@ class traktService:
del data['action']
self.doAddToWatchlist(data)
elif action == 'manualSync':
- if not self.syncThread.isAlive():
+ if not self.syncThread.is_alive():
logger.debug("Performing a manual sync.")
self.doSync(
manual=True, silent=data['silent'], library=data['library'])
@@ -132,7 +132,7 @@ class traktService:
del self.Monitor
# check if sync thread is running, if so, join it.
- if self.syncThread.isAlive():
+ if self.syncThread.is_alive():
self.syncThread.join()
def doManualRating(self, data):
https://bugs.python.org/issue37804
Kodi 19 Beta 2, Fedora 33, Python 3.9.0, I'm getting the following when attempting a sync.
I've confirmed that the following code change fixes the issue for me, but I'm not sure how best to avoid breaking backwards compatibility?