---
source: crates/ruff_linter/src/rules/isort/mod.rs
snapshot_kind: text
---
fit_line_length_comment.py:1:1: I001 [*] Import block is un-sorted or un-formatted
  |
1 | / import a
2 | | # Don't take this comment into account when determining whether the next import can fit on one line.
3 | | from b import c
4 | | from d import e  # Do take this comment into account when determining whether the next import can fit on one line.
5 | | # The next import fits on one line.
6 | | from f import g  # 012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ
7 | | # The next import doesn't fit on one line.
8 | | from h import i  # 012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9
  |
  = help: Organize imports

ℹ Safe fix
1  1  | import a
   2  |+
2  3  | # Don't take this comment into account when determining whether the next import can fit on one line.
3  4  | from b import c
4     |-from d import e  # Do take this comment into account when determining whether the next import can fit on one line.
   5  |+from d import (
   6  |+    e,  # Do take this comment into account when determining whether the next import can fit on one line.
   7  |+)
   8  |+
5  9  | # The next import fits on one line.
6  10 | from f import g  # 012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ
   11 |+
7  12 | # The next import doesn't fit on one line.
8     |-from h import i  # 012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9
   13 |+from h import (
   14 |+    i,  # 012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9012ß9💣2ℝ9
   15 |+)
