@@ -78,6 +78,7 @@ def __init__(self, *args, **kwargs):
78
78
"""
79
79
Save the original SIGINT handler for later.
80
80
"""
81
+ # https://github.com/python/mypy/issues/5887
81
82
super (InterruptibleMixin , self ).__init__ ( # type: ignore
82
83
* args ,
83
84
** kwargs
@@ -134,6 +135,7 @@ class DownloadProgressMixin(object):
134
135
135
136
def __init__ (self , * args , ** kwargs ):
136
137
# type: (List[Any], Dict[Any, Any]) -> None
138
+ # https://github.com/python/mypy/issues/5887
137
139
super (DownloadProgressMixin , self ).__init__ ( # type: ignore
138
140
* args ,
139
141
** kwargs
@@ -183,6 +185,7 @@ def __init__(self, *args, **kwargs):
183
185
if WINDOWS and self .hide_cursor : # type: ignore
184
186
self .hide_cursor = False
185
187
188
+ # https://github.com/python/mypy/issues/5887
186
189
super (WindowsMixin , self ).__init__ (* args , ** kwargs ) # type: ignore
187
190
188
191
# Check if we are running on Windows and we have the colorama module,
@@ -206,30 +209,27 @@ class BaseDownloadProgressBar(WindowsMixin, InterruptibleMixin,
206
209
message = "%(percent)d%%"
207
210
suffix = "%(downloaded)s %(download_speed)s %(pretty_eta)s"
208
211
209
- # NOTE: The "type: ignore" comments on the following classes are there to
210
- # work around https://github.com/python/typing/issues/241
211
-
212
212
213
213
class DefaultDownloadProgressBar (BaseDownloadProgressBar ,
214
214
_BaseBar ):
215
215
pass
216
216
217
217
218
- class DownloadSilentBar (BaseDownloadProgressBar , SilentBar ): # type: ignore
218
+ class DownloadSilentBar (BaseDownloadProgressBar , SilentBar ):
219
219
pass
220
220
221
221
222
- class DownloadBar (BaseDownloadProgressBar , # type: ignore
222
+ class DownloadBar (BaseDownloadProgressBar ,
223
223
Bar ):
224
224
pass
225
225
226
226
227
- class DownloadFillingCirclesBar (BaseDownloadProgressBar , # type: ignore
227
+ class DownloadFillingCirclesBar (BaseDownloadProgressBar ,
228
228
FillingCirclesBar ):
229
229
pass
230
230
231
231
232
- class DownloadBlueEmojiProgressBar (BaseDownloadProgressBar , # type: ignore
232
+ class DownloadBlueEmojiProgressBar (BaseDownloadProgressBar ,
233
233
BlueEmojiBar ):
234
234
pass
235
235
@@ -240,7 +240,8 @@ class DownloadProgressSpinner(WindowsMixin, InterruptibleMixin,
240
240
file = sys .stdout
241
241
suffix = "%(downloaded)s %(download_speed)s"
242
242
243
- def next_phase (self ): # type: ignore
243
+ def next_phase (self ):
244
+ # type: () -> str
244
245
if not hasattr (self , "_phaser" ):
245
246
self ._phaser = itertools .cycle (self .phases )
246
247
return next (self ._phaser )
0 commit comments