aboutsummaryrefslogtreecommitdiffstats
path: root/youtube_dlc/postprocessor/xattrpp.py
diff options
context:
space:
mode:
authorpukkandan <pukkandan@gmail.com>2021-01-10 19:14:54 +0530
committerpukkandan <pukkandan@gmail.com>2021-01-10 22:22:24 +0530
commitf446cc66675629d3e043800d9ce74d3327f9fdfa (patch)
tree80c00c707c1404d088c1d5ded88248f69567243c /youtube_dlc/postprocessor/xattrpp.py
parentebdd9275c3e65b558125381a00fd77b0a8c2ce73 (diff)
downloadhypervideo-pre-f446cc66675629d3e043800d9ce74d3327f9fdfa.tar.lz
hypervideo-pre-f446cc66675629d3e043800d9ce74d3327f9fdfa.tar.xz
hypervideo-pre-f446cc66675629d3e043800d9ce74d3327f9fdfa.zip
Create `to_screen` and similar functions in postprocessor/common
`to_screen`, `report_warning`, `report_error`, `write_debug`, `get_param` This is a first step in standardizing these function. This has to be done eventually for extractors and downloaders too
Diffstat (limited to 'youtube_dlc/postprocessor/xattrpp.py')
-rw-r--r--youtube_dlc/postprocessor/xattrpp.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/youtube_dlc/postprocessor/xattrpp.py b/youtube_dlc/postprocessor/xattrpp.py
index 85834db45..3d31f0ce5 100644
--- a/youtube_dlc/postprocessor/xattrpp.py
+++ b/youtube_dlc/postprocessor/xattrpp.py
@@ -57,16 +57,16 @@ class XAttrMetadataPP(PostProcessor):
return [], info
except XAttrUnavailableError as e:
- self._downloader.report_error(str(e))
+ self.report_error(str(e))
return [], info
except XAttrMetadataError as e:
if e.reason == 'NO_SPACE':
- self._downloader.report_warning(
+ self.report_warning(
'There\'s no disk space left, disk quota exceeded or filesystem xattr limit exceeded. '
+ (('Some ' if num_written else '') + 'extended attributes are not written.').capitalize())
elif e.reason == 'VALUE_TOO_LONG':
- self._downloader.report_warning(
+ self.report_warning(
'Unable to write extended attributes due to too long values.')
else:
msg = 'This filesystem doesn\'t support extended attributes. '
@@ -74,5 +74,5 @@ class XAttrMetadataPP(PostProcessor):
msg += 'You need to use NTFS.'
else:
msg += '(You may have to enable them in your /etc/fstab)'
- self._downloader.report_error(msg)
+ self.report_error(msg)
return [], info