mirror of
https://github.com/unshackle-dl/unshackle.git
synced 2026-11-27 03:15:08 +00:00
fix(remote): report a missing title list and a refused track URI clearly
A service returning no titles now fails with a service error instead of an unsupported "other" title, and the init segment read names the HTTP status.
This commit is contained in:
@@ -1095,6 +1095,9 @@ class Track:
|
||||
else:
|
||||
init_data = None
|
||||
s = session.get(url, stream=True)
|
||||
if not s.ok:
|
||||
s.close()
|
||||
raise ValueError(f"Track URI returned HTTP {s.status_code}")
|
||||
for chunk in s.iter_content(content_length):
|
||||
init_data = chunk
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user