[output] write download progress indicator to stderr
This commit is contained in:
@@ -1,5 +1,7 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## Unreleased
|
||||||
|
|
||||||
## 1.19.3 - 2021-11-27
|
## 1.19.3 - 2021-11-27
|
||||||
### Additions
|
### Additions
|
||||||
- [dynastyscans] add `manga` extractor ([#2035](https://github.com/mikf/gallery-dl/issues/2035))
|
- [dynastyscans] add `manga` extractor ([#2035](https://github.com/mikf/gallery-dl/issues/2035))
|
||||||
|
|||||||
@@ -296,10 +296,10 @@ class TerminalOutput(NullOutput):
|
|||||||
bdl = util.format_value(bytes_downloaded)
|
bdl = util.format_value(bytes_downloaded)
|
||||||
bps = util.format_value(bytes_per_second)
|
bps = util.format_value(bytes_per_second)
|
||||||
if bytes_total is None:
|
if bytes_total is None:
|
||||||
print("\r{:>7}B {:>7}B/s ".format(bdl, bps), end="")
|
sys.stderr.write("\r{:>7}B {:>7}B/s ".format(bdl, bps))
|
||||||
else:
|
else:
|
||||||
print("\r{:>3}% {:>7}B {:>7}B/s ".format(
|
sys.stderr.write("\r{:>3}% {:>7}B {:>7}B/s ".format(
|
||||||
bytes_downloaded * 100 // bytes_total, bdl, bps), end="")
|
bytes_downloaded * 100 // bytes_total, bdl, bps))
|
||||||
|
|
||||||
|
|
||||||
class ColorOutput(TerminalOutput):
|
class ColorOutput(TerminalOutput):
|
||||||
|
|||||||
@@ -6,4 +6,4 @@
|
|||||||
# it under the terms of the GNU General Public License version 2 as
|
# it under the terms of the GNU General Public License version 2 as
|
||||||
# published by the Free Software Foundation.
|
# published by the Free Software Foundation.
|
||||||
|
|
||||||
__version__ = "1.19.3"
|
__version__ = "1.20.0-dev"
|
||||||
|
|||||||
Reference in New Issue
Block a user