Skip to content

Commit 433a342

Browse files
authored
[flake8-executable] Add pytest and uv run to help message for shebang-missing-python (EXE003) (#16855)
Followup to #16849 per #16849 (comment)
1 parent 4ed93b4 commit 433a342

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

crates/ruff_linter/src/rules/flake8_executable/rules/shebang_missing_python.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ pub(crate) struct ShebangMissingPython;
3636
impl Violation for ShebangMissingPython {
3737
#[derive_message_formats]
3838
fn message(&self) -> String {
39-
"Shebang should contain `python`".to_string()
39+
"Shebang should contain `python`, `pytest`, or `uv run`".to_string()
4040
}
4141
}
4242

Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
---
22
source: crates/ruff_linter/src/rules/flake8_executable/mod.rs
33
---
4-
EXE003.py:1:1: EXE003 Shebang should contain `python`
4+
EXE003.py:1:1: EXE003 Shebang should contain `python`, `pytest`, or `uv run`
55
|
66
1 | #!/usr/bin/bash
77
| ^^^^^^^^^^^^^^^ EXE003
88
2 | print("hello world")
99
|
10-
11-

0 commit comments

Comments
 (0)