Introduced Trouble(Exception) for more elegant non-fatal errors handling
This commit is contained in:
parent
3fe294e4ef
commit
0b8c922da9
2 changed files with 30 additions and 24 deletions
|
@ -290,6 +290,13 @@ class ContentTooShortError(Exception):
|
|||
self.expected = expected
|
||||
|
||||
|
||||
class Trouble(Exception):
|
||||
"""Trouble helper exception
|
||||
|
||||
This is an exception to be handled with
|
||||
FileDownloader.trouble
|
||||
"""
|
||||
|
||||
class YoutubeDLHandler(urllib2.HTTPHandler):
|
||||
"""Handler for HTTP requests and responses.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue