Skip to content

Commit c8c10dd

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent eca912f commit c8c10dd

4 files changed

Lines changed: 4 additions & 21 deletions

File tree

mypy/build.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1223,12 +1223,7 @@ def parse_file(
12231223
tree = load_from_raw(path, id, raw_data, self.errors, options)
12241224
else:
12251225
tree, parse_errors = parse(
1226-
source,
1227-
path,
1228-
id,
1229-
self.errors,
1230-
options=options,
1231-
imports_only=imports_only,
1226+
source, path, id, self.errors, options=options, imports_only=imports_only
12321227
)
12331228
tree._fullname = id
12341229
if self.stats_enabled:

mypy/checkstrformat.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -582,11 +582,7 @@ def apply_field_accessors(
582582
temp_errors = Errors(self.chk.options)
583583
dummy = DUMMY_FIELD_NAME + spec.field[len(spec.key) :]
584584
temp_ast, _ = parse(
585-
dummy,
586-
fnam="<format>",
587-
module=None,
588-
options=self.chk.options,
589-
errors=temp_errors,
585+
dummy, fnam="<format>", module=None, options=self.chk.options, errors=temp_errors
590586
)
591587
if temp_errors.is_errors():
592588
self.msg.fail(

mypy/stubgen.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1745,11 +1745,7 @@ def parse_source_file(mod: StubSource, mypy_options: MypyOptions) -> None:
17451745
source = mypy.util.decode_python_encoding(data)
17461746
errors = Errors(mypy_options)
17471747
mod.ast, errs = mypy.parse.parse(
1748-
source,
1749-
fnam=mod.path,
1750-
module=mod.module,
1751-
errors=errors,
1752-
options=mypy_options,
1748+
source, fnam=mod.path, module=mod.module, errors=errors, options=mypy_options
17531749
)
17541750
mod.ast._fullname = mod.module
17551751
for err in errs:

mypy/test/testparse.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,7 @@ def test_parser(testcase: DataDrivenTestCase) -> None:
6161
try:
6262
errors = Errors(options)
6363
n, _ = parse(
64-
bytes(source, "ascii"),
65-
fnam="main",
66-
module="__main__",
67-
errors=errors,
68-
options=options,
64+
bytes(source, "ascii"), fnam="main", module="__main__", errors=errors, options=options
6965
)
7066
if errors.is_errors():
7167
errors.raise_error()

0 commit comments

Comments
 (0)