Skip to content

Commit 6e25daa

Browse files
authored
Restore the correct type of AugmentedHelpFormatter._fill_text() (#9377)
This reverts commit af00d01 which introduced a workaround for an incorrect type definition in typeshed. The type of AugmentedHelpFormatter._fill_text() got fixed in commit python/typeshed@686e21d so we can remove the workaround.
1 parent 0ea510c commit 6e25daa

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

mypy/main.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,9 +134,7 @@ class AugmentedHelpFormatter(argparse.RawDescriptionHelpFormatter):
134134
def __init__(self, prog: str) -> None:
135135
super().__init__(prog=prog, max_help_position=28)
136136

137-
# FIXME: typeshed incorrectly has the type of indent as int when
138-
# it should be str. Make it Any to avoid rusing mypyc.
139-
def _fill_text(self, text: str, width: int, indent: Any) -> str:
137+
def _fill_text(self, text: str, width: int, indent: str) -> str:
140138
if '\n' in text:
141139
# Assume we want to manually format the text
142140
return super()._fill_text(text, width, indent)

0 commit comments

Comments
 (0)