Skip to content

Commit 130e1a4

Browse files
authored
Fix unnecessarily split quotes, couple string bugs (#13603)
This is a relic from blackening. Actually quite a few buggy strings in here, so glad I did this.
1 parent 2e326b2 commit 130e1a4

File tree

13 files changed

+16
-18
lines changed

13 files changed

+16
-18
lines changed

misc/incremental_checker.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ def main() -> None:
407407
parser.add_argument(
408408
"range_start",
409409
metavar="COMMIT_ID_OR_NUMBER",
410-
help="the commit id to start from, or the number of " "commits to move back (see above)",
410+
help="the commit id to start from, or the number of commits to move back (see above)",
411411
)
412412
parser.add_argument(
413413
"-r",
@@ -439,7 +439,7 @@ def main() -> None:
439439
"--branch",
440440
default=None,
441441
metavar="NAME",
442-
help="check out and test a custom branch" "uses the default if not specified",
442+
help="check out and test a custom branch uses the default if not specified",
443443
)
444444
parser.add_argument("--sample", type=int, help="use a random sample of size SAMPLE")
445445
parser.add_argument("--seed", type=str, help="random seed")

mypy/checkexpr.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1194,7 +1194,7 @@ def check_call_expr_with_callee_type(
11941194
return ret_type
11951195

11961196
def check_union_call_expr(self, e: CallExpr, object_type: UnionType, member: str) -> Type:
1197-
""" "Type check calling a member expression where the base type is a union."""
1197+
"""Type check calling a member expression where the base type is a union."""
11981198
res: list[Type] = []
11991199
for typ in object_type.relevant_items():
12001200
# Member access errors are already reported when visiting the member expression.

mypy/config_parser.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -484,8 +484,7 @@ def parse_section(
484484
results["follow_imports"] = "skip"
485485
if key == "almost_silent":
486486
print(
487-
"%salmost_silent has been replaced by " "follow_imports=error" % prefix,
488-
file=stderr,
487+
"%salmost_silent has been replaced by follow_imports=error" % prefix, file=stderr
489488
)
490489
if v:
491490
if "follow_imports" not in results:

mypy/fastparse.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -934,7 +934,7 @@ def do_func_def(
934934
if any(arg_types) or return_type:
935935
if len(arg_types) != 1 and any(isinstance(t, EllipsisType) for t in arg_types):
936936
self.fail(
937-
"Ellipses cannot accompany other argument types " "in function type signature",
937+
"Ellipses cannot accompany other argument types in function type signature",
938938
lineno,
939939
n.col_offset,
940940
)

mypy/ipc.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ def __exit__(
252252
# Wait for the client to finish reading the last write before disconnecting
253253
if not FlushFileBuffers(self.connection):
254254
raise IPCException(
255-
"Failed to flush NamedPipe buffer," "maybe the client hung up?"
255+
"Failed to flush NamedPipe buffer, maybe the client hung up?"
256256
)
257257
finally:
258258
DisconnectNamedPipe(self.connection)

mypy/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -657,7 +657,7 @@ def add_invertible_flag(
657657
"--disallow-any-generics",
658658
default=False,
659659
strict_flag=True,
660-
help="Disallow usage of generic types that do not specify explicit type " "parameters",
660+
help="Disallow usage of generic types that do not specify explicit type parameters",
661661
group=disallow_any_group,
662662
)
663663
add_invertible_flag(

mypy/messages.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1302,7 +1302,7 @@ def incompatible_self_argument(
13021302
)
13031303

13041304
def incompatible_conditional_function_def(self, defn: FuncDef) -> None:
1305-
self.fail("All conditional function variants must have identical " "signatures", defn)
1305+
self.fail("All conditional function variants must have identical signatures", defn)
13061306

13071307
def cannot_instantiate_abstract_class(
13081308
self, class_name: str, abstract_attributes: dict[str, bool], context: Context

mypy/nodes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3715,7 +3715,7 @@ def check_arg_kinds(
37153715
if kind == ARG_POS:
37163716
if is_var_arg or is_kw_arg or seen_named or seen_opt:
37173717
fail(
3718-
"Required positional args may not appear " "after default, named or var args",
3718+
"Required positional args may not appear after default, named or var args",
37193719
node,
37203720
)
37213721
break

mypy/semanal.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1099,7 +1099,7 @@ def handle_missing_overload_decorators(
10991099
)
11001100
else:
11011101
self.fail(
1102-
"The implementation for an overloaded function " "must come last",
1102+
"The implementation for an overloaded function must come last",
11031103
defn.items[idx],
11041104
)
11051105
else:
@@ -3347,7 +3347,7 @@ def analyze_lvalue(
33473347
elif isinstance(lval, MemberExpr):
33483348
self.analyze_member_lvalue(lval, explicit_type, is_final)
33493349
if explicit_type and not self.is_self_member_ref(lval):
3350-
self.fail("Type cannot be declared in assignment to non-self " "attribute", lval)
3350+
self.fail("Type cannot be declared in assignment to non-self attribute", lval)
33513351
elif isinstance(lval, IndexExpr):
33523352
if explicit_type:
33533353
self.fail("Unexpected type declaration", lval)

mypy/stubgen.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1732,9 +1732,7 @@ def parse_options(args: list[str]) -> Options:
17321732
parser.add_argument(
17331733
"--export-less",
17341734
action="store_true",
1735-
help=(
1736-
"don't implicitly export all names imported from other modules " "in the same package"
1737-
),
1735+
help="don't implicitly export all names imported from other modules in the same package",
17381736
)
17391737
parser.add_argument("-v", "--verbose", action="store_true", help="show more verbose messages")
17401738
parser.add_argument("-q", "--quiet", action="store_true", help="show fewer messages")

0 commit comments

Comments
 (0)