mirror of
https://github.com/httpie/cli.git
synced 2025-03-13 14:28:50 +01:00
Fix average download speed (httpie#1516)
This commit is contained in:
parent
30a6f73ec8
commit
939e77476d
@ -105,7 +105,7 @@ class ProgressDisplay(BaseDisplay):
|
|||||||
TimeRemainingColumn,
|
TimeRemainingColumn,
|
||||||
TransferSpeedColumn,
|
TransferSpeedColumn,
|
||||||
)
|
)
|
||||||
|
self.resumed_at = at
|
||||||
assert total is not None
|
assert total is not None
|
||||||
self.console.print(f'[progress.description]{description}')
|
self.console.print(f'[progress.description]{description}')
|
||||||
self.progress_bar = Progress(
|
self.progress_bar = Progress(
|
||||||
@ -136,6 +136,6 @@ class ProgressDisplay(BaseDisplay):
|
|||||||
[task] = self.progress_bar.tasks
|
[task] = self.progress_bar.tasks
|
||||||
self._print_summary(
|
self._print_summary(
|
||||||
is_finished=task.finished,
|
is_finished=task.finished,
|
||||||
observed_steps=task.completed,
|
observed_steps=task.completed - self.resumed_at,
|
||||||
time_spent=time_spent,
|
time_spent=time_spent,
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user