---
source: crates/ruff_linter/src/rules/pycodestyle/mod.rs
snapshot_kind: text
---
E30_isort.pyi:1:1: I001 [*] Import block is un-sorted or un-formatted
  |
1 | / import json
2 | | 
3 | | 
4 | | 
5 | | from typing import Any, Sequence
6 | | 
7 | | 
8 | | class MissingCommand(TypeError): ...  # noqa: N818
  | |_^ I001
  |
  = help: Organize imports

ℹ Safe fix
1 1 | import json
2   |-
3   |-
4   |-
5 2 | from typing import Any, Sequence
6   |-
7 3 | 
8 4 | class MissingCommand(TypeError): ...  # noqa: N818
9 5 | 

E30_isort.pyi:5:1: E303 [*] Too many blank lines (3)
  |
5 | from typing import Any, Sequence
  | ^^^^ E303
  |
  = help: Remove extraneous blank line(s)

ℹ Safe fix
1 1 | import json
2 2 | 
3   |-
4   |-
5 3 | from typing import Any, Sequence
6 4 | 
7 5 | 

E30_isort.pyi:8:1: E303 [*] Too many blank lines (2)
  |
8 | class MissingCommand(TypeError): ...  # noqa: N818
  | ^^^^^ E303
  |
  = help: Remove extraneous blank line(s)

ℹ Safe fix
4 4 | 
5 5 | from typing import Any, Sequence
6 6 | 
7   |-
8 7 | class MissingCommand(TypeError): ...  # noqa: N818
9 8 | 
10 9 | 

E30_isort.pyi:11:1: E303 [*] Too many blank lines (2)
   |
11 | class BackendProxy:
   | ^^^^^ E303
12 |     backend_module: str
13 |     backend_object: str | None
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
7  7  | 
8  8  | class MissingCommand(TypeError): ...  # noqa: N818
9  9  | 
10    |-
11 10 | class BackendProxy:
12 11 |     backend_module: str
13 12 |     backend_object: str | None

E30_isort.pyi:17:1: E303 [*] Too many blank lines (2)
   |
17 | if __name__ == "__main__":
   | ^^ E303
18 |     import abcd
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
13 13 |     backend_object: str | None
14 14 |     backend: Any
15 15 | 
16    |-
17 16 | if __name__ == "__main__":
18 17 |     import abcd
19 18 | 

E30_isort.pyi:21:5: E303 [*] Too many blank lines (2)
   |
21 |     abcd.foo()
   |     ^^^^ E303
22 | 
23 | def __init__(self, backend_module: str, backend_obj: str | None) -> None: ...
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
17 17 | if __name__ == "__main__":
18 18 |     import abcd
19 19 | 
20    |-
21 20 |     abcd.foo()
22 21 | 
23 22 | def __init__(self, backend_module: str, backend_obj: str | None) -> None: ...

E30_isort.pyi:26:1: I001 [*] Import block is un-sorted or un-formatted
   |
25 |   if TYPE_CHECKING:
26 | /     import os
27 | | 
28 | | 
29 | | 
30 | |     from typing_extensions import TypeAlias
31 | | 
   | |_^ I001
32 |   
33 |       abcd.foo()
   |
   = help: Organize imports

ℹ Safe fix
25 25 | if TYPE_CHECKING:
26 26 |     import os
27 27 | 
28    |-
29    |-
30 28 |     from typing_extensions import TypeAlias
31 29 | 
32 30 | 

E30_isort.pyi:30:5: E303 [*] Too many blank lines (3)
   |
30 |     from typing_extensions import TypeAlias
   |     ^^^^ E303
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
25 25 | if TYPE_CHECKING:
26 26 |     import os
27 27 | 
28    |-
29    |-
30 28 |     from typing_extensions import TypeAlias
31 29 | 
32 30 | 

E30_isort.pyi:33:5: E303 [*] Too many blank lines (2)
   |
33 |     abcd.foo()
   |     ^^^^ E303
34 | 
35 | def __call__(self, name: str, *args: Any, **kwargs: Any) -> Any:
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
29 29 | 
30 30 |     from typing_extensions import TypeAlias
31 31 | 
32    |-
33 32 |     abcd.foo()
34 33 | 
35 34 | def __call__(self, name: str, *args: Any, **kwargs: Any) -> Any:

E30_isort.pyi:45:1: E303 [*] Too many blank lines (2)
   |
45 | def _exit(self) -> None: ...
   | ^^^ E303
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
41 41 | def __call__2(self, name: str, *args: Any, **kwargs: Any) -> Any:
42 42 |     ...
43 43 | 
44    |-
45 44 | def _exit(self) -> None: ...
46 45 | 
47 46 | 

E30_isort.pyi:48:1: E303 [*] Too many blank lines (2)
   |
48 | def _optional_commands(self) -> dict[str, bool]: ...
   | ^^^ E303
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
44 44 | 
45 45 | def _exit(self) -> None: ...
46 46 | 
47    |-
48 47 | def _optional_commands(self) -> dict[str, bool]: ...
49 48 | 
50 49 | 

E30_isort.pyi:51:1: E303 [*] Too many blank lines (2)
   |
51 | def run(argv: Sequence[str]) -> int: ...
   | ^^^ E303
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
47 47 | 
48 48 | def _optional_commands(self) -> dict[str, bool]: ...
49 49 | 
50    |-
51 50 | def run(argv: Sequence[str]) -> int: ...
52 51 | 
53 52 | 

E30_isort.pyi:54:1: E303 [*] Too many blank lines (2)
   |
54 | def read_line(fd: int = 0) -> bytearray: ...
   | ^^^ E303
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
50 50 | 
51 51 | def run(argv: Sequence[str]) -> int: ...
52 52 | 
53    |-
54 53 | def read_line(fd: int = 0) -> bytearray: ...
55 54 | 
56 55 | 

E30_isort.pyi:57:1: E303 [*] Too many blank lines (2)
   |
57 | def flush() -> None: ...
   | ^^^ E303
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
53 53 | 
54 54 | def read_line(fd: int = 0) -> bytearray: ...
55 55 | 
56    |-
57 56 | def flush() -> None: ...
58 57 | 
59 58 | 

E30_isort.pyi:60:1: E303 [*] Too many blank lines (2)
   |
60 | from typing import Any, Sequence
   | ^^^^ E303
61 | 
62 | class MissingCommand(TypeError): ...  # noqa: N818
   |
   = help: Remove extraneous blank line(s)

ℹ Safe fix
56 56 | 
57 57 | def flush() -> None: ...
58 58 | 
59    |-
60 59 | from typing import Any, Sequence
61 60 | 
62 61 | class MissingCommand(TypeError): ...  # noqa: N818
