Skip to content

test,refactor: misc fixes for linters

Sign in for the full log view
GitHub Actions / Pylint failed Aug 9, 2024 in 0s

21 errors

Pylint found 21 errors

Annotations

Check failure on line 65 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L65

Too many arguments (7/5) (too-many-arguments, R0913)

Check failure on line 25 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L25

Consider using '{"black_exclude": set(), "expect": [A_PY_BLACK]}' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 29 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L29

Consider using '{"black_exclude": set(), "isort_exclude": set(), "expect": [A_PY_BLACK_ISORT], ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 34 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L34

Consider using '{"black_exclude": set(), "flynt_exclude": set(), "expect": [A_PY_BLACK_FLYNT], ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 39 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L39

Consider using '{"black_exclude": set(), "isort_exclude": set(), "flynt_exclude": set(), ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 45 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L45

Consider using '{"black_config": {'skip_string_normalization': True}, "black_exclude": set(), ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 50 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L50

Consider using '{"black_exclude": {Path('a.py')}, "expect": []}' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 54 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L54

Consider using '{"black_exclude": {Path('a.py')}, "isort_exclude": set(), "expect": [A_PY_ISORT], ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 111 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L111

Consider using '{"rev1": 'HEAD', "rev2": ':STDIN:', "expect": [('a.py', ("print('a.py HEAD' )", '#', "print( 'a.py STDIN')"), ("print('a.py HEAD' )", '#', 'print("a.py STDIN")'))], ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 122 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L122

Consider using '{"rev1": ':WORKTREE:', "rev2": ':STDIN:', "expect": [('a.py', ("print('a.py :WORKTREE:' )", '#', "print( 'a.py STDIN')"), ("print('a.py :WORKTREE:' )", '#', 'print("a.py STDIN")'))], ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 133 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L133

Consider using '{"rev1": 'HEAD', "rev2": ':WORKTREE:', "expect": [('a.py', ("print('a.py :WORKTREE:' )", '#', "print( 'a.py HEAD')"), ('print("a.py :WORKTREE:")', '#', "print( 'a.py HEAD')"))], ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 206 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L206

"result == []" can be simplified to "not result", if it is strictly a sequence, as an empty list is falsey (use-implicit-booleaness-not-comparison, C1803)

Check failure on line 274 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L274

"list(...) == []" can be simplified to "not list(...)", if it is strictly a sequence, as an empty list is falsey (use-implicit-booleaness-not-comparison, C1803)

Check failure on line 278 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L278

Consider using '{"rev1": 'HEAD^', "rev2": 'HEAD', "expect": []}' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 279 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L279

Consider using '{"rev1": 'HEAD^', "rev2": WORKTREE, "expect": [(':WORKTREE:', 'reformatted')], ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 280 in src/darker/tests/test_main_format_edited_parts.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_format_edited_parts.py#L280

Consider using '{"rev1": 'HEAD', "rev2": WORKTREE, "expect": [(':WORKTREE:', 'reformatted')], ... }' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 18 in src/darker/tests/test_main_isort.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_isort.py#L18

Unused argument 'git_repo' (unused-argument, W0613)

Check failure on line 61 in src/darker/tests/test_main_isort.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_isort.py#L61

Redefining name 'run_isort' from outer scope (line 35) (redefined-outer-name, W0621)

Check failure on line 71 in src/darker/tests/test_main_isort.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_isort.py#L71

Redefining name 'run_isort' from outer scope (line 35) (redefined-outer-name, W0621)

Check failure on line 67 in src/darker/tests/test_main_isort.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_isort.py#L67

Consider using '{"run_isort": (), "isort_args": {}}' instead of a call to 'dict'. (use-dict-literal, R1735)

Check failure on line 68 in src/darker/tests/test_main_isort.py

See this annotation in the file changed.

@github-actions github-actions / Pylint

src/darker/tests/test_main_isort.py#L68

Consider using '{"run_isort": ('--line-length', '120'), "isort_args": {'line_length': 120}, ... }' instead of a call to 'dict'. (use-dict-literal, R1735)