[mythtv-users] Runaway CPU when looking up nonexistent episode's metadata
Jan Ceuleers
jan.ceuleers at gmail.com
Sun Apr 18 16:21:04 UTC 2021
On 18/04/2021 17:49, Peter Bennett wrote:
> Thanks for that. However I am more concerned about the endless loop you
> said occurs with a misnumbered episode.
It [1] does that on one of my frontend machines (my laptop). If I hit
Ctrl-C I get the backtrace below. On the backend machine I immediately
get the backtrace I reported earlier.
[1]: /path/to/tmdb3tv.py -l en -a GB -D 873 11 1
$ /usr/share/mythtv/metadata/Television/tmdb3tv.py -l en -a GB -D 873 11 1
^CTraceback (most recent call last):
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
117, in open
return _py23urlopen(self)
File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
return opener.open(url, data, timeout)
File "/usr/lib/python3.6/urllib/request.py", line 532, in open
response = meth(req, response)
File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
'http', request, response, code, msg, hdrs)
File "/usr/lib/python3.6/urllib/request.py", line 570, in error
return self._call_chain(*args)
File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
result = func(*args)
File "/usr/lib/python3.6/urllib/request.py", line 650, in
http_error_default
raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 404: Not Found
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
133, in readJSON
data = json.load(self.open())
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
119, in open
raise TMDBHTTPError(e)
MythTV.tmdb3.tmdb_exceptions.TMDBHTTPError: HTTP Error 404: Not Found
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/share/mythtv/metadata/Television/tmdb3tv.py", line 159, in
<module>
sys.exit(main("television",'tmdb3tv.py'))
File "/usr/share/mythtv/metadata/Television/tmdb3tv.py", line 136, in main
xml = buildEpisode(args[0:3], opts)
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/lookup.py", line
323, in buildEpisode
episode = season.episodes[episode_number]
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/util.py", line 162,
in __get__
self.poller.__get__(inst, owner)()
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/util.py", line 79,
in __call__
if not self.apply(req.readJSON(), False):
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/cache.py", line 117,
in __call__
data = self.func(*args, **kwargs)
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
152, in readJSON
handle_status(data, url)
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
194, in handle_status
raise status
MythTV.tmdb3.tmdb_exceptions.TMDBRequestInvalid: The resource you
requested could not be found.
Error in sys.excepthook:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 140,
in apport_excepthook
crash_counter = get_recent_crashes(f) + 1
File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 262,
in get_recent_crashes
pr.load(report, False, key_filter=['CrashCounter', 'Date'])
File "/usr/lib/python3/dist-packages/problem_report.py", line 168, in load
value += line[1:-1]
KeyboardInterrupt
Original exception was:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
117, in open
return _py23urlopen(self)
File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
return opener.open(url, data, timeout)
File "/usr/lib/python3.6/urllib/request.py", line 532, in open
response = meth(req, response)
File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
'http', request, response, code, msg, hdrs)
File "/usr/lib/python3.6/urllib/request.py", line 570, in error
return self._call_chain(*args)
File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
result = func(*args)
File "/usr/lib/python3.6/urllib/request.py", line 650, in
http_error_default
raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 404: Not Found
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
133, in readJSON
data = json.load(self.open())
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
119, in open
raise TMDBHTTPError(e)
MythTV.tmdb3.tmdb_exceptions.TMDBHTTPError: HTTP Error 404: Not Found
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/share/mythtv/metadata/Television/tmdb3tv.py", line 159, in
<module>
sys.exit(main("television",'tmdb3tv.py'))
File "/usr/share/mythtv/metadata/Television/tmdb3tv.py", line 136, in main
xml = buildEpisode(args[0:3], opts)
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/lookup.py", line
323, in buildEpisode
episode = season.episodes[episode_number]
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/util.py", line 162,
in __get__
self.poller.__get__(inst, owner)()
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/util.py", line 79,
in __call__
if not self.apply(req.readJSON(), False):
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/cache.py", line 117,
in __call__
data = self.func(*args, **kwargs)
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
152, in readJSON
handle_status(data, url)
File "/usr/lib/python3/dist-packages/MythTV/tmdb3/request.py", line
194, in handle_status
raise status
MythTV.tmdb3.tmdb_exceptions.TMDBRequestInvalid: The resource you
requested could not be found.
HTH, Jan
More information about the mythtv-users
mailing list