@@ -495,9 +495,8 @@ def refresh(cls, path: Union[None, PathLike] = None) -> bool:
495
495
if mode in quiet :
496
496
pass
497
497
elif mode in warn or mode in error :
498
- err = (
499
- dedent (
500
- """\
498
+ err = dedent (
499
+ """\
501
500
%s
502
501
All git commands will error until this is rectified.
503
502
@@ -510,40 +509,35 @@ def refresh(cls, path: Union[None, PathLike] = None) -> bool:
510
509
Example:
511
510
export %s=%s
512
511
"""
513
- )
514
- % (
515
- err ,
516
- cls ._refresh_env_var ,
517
- "|" .join (quiet ),
518
- "|" .join (warn ),
519
- "|" .join (error ),
520
- cls ._refresh_env_var ,
521
- quiet [0 ],
522
- )
512
+ ) % (
513
+ err ,
514
+ cls ._refresh_env_var ,
515
+ "|" .join (quiet ),
516
+ "|" .join (warn ),
517
+ "|" .join (error ),
518
+ cls ._refresh_env_var ,
519
+ quiet [0 ],
523
520
)
524
521
525
522
if mode in warn :
526
523
_logger .critical (err )
527
524
else :
528
525
raise ImportError (err )
529
526
else :
530
- err = (
531
- dedent (
532
- """\
527
+ err = dedent (
528
+ """\
533
529
%s environment variable has been set but it has been set with an invalid value.
534
530
535
531
Use only the following values:
536
532
- %s: for no message or exception
537
533
- %s: for a warning message (logging level CRITICAL, displayed by default)
538
534
- %s: for a raised exception
539
535
"""
540
- )
541
- % (
542
- cls ._refresh_env_var ,
543
- "|" .join (quiet ),
544
- "|" .join (warn ),
545
- "|" .join (error ),
546
- )
536
+ ) % (
537
+ cls ._refresh_env_var ,
538
+ "|" .join (quiet ),
539
+ "|" .join (warn ),
540
+ "|" .join (error ),
547
541
)
548
542
raise ImportError (err )
549
543
@@ -565,13 +559,11 @@ def is_cygwin(cls) -> bool:
565
559
566
560
@overload
567
561
@classmethod
568
- def polish_url (cls , url : str , is_cygwin : Literal [False ] = ...) -> str :
569
- ...
562
+ def polish_url (cls , url : str , is_cygwin : Literal [False ] = ...) -> str : ...
570
563
571
564
@overload
572
565
@classmethod
573
- def polish_url (cls , url : str , is_cygwin : Union [None , bool ] = None ) -> str :
574
- ...
566
+ def polish_url (cls , url : str , is_cygwin : Union [None , bool ] = None ) -> str : ...
575
567
576
568
@classmethod
577
569
def polish_url (cls , url : str , is_cygwin : Union [None , bool ] = None ) -> PathLike :
@@ -932,8 +924,7 @@ def execute(
932
924
command : Union [str , Sequence [Any ]],
933
925
* ,
934
926
as_process : Literal [True ],
935
- ) -> "AutoInterrupt" :
936
- ...
927
+ ) -> "AutoInterrupt" : ...
937
928
938
929
@overload
939
930
def execute (
@@ -942,8 +933,7 @@ def execute(
942
933
* ,
943
934
as_process : Literal [False ] = False ,
944
935
stdout_as_string : Literal [True ],
945
- ) -> Union [str , Tuple [int , str , str ]]:
946
- ...
936
+ ) -> Union [str , Tuple [int , str , str ]]: ...
947
937
948
938
@overload
949
939
def execute (
@@ -952,8 +942,7 @@ def execute(
952
942
* ,
953
943
as_process : Literal [False ] = False ,
954
944
stdout_as_string : Literal [False ] = False ,
955
- ) -> Union [bytes , Tuple [int , bytes , str ]]:
956
- ...
945
+ ) -> Union [bytes , Tuple [int , bytes , str ]]: ...
957
946
958
947
@overload
959
948
def execute (
@@ -963,8 +952,7 @@ def execute(
963
952
with_extended_output : Literal [False ],
964
953
as_process : Literal [False ],
965
954
stdout_as_string : Literal [True ],
966
- ) -> str :
967
- ...
955
+ ) -> str : ...
968
956
969
957
@overload
970
958
def execute (
@@ -974,8 +962,7 @@ def execute(
974
962
with_extended_output : Literal [False ],
975
963
as_process : Literal [False ],
976
964
stdout_as_string : Literal [False ],
977
- ) -> bytes :
978
- ...
965
+ ) -> bytes : ...
979
966
980
967
def execute (
981
968
self ,
@@ -1387,8 +1374,9 @@ def __call__(self, **kwargs: Any) -> "Git":
1387
1374
return self
1388
1375
1389
1376
@overload
1390
- def _call_process (self , method : str , * args : None , ** kwargs : None ) -> str :
1391
- ... # If no args were given, execute the call with all defaults.
1377
+ def _call_process (
1378
+ self , method : str , * args : None , ** kwargs : None
1379
+ ) -> str : ... # If no args were given, execute the call with all defaults.
1392
1380
1393
1381
@overload
1394
1382
def _call_process (
@@ -1398,14 +1386,12 @@ def _call_process(
1398
1386
as_process : Literal [True ],
1399
1387
* args : Any ,
1400
1388
** kwargs : Any ,
1401
- ) -> "Git.AutoInterrupt" :
1402
- ...
1389
+ ) -> "Git.AutoInterrupt" : ...
1403
1390
1404
1391
@overload
1405
1392
def _call_process (
1406
1393
self , method : str , * args : Any , ** kwargs : Any
1407
- ) -> Union [str , bytes , Tuple [int , Union [str , bytes ], str ], "Git.AutoInterrupt" ]:
1408
- ...
1394
+ ) -> Union [str , bytes , Tuple [int , Union [str , bytes ], str ], "Git.AutoInterrupt" ]: ...
1409
1395
1410
1396
def _call_process (
1411
1397
self , method : str , * args : Any , ** kwargs : Any
0 commit comments