Skip to content

Commit 34b3b52

Browse files
Disable EM rule (#539)
1 parent 3314678 commit 34b3b52

File tree

5 files changed

+5
-6
lines changed

5 files changed

+5
-6
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ $ uvx usethis tool ruff
8282
✔ Writing 'pyproject.toml'.
8383
✔ Adding dependency 'ruff' to the 'dev' group in 'pyproject.toml'.
8484
✔ Adding Ruff config to 'pyproject.toml'.
85-
✔ Enabling Ruff rules 'A', 'C4', 'E4', 'E7', 'E9', 'EM', 'F', 'FLY', 'FURB', 'I', 'PLE', 'PLR', 'RUF', 'SIM', 'UP' in 'pyproject.toml'.
85+
✔ Enabling Ruff rules 'A', 'C4', 'E4', 'E7', 'E9', 'F', 'FLY', 'FURB', 'I', 'PLE', 'PLR', 'RUF', 'SIM', 'UP' in 'pyproject.toml'.
8686
✔ Ignoring Ruff rules 'PLR2004', 'SIM108' in 'pyproject.toml'.
8787
☐ Run 'uv run ruff check --fix' to run the Ruff linter with autofixes.
8888
☐ Run 'uv run ruff format' to run the Ruff formatter.

src/usethis/_core/tool.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,6 @@ def use_ruff(*, remove: bool = False, minimal: bool = False) -> None:
343343
"E4",
344344
"E7",
345345
"E9",
346-
"EM",
347346
"F",
348347
"FLY",
349348
"FURB",

tests/usethis/_core/test_core_tool.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2532,7 +2532,7 @@ def test_stdout(self, uv_init_dir: Path, capfd: pytest.CaptureFixture[str]):
25322532
"✔ Adding dependency 'ruff' to the 'dev' group in 'pyproject.toml'.\n"
25332533
"☐ Install the dependency 'ruff'.\n"
25342534
"✔ Adding Ruff config to 'pyproject.toml'.\n"
2535-
"✔ Enabling Ruff rules 'A', 'C4', 'E4', 'E7', 'E9', 'EM', 'F', 'FLY', 'FURB', \n'I', 'PLE', 'PLR', 'RUF', 'SIM', 'UP' in 'pyproject.toml'.\n"
2535+
"✔ Enabling Ruff rules 'A', 'C4', 'E4', 'E7', 'E9', 'F', 'FLY', 'FURB', 'I', \n'PLE', 'PLR', 'RUF', 'SIM', 'UP' in 'pyproject.toml'.\n"
25362536
"✔ Ignoring Ruff rules 'PLR2004', 'SIM108' in 'pyproject.toml'.\n"
25372537
"☐ Run 'ruff check --fix' to run the Ruff linter with autofixes.\n"
25382538
"☐ Run 'ruff format' to run the Ruff formatter.\n"

tests/usethis/_core/test_docstyle.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ def test_adding_ruff_afterwards_allows_default_rules(self, tmp_path: Path):
185185
== """\
186186
line-length = 88
187187
[lint]
188-
select = ["D2", "D3", "D4", "A", "C4", "E4", "E7", "E9", "EM", "F", "FLY", "FURB", "I", "PLE", "PLR", "RUF", "SIM", "UP"]
188+
select = ["D2", "D3", "D4", "A", "C4", "E4", "E7", "E9", "F", "FLY", "FURB", "I", "PLE", "PLR", "RUF", "SIM", "UP"]
189189
ignore = ["PLR2004", "SIM108"]
190190
[lint.pydocstyle]
191191
convention = "numpy"

tests/usethis/_interface/test_tool.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,8 +174,8 @@ def test_readme_example(self, tmp_path: Path):
174174
✔ Writing 'pyproject.toml'.
175175
✔ Adding dependency 'ruff' to the 'dev' group in 'pyproject.toml'.
176176
✔ Adding Ruff config to 'pyproject.toml'.
177-
✔ Enabling Ruff rules 'A', 'C4', 'E4', 'E7', 'E9', 'EM', 'F', 'FLY', 'FURB',
178-
'I', 'PLE', 'PLR', 'RUF', 'SIM', 'UP' in 'pyproject.toml'.
177+
✔ Enabling Ruff rules 'A', 'C4', 'E4', 'E7', 'E9', 'F', 'FLY', 'FURB', 'I',
178+
'PLE', 'PLR', 'RUF', 'SIM', 'UP' in 'pyproject.toml'.
179179
✔ Ignoring Ruff rules 'PLR2004', 'SIM108' in 'pyproject.toml'.
180180
☐ Run 'uv run ruff check --fix' to run the Ruff linter with autofixes.
181181
☐ Run 'uv run ruff format' to run the Ruff formatter.

0 commit comments

Comments
 (0)