The uncompromising Python code formatter
851 matches across 11 categories. Click a row to expand file-level details.
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | tests/optional.py | 107 | def pytest_collection_modifyitems(config: "Config", items: "list[Node]") -> None: |
| LOW | tests/util.py | 342 | def read_jupyter_notebook_from_file(file_name: Path) -> str: |
| LOW | tests/test_docs.py | 59 | def test_feature_lists_are_up_to_date() -> None: |
| LOW | tests/test_ipynb.py | 66 | def test_trailing_semicolon_with_comment() -> None: |
| LOW | tests/test_ipynb.py | 73 | def test_trailing_semicolon_with_comment_on_next_line() -> None: |
| LOW | tests/test_ipynb.py | 79 | def test_trailing_semicolon_indented() -> None: |
| LOW | tests/test_ipynb.py | 85 | def test_trailing_semicolon_noop() -> None: |
| LOW | tests/test_ipynb.py | 48 | def test_create_token_uses_requested_length(n_chars: int) -> None: |
| LOW | tests/test_ipynb.py | 52 | def test_unmask_cell_raises_when_token_is_not_unique() -> None: |
| LOW | tests/test_ipynb.py | 173 | def test_input_already_contains_transformed_magic() -> None: |
| LOW | tests/test_ipynb.py | 185 | def test_cell_magic_with_magic() -> None: |
| LOW | tests/test_ipynb.py | 203 | def test_cell_magic_with_empty_lines(src: str, expected: str) -> None: |
| LOW | tests/test_ipynb.py | 231 | def test_cell_magic_with_custom_python_magic( |
| LOW | tests/test_ipynb.py | 252 | def test_cell_magic_with_custom_python_magic_after_spaces_and_comments_noop( |
| LOW | tests/test_ipynb.py | 266 | def test_cell_magic_with_magic_noop() -> None: |
| LOW | tests/test_ipynb.py | 291 | def test_cell_magic_with_invalid_body() -> None: |
| LOW | tests/test_ipynb.py | 303 | def test_entire_notebook_empty_metadata() -> None: |
| LOW | tests/test_ipynb.py | 338 | def test_entire_notebook_trailing_newline() -> None: |
| LOW | tests/test_ipynb.py | 385 | def test_entire_notebook_no_trailing_newline() -> None: |
| LOW | tests/test_ipynb.py | 432 | def test_entire_notebook_without_changes() -> None: |
| LOW | tests/test_ipynb.py | 450 | def test_unparseable_notebook() -> None: |
| LOW | tests/test_ipynb.py | 457 | def test_ipynb_diff_with_change() -> None: |
| LOW | tests/test_ipynb.py | 470 | def test_ipynb_diff_with_no_change() -> None: |
| LOW | tests/test_ipynb.py | 483 | def test_cache_isnt_written_if_no_jupyter_deps_single( |
| LOW | tests/test_ipynb.py | 504 | def test_cache_isnt_written_if_no_jupyter_deps_dir( |
| LOW | tests/test_ipynb.py | 559 | def test_unable_to_replace_magics(monkeypatch: MonkeyPatch) -> None: |
| LOW | tests/test_concurrency_manager_shutdown.py | 26 | def test_manager_shutdown_called_for_diff(monkeypatch: Any, tmp_path: Path) -> None: |
| LOW | tests/test_concurrency_manager_shutdown.py | 35 | def fake_format_file_in_place( |
| LOW | tests/test_black.py | 1431 | def test_required_version_matches_version(self) -> None: |
| LOW | tests/test_black.py | 1438 | def test_required_version_matches_partial_version(self) -> None: |
| LOW | tests/test_black.py | 1445 | def test_required_version_does_not_match_on_minor_version(self) -> None: |
| LOW | tests/test_black.py | 1452 | def test_required_version_does_not_match_version(self) -> None: |
| LOW | tests/test_black.py | 1460 | def test_preserves_line_endings(self) -> None: |
| LOW | tests/test_black.py | 3148 | def test_assert_equivalent_basic(self) -> None: |
| LOW | tests/test_black.py | 3153 | def test_assert_equivalent_del(self) -> None: |
| LOW | tests/test_black.py | 3156 | def test_assert_equivalent_strings(self) -> None: |
| LOW | tests/test_black.py | 215 | def test_piping_diff_with_color(self) -> None: |
| LOW | tests/test_black.py | 236 | def test_piping_diff_with_color_respects_no_color(self) -> None: |
| LOW | tests/test_black.py | 337 | def test_expression_diff_with_color(self) -> None: |
| LOW | tests/test_black.py | 357 | def test_detect_pos_only_arguments(self) -> None: |
| LOW | tests/test_black.py | 365 | def test_detect_debug_f_strings(self) -> None: |
| LOW | tests/test_black.py | 395 | def test_skip_source_first_line(self) -> None: |
| LOW | tests/test_black.py | 408 | def test_skip_source_first_line_when_mixing_newlines(self) -> None: |
| LOW | tests/test_black.py | 418 | def test_skip_magic_trailing_comma(self) -> None: |
| LOW | tests/test_black.py | 470 | def test_tab_comment_indentation(self) -> None: |
| LOW | tests/test_black.py | 808 | def test_report_respects_no_color(self) -> None: |
| LOW | tests/test_black.py | 831 | def test_get_features_used_decorator(self) -> None: |
| LOW | tests/test_black.py | 954 | def test_get_features_used_for_future_flags(self) -> None: |
| LOW | tests/test_black.py | 1027 | def test_format_file_contents(self) -> None: |
| LOW | tests/test_black.py | 1115 | def test_works_in_mono_process_only_environment(self) -> None: |
| LOW | tests/test_black.py | 1125 | def test_check_diff_use_together(self) -> None: |
| LOW | tests/test_black.py | 1153 | def test_single_file_force_pyi(self) -> None: |
| LOW | tests/test_black.py | 1171 | def test_multi_file_force_pyi(self) -> None: |
| LOW | tests/test_black.py | 1253 | def test_reformat_one_with_stdin(self) -> None: |
| LOW | tests/test_black.py | 1271 | def test_reformat_one_with_stdin_filename(self) -> None: |
| LOW | tests/test_black.py | 1294 | def test_reformat_one_with_stdin_filename_pyi(self) -> None: |
| LOW | tests/test_black.py | 1320 | def test_reformat_one_with_stdin_filename_ipynb(self) -> None: |
| LOW | tests/test_black.py | 1346 | def test_reformat_one_with_stdin_and_existing_path(self) -> None: |
| LOW | tests/test_black.py | 1370 | def test_reformat_one_with_stdin_empty(self) -> None: |
| LOW | tests/test_black.py | 1472 | def test_preserves_line_endings_via_stdin(self) -> None: |
| 322 more matches not shown… | |||
| Severity | File | Line | Snippet |
|---|---|---|---|
| HIGH | tests/data/cases/module_docstring_4.py | 0 | single line module-level docstring should be followed by single newline. |
| HIGH | tests/data/cases/module_docstring_4.py | 0 | single line module-level docstring should be followed by single newline. |
| HIGH | tests/data/cases/module_docstring_1.py | 0 | single line module-level docstring should be followed by single newline. |
| HIGH | tests/data/cases/module_docstring_1.py | 0 | single line module-level docstring should be followed by single newline. |
| HIGH | tests/data/cases/module_docstring_3.py | 0 | single line module-level docstring should be followed by single newline. |
| HIGH | tests/data/cases/module_docstring_3.py | 0 | single line module-level docstring should be followed by single newline. |
| HIGH | tests/data/cases/docstring_no_string_normalization.py | 0 | lorem ipsum dolor sit amet. consectetur adipiscing elit: - sed do eiusmod tempor incididunt ut labore - dolore magna ali |
| HIGH | tests/data/cases/docstring_no_string_normalization.py | 0 | lorem ipsum dolor sit amet. consectetur adipiscing elit: - sed do eiusmod tempor incididunt ut labore - dolore magna ali |
| HIGH | tests/data/cases/docstring.py | 0 | lorem ipsum dolor sit amet. consectetur adipiscing elit: - sed do eiusmod tempor incididunt ut labore - dolore magna ali |
| HIGH | tests/data/cases/docstring.py | 0 | lorem ipsum dolor sit amet. consectetur adipiscing elit: - sed do eiusmod tempor incididunt ut labore - dolore magna ali |
| HIGH | tests/data/cases/docstring_no_string_normalization.py | 0 | these lines are indented in a way that does not make sense. |
| HIGH | tests/data/cases/docstring_no_string_normalization.py | 0 | these lines are indented in a way that does not make sense. |
| HIGH | tests/data/cases/docstring.py | 0 | these lines are indented in a way that does not make sense. |
| HIGH | tests/data/cases/docstring.py | 0 | these lines are indented in a way that does not make sense. |
| HIGH | tests/data/cases/docstring_no_string_normalization.py | 0 | this has a shallow indent - but some lines are deeper - and the closing quote is too deep |
| HIGH | tests/data/cases/docstring_no_string_normalization.py | 0 | this has a shallow indent - but some lines are deeper - and the closing quote is too deep |
| HIGH | tests/data/cases/docstring.py | 0 | this has a shallow indent - but some lines are deeper - and the closing quote is too deep |
| HIGH | tests/data/cases/docstring.py | 0 | this has a shallow indent - but some lines are deeper - and the closing quote is too deep |
| HIGH | tests/data/cases/composition_no_trailing_comma.py | 0 | \ %3d 0 load_fast 1 (x) 2 load_const 1 (1) 4 compare_op 2 (==) 6 load_fast 0 (self) 8 store_attr 0 (x) 10 load_const 0 ( |
| HIGH | tests/data/cases/composition_no_trailing_comma.py | 0 | \ %3d 0 load_fast 1 (x) 2 load_const 1 (1) 4 compare_op 2 (==) 6 load_fast 0 (self) 8 store_attr 0 (x) 10 load_const 0 ( |
| HIGH | tests/data/cases/composition.py | 0 | \ %3d 0 load_fast 1 (x) 2 load_const 1 (1) 4 compare_op 2 (==) 6 load_fast 0 (self) 8 store_attr 0 (x) 10 load_const 0 ( |
| HIGH | tests/data/cases/multiline_strings.py | 0 | \ %3d 0 load_fast 1 (x) 2 load_const 1 (1) 4 compare_op 2 (==) 6 load_fast 0 (self) 8 store_attr 0 (x) 10 load_const 0 ( |
| HIGH | tests/data/cases/multiline_strings.py | 0 | \ %3d 0 load_fast 1 (x) 2 load_const 1 (1) 4 compare_op 2 (==) 6 load_fast 0 (self) 8 store_attr 0 (x) 10 load_const 0 ( |
| HIGH | tests/data/cases/docstring2.py | 0 | long docstring................................................................. |
| HIGH | tests/data/cases/docstring2.py | 0 | long docstring................................................................. |
| HIGH | tests/data/cases/docstring.py | 0 | long docstring................................................................. |
| HIGH | tests/data/cases/docstring.py | 0 | long docstring................................................................. |
| HIGH | tests/data/cases/docstring2.py | 0 | long docstring................................................................ |
| HIGH | tests/data/cases/docstring2.py | 0 | long docstring................................................................ |
| HIGH | tests/data/cases/docstring2.py | 0 | long docstring................................................................ |
| HIGH | tests/data/cases/docstring2.py | 0 | long docstring................................................................ |
| HIGH | tests/data/cases/docstring.py | 0 | long docstring................................................................ |
| HIGH | tests/data/cases/docstring.py | 0 | long docstring................................................................ |
| HIGH | tests/data/cases/docstring2.py | 0 | long docstring................................................................. ........................................ |
| HIGH | tests/data/cases/docstring2.py | 0 | long docstring................................................................. ........................................ |
| HIGH | tests/data/cases/docstring.py | 0 | long docstring................................................................. ........................................ |
| HIGH | tests/data/cases/docstring.py | 0 | long docstring................................................................. ........................................ |
| HIGH | tests/data/cases/docstring2.py | 0 | first line----------------------------------------------------------------------- second line--------------------------- |
| HIGH | tests/data/cases/docstring2.py | 0 | first line----------------------------------------------------------------------- second line--------------------------- |
| HIGH | tests/data/cases/docstring.py | 0 | first line----------------------------------------------------------------------- second line--------------------------- |
| HIGH | tests/data/cases/docstring.py | 0 | first line----------------------------------------------------------------------- second line--------------------------- |
| HIGH | tests/data/cases/fmtonoff.py | 0 | ^ [\t ]* \#[ ]type:[ ]* (?p<type> [^#\t\n]+? ) (?<!ignore) # note: this will force the non-greedy + in <type> to match # |
| HIGH | tests/data/cases/fmtonoff.py | 0 | ^ [\t ]* \#[ ]type:[ ]* (?p<type> [^#\t\n]+? ) (?<!ignore) # note: this will force the non-greedy + in <type> to match # |
| HIGH | tests/data/cases/function.py | 0 | ^ [\t ]* \#[ ]type:[ ]* (?p<type> [^#\t\n]+? ) (?<!ignore) # note: this will force the non-greedy + in <type> to match # |
| HIGH | tests/data/cases/function.py | 0 | ^ [\t ]* \#[ ]type:[ ]* (?p<type> [^#\t\n]+? ) (?<!ignore) # note: this will force the non-greedy + in <type> to match # |
| HIGH | tests/data/cases/preview_long_strings.py | 0 | this is a really really really long triple quote string and it should not be touched. |
| HIGH | tests/data/cases/preview_long_strings.py | 0 | this is a really really really long triple quote string and it should not be touched. |
| HIGH | tests/data/cases/long_strings_flag_disabled.py | 0 | this is a really really really long triple quote string and it should not be touched. |
| HIGH | tests/data/cases/preview_long_strings.py | 0 | this is a really really really long triple quote string assignment and it should not be touched. |
| HIGH | tests/data/cases/preview_long_strings.py | 0 | this is a really really really long triple quote string assignment and it should not be touched. |
| HIGH | tests/data/cases/long_strings_flag_disabled.py | 0 | this is a really really really long triple quote string assignment and it should not be touched. |
| HIGH | tests/data/cases/pep_750.py | 0 | foo {{ a foo {2 + 2}bar {{ baz x = f"foo {{ { 2 + 2 # comment }bar" {{ baz }} buzz {print("abc" + "def" )} abc |
| HIGH | tests/data/cases/pep_750.py | 0 | foo {{ a foo {2 + 2}bar {{ baz x = f"foo {{ { 2 + 2 # comment }bar" {{ baz }} buzz {print("abc" + "def" )} abc |
| HIGH | tests/data/cases/pep_701.py | 0 | foo {{ a foo {2 + 2}bar {{ baz x = f"foo {{ { 2 + 2 # comment }bar" {{ baz }} buzz {print("abc" + "def" )} abc |
| HIGH | tests/data/cases/pep_701.py | 0 | foo {{ a foo {2 + 2}bar {{ baz x = f"foo {{ { 2 + 2 # comment }bar" {{ baz }} buzz {print("abc" + "def" )} abc |
| HIGH | tests/data/cases/docstring.py | 0 | hey tab separated value tab at start of line and then a tab separated value multiple tabs at the beginning and inline mi |
| HIGH | tests/data/cases/docstring.py | 0 | hey tab separated value tab at start of line and then a tab separated value multiple tabs at the beginning and inline mi |
| HIGH | tests/data/cases/docstring.py | 0 | hey tab separated value tab at start of line and then a tab separated value multiple tabs at the beginning and inline mi |
| HIGH | tests/data/cases/docstring.py | 0 | hey tab separated value tab at start of line and then a tab separated value multiple tabs at the beginning and inline mi |
| HIGH | tests/data/cases/multiline_strings.py | 0 | \ a triple-quoted string actually leveraging the textwrap.dedent functionality that ends in a trailing newline, represen |
| 9 more matches not shown… | |||
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | tests/optional.py | 30 | |
| LOW | tests/optional.py | 31 | |
| LOW | tests/optional.py | 32 | |
| LOW | tests/optional.py | 33 | |
| LOW | tests/test_concurrency_manager_shutdown.py | 1 | |
| LOW | tests/data/cases/preview_comments7.py | 2 | |
| LOW | tests/data/cases/preview_comments7.py | 2 | |
| LOW | tests/data/cases/preview_comments7.py | 2 | |
| LOW | tests/data/cases/preview_comments7.py | 2 | |
| LOW | tests/data/cases/preview_comments7.py | 2 | |
| LOW | tests/data/cases/preview_comments7.py | 2 | |
| LOW | tests/data/cases/preview_comments7.py | 15 | |
| LOW | tests/data/cases/preview_comments7.py | 15 | |
| LOW | tests/data/cases/preview_comments7.py | 15 | |
| LOW | tests/data/cases/preview_comments7.py | 15 | |
| LOW | tests/data/cases/preview_comments7.py | 15 | |
| LOW | tests/data/cases/preview_comments7.py | 15 | |
| LOW | tests/data/cases/preview_comments7.py | 26 | |
| LOW | tests/data/cases/preview_comments7.py | 29 | |
| LOW | tests/data/cases/preview_comments7.py | 149 | |
| LOW | tests/data/cases/preview_comments7.py | 149 | |
| LOW | tests/data/cases/preview_comments7.py | 149 | |
| LOW | tests/data/cases/preview_comments7.py | 149 | |
| LOW | tests/data/cases/preview_comments7.py | 149 | |
| LOW | tests/data/cases/preview_comments7.py | 149 | |
| LOW | tests/data/cases/preview_comments7.py | 162 | |
| LOW | tests/data/cases/preview_comments7.py | 162 | |
| LOW | tests/data/cases/preview_comments7.py | 162 | |
| LOW | tests/data/cases/preview_comments7.py | 162 | |
| LOW | tests/data/cases/preview_comments7.py | 162 | |
| LOW | tests/data/cases/preview_comments7.py | 162 | |
| LOW | tests/data/cases/preview_comments7.py | 173 | |
| LOW | tests/data/cases/preview_comments7.py | 176 | |
| LOW | tests/data/cases/line_ranges_imports.py | 7 | |
| LOW | tests/data/cases/line_ranges_imports.py | 8 | |
| LOW | tests/data/cases/line_ranges_imports.py | 9 | |
| LOW | tests/data/cases/line_ranges_fmt_off.py | 6 | |
| LOW | tests/data/cases/line_ranges_fmt_off.py | 32 | |
| LOW | tests/data/cases/fmtonoff.py | 3 | |
| LOW | tests/data/cases/fmtonoff.py | 5 | |
| LOW | tests/data/cases/fmtonoff.py | 5 | |
| LOW | tests/data/cases/fmtonoff.py | 5 | |
| LOW | tests/data/cases/fmtonoff.py | 10 | |
| LOW | tests/data/cases/fmtonoff.py | 10 | |
| LOW | tests/data/cases/fmtonoff.py | 10 | |
| LOW | tests/data/cases/fmtonoff.py | 248 | |
| LOW | tests/data/cases/fmtonoff.py | 250 | |
| LOW | tests/data/cases/fmtonoff.py | 250 | |
| LOW | tests/data/cases/fmtonoff.py | 250 | |
| LOW | tests/data/cases/fmtonoff.py | 254 | |
| LOW | tests/data/cases/fmtonoff.py | 254 | |
| LOW | tests/data/cases/fmtonoff.py | 254 | |
| LOW | tests/data/cases/comments2.py | 1 | |
| LOW | tests/data/cases/comments2.py | 4 | |
| LOW | tests/data/cases/comments2.py | 172 | |
| LOW | tests/data/cases/comments2.py | 175 | |
| LOW | tests/data/cases/function2.py | 28 | |
| LOW | tests/data/cases/function2.py | 91 | |
| LOW | tests/data/cases/function2.py | 33 | |
| LOW | tests/data/cases/function2.py | 98 | |
| 165 more matches not shown… | |||
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | tests/test_black.py | 2507 | |
| LOW | tests/test_blackd.py | 212 | |
| LOW | tests/data/cases/composition_no_trailing_comma.py | 2 | |
| LOW | tests/data/cases/composition_no_trailing_comma.py | 188 | |
| LOW | tests/data/cases/empty_lines.py | 5 | |
| LOW | tests/data/cases/empty_lines.py | 102 | |
| LOW | tests/data/cases/composition.py | 2 | |
| LOW | action/main.py | 102 | |
| LOW | src/blib2to3/pytree.py | 943 | |
| LOW | src/blib2to3/pytree.py | 672 | |
| LOW | src/blib2to3/pytree.py | 792 | |
| LOW | src/blib2to3/pytree.py | 803 | |
| LOW | src/blib2to3/pytree.py | 848 | |
| LOW | src/blib2to3/pytree.py | 894 | |
| LOW | src/blib2to3/pgen2/pgen.py | 132 | |
| LOW | src/blib2to3/pgen2/pgen.py | 189 | |
| LOW | src/blib2to3/pgen2/pgen.py | 228 | |
| LOW | src/blib2to3/pgen2/conv.py | 85 | |
| LOW | src/blib2to3/pgen2/parse.py | 274 | |
| LOW | src/blib2to3/pgen2/parse.py | 320 | |
| LOW | src/blib2to3/pgen2/driver.py | 200 | |
| LOW | src/blib2to3/pgen2/tokenize.py | 146 | |
| LOW | src/blackd/client.py | 69 | |
| LOW | src/blackd/__init__.py | 297 | |
| LOW | src/black/files.py | 195 | |
| LOW | src/black/files.py | 320 | |
| LOW | src/black/parsing.py | 188 | |
| LOW | src/black/handle_ipynb_magics.py | 443 | |
| LOW | src/black/handle_ipynb_magics.py | 476 | |
| LOW | src/black/concurrency.py | 142 | |
| LOW | src/black/__init__.py | 538 | |
| LOW | src/black/__init__.py | 763 | |
| LOW | src/black/__init__.py | 894 | |
| LOW | src/black/__init__.py | 1023 | |
| LOW | src/black/__init__.py | 1364 | |
| LOW | src/black/__init__.py | 1573 | |
| LOW | src/black/__init__.py | 1577 | |
| LOW | src/black/brackets.py | 368 | |
| LOW | src/black/lines.py | 1242 | |
| LOW | src/black/lines.py | 1330 | |
| LOW | src/black/lines.py | 1366 | |
| LOW | src/black/lines.py | 264 | |
| LOW | src/black/lines.py | 300 | |
| LOW | src/black/lines.py | 741 | |
| LOW | src/black/lines.py | 932 | |
| LOW | src/black/lines.py | 1082 | |
| LOW | src/black/ranges.py | 252 | |
| LOW | src/black/trans.py | 1330 | |
| LOW | src/black/trans.py | 425 | |
| LOW | src/black/trans.py | 756 | |
| LOW | src/black/trans.py | 1175 | |
| LOW | src/black/trans.py | 1513 | |
| LOW | src/black/trans.py | 1984 | |
| LOW | src/black/trans.py | 2080 | |
| LOW | src/black/trans.py | 2115 | |
| LOW | src/black/trans.py | 2162 | |
| LOW | src/black/trans.py | 2226 | |
| LOW | src/black/nodes.py | 180 | |
| LOW | src/black/linegen.py | 707 | |
| LOW | src/black/linegen.py | 882 | |
| 16 more matches not shown… | |||
| Severity | File | Line | Snippet |
|---|---|---|---|
| HIGH | tests/test_ipynb.py | 311 | ' "execution_count": null,\n' |
| HIGH | tests/test_ipynb.py | 324 | ' "execution_count": null,\n' |
| HIGH | tests/test_ipynb.py | 346 | ' "execution_count": null,\n' |
| HIGH | tests/test_ipynb.py | 359 | ' "execution_count": null,\n' |
| HIGH | tests/test_ipynb.py | 393 | ' "execution_count": null,\n' |
| HIGH | tests/test_ipynb.py | 406 | ' "execution_count": null,\n' |
| HIGH | tests/data/cases/preview_long_strings__regression.py | 128 | "xx {xxxxxxxxxxx}/xxxxxxxxxxx.xxx xxxx.xxx && xxxxxx -x " |
| HIGH | tests/data/cases/preview_long_strings__regression.py | 140 | "xx {xxxxxxxxxxx}/xxxxxxxxxxx.xxx xxxx.xxx && xxxxxx -x " |
| HIGH | tests/data/cases/preview_long_strings__regression.py | 727 | "xx {xxxxxxxxxxx}/xxxxxxxxxxx.xxx xxxx.xxx && xxxxxx -x " |
| HIGH | tests/data/cases/preview_long_strings__regression.py | 738 | "xx {xxxxxxxxxxx}/xxxxxxxxxxx.xxx xxxx.xxx && xxxxxx -x " |
| HIGH | src/blib2to3/pgen2/parse.py | 289 | self.push(t, itsdfa, newstate, context) |
| HIGH | src/black/__init__.py | 486 | " (which can silenced by 2>/dev/null)." |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | tests/util.py | 66 | except Exception as ve: |
| LOW | tests/util.py | 75 | except Exception as ve: |
| LOW | tests/util.py | 129 | except Exception as e: |
| LOW | tests/util.py | 156 | except Exception as e: |
| LOW | tests/data/cases/remove_parens.py | 15 | except Exception as e: |
| LOW | tests/data/cases/remove_parens.py | 73 | except Exception as e: |
| LOW | tests/data/cases/pep_654.py | 25 | except Exception as e: |
| LOW | tests/data/cases/pep_654.py | 37 | except Exception as e: |
| LOW | tests/data/cases/import_line_collapse.py | 35 | except Exception: |
| LOW | tests/data/cases/import_line_collapse.py | 42 | except Exception: |
| LOW | tests/data/cases/import_line_collapse.py | 126 | except Exception: |
| LOW | tests/data/cases/import_line_collapse.py | 135 | except Exception: |
| LOW | tests/data/cases/pep_654_style.py | 25 | except Exception as e: |
| LOW | tests/data/cases/pep_654_style.py | 38 | except Exception as e: |
| LOW | tests/data/cases/pep_654_style.py | 83 | except Exception as e: |
| LOW | tests/data/cases/pep_654_style.py | 95 | except Exception as e: |
| LOW | tests/data/miscellaneous/python2_detection.py | 60 | except Exception as err: |
| LOW | action/main.py | 196 | except Exception as e: |
| LOW | src/blackd/__init__.py | 213 | except Exception as e: |
| LOW | src/black/__init__.py | 885 | except Exception as exc: |
| LOW | src/black/__init__.py | 949 | except Exception as exc: |
| LOW | src/black/__init__.py | 1637 | except Exception as exc: |
| LOW | src/black/__init__.py | 1647 | except Exception as exc: |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | tests/data/empty_pyproject.toml | 1 | # Empty pyproject.toml to use with some tests that depend on Python 3.6 autodiscovery |
| LOW | tests/data/cases/comments8.py | 1 | # The percent-percent comments are Spyder IDE cells. |
| LOW | tests/data/cases/fmtonoff.py | 101 | |
| LOW | tests/data/cases/fmtonoff.py | 201 | #nospaceatall |
| LOW | tests/data/cases/fmtonoff.py | 221 | # fmt: on |
| LOW | tests/data/cases/fmtonoff.py | 361 | # fmt: off |
| LOW | tests/data/cases/fmtonoff.py | 481 | #nospaceatall |
| LOW | tests/data/cases/fmtonoff.py | 501 | # fmt: on |
| LOW | tests/data/cases/pyi_overload_groups.py | 1 | # flags: --preview --pyi |
| LOW | tests/data/cases/pyi_overload_groups.py | 461 | @overload |
| LOW | tests/data/cases/jupytext_markdown_fmt.py | 1 | # Test that Jupytext markdown comments are preserved before fmt:off/on blocks |
| LOW | tests/data/cases/line_ranges_diff_edge_case.py | 1 | # flags: --line-ranges=10-11 |
| LOW | tests/data/miscellaneous/missing_final_newline.py | 1 | # A comment-only file, with no final EOL character |
| LOW | docs/conf.py | 1 | # |
| LOW | docs/conf.py | 101 | # The language for content autogenerated by Sphinx. Refer to documentation |
| LOW | docs/conf.py | 141 | # Add any paths that contain custom static files (such as style sheets) here, |
| LOW | src/blib2to3/Grammar.txt | 21 | decorator: '@' namedexpr_test NEWLINE |
| LOW | src/blib2to3/Grammar.txt | 201 | comp_for: [ASYNC] 'for' exprlist 'in' or_test [comp_iter] |
| LOW | src/black/lines.py | 301 | if not self.leaves: |
| LOW | src/black/ranges.py | 321 | # isn't easy. These cases are also badly formatted code, so it isn't |
| LOW | src/black/trans.py | 1641 | # Otherwise, we stop splitting here. |
| LOW | src/black/linegen.py | 621 | # fstring_start = node.children[0] |
| LOW | src/black/linegen.py | 1781 | for child in context_managers: |
| LOW | src/black/linegen.py | 1801 | node: Node, parent: Node, mode: Mode, features: Collection[Feature] |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | tests/data/cases/docstring_no_string_normalization.py | 40 | Lorem ipsum dolor sit amet. |
| LOW | tests/data/cases/docstring_no_string_normalization.py | 40 | Lorem ipsum dolor sit amet. |
| LOW | tests/data/cases/docstring_no_string_normalization.py | 167 | Lorem ipsum dolor sit amet. |
| LOW | tests/data/cases/docstring_no_string_normalization.py | 167 | Lorem ipsum dolor sit amet. |
| LOW | tests/data/cases/preview_long_dict_values.py | 25 | r"Lorem ipsum dolor sit amet, an sed convenire eloquentiam \t" |
| LOW | tests/data/cases/preview_long_dict_values.py | 25 | r"Lorem ipsum dolor sit amet, an sed convenire eloquentiam \t" |
| LOW | tests/data/cases/preview_long_dict_values.py | 172 | r"Lorem ipsum dolor sit amet, an sed convenire eloquentiam \t" |
| LOW | tests/data/cases/preview_long_dict_values.py | 172 | r"Lorem ipsum dolor sit amet, an sed convenire eloquentiam \t" |
| LOW | tests/data/cases/preview_long_strings__regression.py | 376 | print(f"Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam. {[f'{i}' for i in range(10)]}") |
| LOW | tests/data/cases/preview_long_strings__regression.py | 376 | print(f"Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam. {[f'{i}' for i in range(10)]}") |
| LOW | tests/data/cases/preview_long_strings__regression.py | 531 | r"Lorem ipsum dolor sit amet, an sed convenire eloquentiam \t" |
| LOW | tests/data/cases/preview_long_strings__regression.py | 531 | r"Lorem ipsum dolor sit amet, an sed convenire eloquentiam \t" |
| LOW | tests/data/cases/preview_long_strings__regression.py | 563 | s = f'Lorem Ipsum is simply dummy text of the printing and typesetting industry:\'{my_dict["foo"]}\'' |
| LOW | tests/data/cases/preview_long_strings__regression.py | 1041 | "Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam." |
| LOW | tests/data/cases/preview_long_strings__regression.py | 1041 | "Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam." |
| LOW | tests/data/cases/preview_long_strings__regression.py | 1222 | r"Lorem ipsum dolor sit amet, an sed convenire eloquentiam \t" |
| LOW | tests/data/cases/preview_long_strings__regression.py | 1222 | r"Lorem ipsum dolor sit amet, an sed convenire eloquentiam \t" |
| LOW | tests/data/cases/preview_long_strings__regression.py | 1260 | "Lorem Ipsum is simply dummy text of the printing and typesetting" |
| LOW | tests/data/cases/docstring.py | 49 | Lorem ipsum dolor sit amet. |
| LOW | tests/data/cases/docstring.py | 49 | Lorem ipsum dolor sit amet. |
| LOW | tests/data/cases/docstring.py | 281 | Lorem ipsum dolor sit amet. |
| LOW | tests/data/cases/docstring.py | 281 | Lorem ipsum dolor sit amet. |
| LOW | tests/data/cases/module_docstring_2.py | 4 | Lorem ipsum dolor sit amet, consectetur adipiscing elit, |
| LOW | tests/data/cases/module_docstring_2.py | 4 | Lorem ipsum dolor sit amet, consectetur adipiscing elit, |
| LOW | tests/data/cases/module_docstring_2.py | 42 | Lorem ipsum dolor sit amet, consectetur adipiscing elit, |
| LOW | tests/data/cases/module_docstring_2.py | 42 | Lorem ipsum dolor sit amet, consectetur adipiscing elit, |
| Severity | File | Line | Snippet |
|---|---|---|---|
| MEDIUM | tests/data/cases/pep_572_remove_parens.py | 45 | |
| MEDIUM | tests/data/cases/pep_572_remove_parens.py | 46 | |
| MEDIUM | tests/data/cases/pep_572_remove_parens.py | 47 | |
| MEDIUM | tests/data/cases/pep_572_remove_parens.py | 115 | |
| MEDIUM | tests/data/cases/pep_572_remove_parens.py | 116 | |
| MEDIUM | tests/data/cases/pep_572_remove_parens.py | 117 |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | src/black/lines.py | 781 | # Check if the if_stmt's next sibling is a same-name decorated function. |
| LOW | src/black/lines.py | 1380 | # Check if the opening bracket (last leaf of head) has comments that would merge |
| LOW | src/black/trans.py | 1592 | # Check if StringMerger registered any custom splits. |
| LOW | src/black/comments.py | 599 | # Check if there are semicolons in the body |
| Severity | File | Line | Snippet |
|---|---|---|---|
| MEDIUM | tests/test_black.py | 3099 | We don't (yet) formally expose an API (see issue #779), but we should endeavor to |
| LOW | scripts/fuzz.py | 60 | # (if you want only bounded fuzzing, just use `pytest fuzz.py`) |
| LOW | src/blib2to3/pgen2/pgen.py | 374 | # Can't just return self.arcs == other.arcs, because that |
| LOW | src/black/strings.py | 273 | # Do not introduce or remove backslashes in raw strings, just use double quote |