---
source: crates/ruff_linter/src/rules/flake8_pyi/mod.rs
---
PYI009.pyi:3:5: PYI009 [*] Empty body should contain `...`, not `pass`
  |
1 | def bar(): ...  # OK
2 | def foo():
3 |     pass  # ERROR PYI009, since we're in a stub file
  |     ^^^^ PYI009
4 | 
5 | class Bar: ...  # OK
  |
  = help: Replace `pass` with `...`

ℹ Safe fix
1 1 | def bar(): ...  # OK
2 2 | def foo():
3   |-    pass  # ERROR PYI009, since we're in a stub file
  3 |+    ...  # ERROR PYI009, since we're in a stub file
4 4 | 
5 5 | class Bar: ...  # OK
6 6 | 

PYI009.pyi:8:5: PYI009 [*] Empty body should contain `...`, not `pass`
  |
7 | class Foo:
8 |     pass  # ERROR PYI009, since we're in a stub file
  |     ^^^^ PYI009
  |
  = help: Replace `pass` with `...`

ℹ Safe fix
5 5 | class Bar: ...  # OK
6 6 | 
7 7 | class Foo:
8   |-    pass  # ERROR PYI009, since we're in a stub file
  8 |+    ...  # ERROR PYI009, since we're in a stub file


