---
source: crates/ruff/src/rules/isort/mod.rs
---
preserve_indentation.py:2:1: I001 [*] Import block is un-sorted or un-formatted
  |
2 |   if True:
3 | /     import sys
4 | |     import os
5 | | else:
  | |_^ I001
6 |       import sys
7 |       import os
  |
  = help: Organize imports

ℹ Suggested fix
1 1 | if True:
  2 |+    import os
2 3 |     import sys
3   |-    import os
4 4 | else:
5 5 |     import sys
6 6 |     import os

preserve_indentation.py:5:1: I001 [*] Import block is un-sorted or un-formatted
  |
5 |       import os
6 |   else:
7 | /     import sys
8 | |     import os
  |
  = help: Organize imports

ℹ Suggested fix
2 2 |     import sys
3 3 |     import os
4 4 | else:
  5 |+    import os
5 6 |     import sys
6   |-    import os


