Skip to content

Commit 43e85ee

Browse files
[pre-commit.ci] pre-commit autoupdate (#276)
* [pre-commit.ci] pre-commit autoupdate updates: - [github.com/rbubley/mirrors-prettier: bc7af46104f0f5368b95878decf720f9f00c2559 → 787fb9f542b140ba0b2aced38e6a3e68021647a3](rbubley/mirrors-prettier@bc7af46...787fb9f) - [github.com/astral-sh/ruff-pre-commit: 89c421dff2e1026ba12cdb9ebd731f4a83aa8021 → 971923581912ef60a6b70dbf0c3e9a39563c9d47](astral-sh/ruff-pre-commit@89c421d...9719235) - [github.com/pre-commit/mirrors-mypy: bbc3dc1f890007061f18f17e2334f216ea9e5df7 → f40886d54c729f533f864ed6ce584e920feb0af7](pre-commit/mirrors-mypy@bbc3dc1...f40886d) - [github.com/codespell-project/codespell: 193cd7d27cd571f79358af09a8fb8997e54f8fff → 63c8f8312b7559622c0d82815639671ae42132ac](codespell-project/codespell@193cd7d...63c8f83) * '[pre-commit.ci 🤖] Apply code format tools to PR' --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent 88f47c7 commit 43e85ee

File tree

4 files changed

+23
-23
lines changed

4 files changed

+23
-23
lines changed

.pre-commit-config.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,14 @@ repos:
2525
- id: trailing-whitespace
2626

2727
- repo: https://github.com/rbubley/mirrors-prettier
28-
rev: bc7af46104f0f5368b95878decf720f9f00c2559 # frozen: v3.4.2
28+
rev: 787fb9f542b140ba0b2aced38e6a3e68021647a3 # frozen: v3.5.3
2929
hooks:
3030
- id: prettier
3131
files: \.(css|html|md|yml|yaml|toml)
3232
args: [--prose-wrap=preserve]
3333

3434
- repo: https://github.com/astral-sh/ruff-pre-commit
35-
rev: 89c421dff2e1026ba12cdb9ebd731f4a83aa8021 # frozen: v0.8.6
35+
rev: 971923581912ef60a6b70dbf0c3e9a39563c9d47 # frozen: v0.11.4
3636
hooks:
3737
- id: ruff
3838
args: ["--fix", "--show-fixes", "--exit-non-zero-on-fix"]
@@ -44,7 +44,7 @@ repos:
4444
- id: blacken-docs
4545

4646
- repo: https://github.com/pre-commit/mirrors-mypy
47-
rev: bbc3dc1f890007061f18f17e2334f216ea9e5df7 # frozen: v1.14.1
47+
rev: f40886d54c729f533f864ed6ce584e920feb0af7 # frozen: v1.15.0
4848
hooks:
4949
- id: mypy
5050
exclude: |
@@ -53,7 +53,7 @@ repos:
5353
)
5454
5555
- repo: https://github.com/codespell-project/codespell
56-
rev: "193cd7d27cd571f79358af09a8fb8997e54f8fff" # frozen: v2.3.0
56+
rev: "63c8f8312b7559622c0d82815639671ae42132ac" # frozen: v2.4.1
5757
hooks:
5858
- id: codespell
5959
args: ["-L", "ans"]

spin/cmds/meson.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -989,7 +989,7 @@ def docs(
989989

990990
if site_path:
991991
os.environ["PYTHONPATH"] = (
992-
f'{site_path}{os.sep}:{os.environ.get("PYTHONPATH", "")}'
992+
f"{site_path}{os.sep}:{os.environ.get('PYTHONPATH', '')}"
993993
)
994994
click.secho(
995995
f"$ export PYTHONPATH={os.environ['PYTHONPATH']}",

spin/tests/test_build_cmds.py

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ def test_basic_build(example_pkg):
2323
spin("build")
2424

2525
assert Path("build").exists(), "`build` folder not created after `spin build`"
26-
assert Path(
27-
"build-install"
28-
).exists(), "`build-install` folder not created after `spin build`"
26+
assert Path("build-install").exists(), (
27+
"`build-install` folder not created after `spin build`"
28+
)
2929

3030

3131
def test_debug_builds(example_pkg):
@@ -64,17 +64,17 @@ def test_coverage_reports(example_pkg, report_type, output_file):
6464
spin("test", "--gcov", f"--gcov-format={report_type}")
6565

6666
coverage_report = Path("./build/meson-logs", output_file)
67-
assert (
68-
coverage_report.exists()
69-
), f"coverage report not generated for gcov build ({report_type})"
67+
assert coverage_report.exists(), (
68+
f"coverage report not generated for gcov build ({report_type})"
69+
)
7070

7171

7272
def test_expand_pythonpath(example_pkg):
7373
"""Does an $ENV_VAR get expanded in `spin run`?"""
7474
output = spin("run", "echo $PYTHONPATH")
75-
assert any(
76-
p in stdout(output) for p in ("site-packages", "dist-packages")
77-
), f"Expected value of $PYTHONPATH, got {stdout(output)} instead"
75+
assert any(p in stdout(output) for p in ("site-packages", "dist-packages")), (
76+
f"Expected value of $PYTHONPATH, got {stdout(output)} instead"
77+
)
7878

7979

8080
def test_run_stdout(example_pkg):
@@ -85,9 +85,9 @@ def test_run_stdout(example_pkg):
8585
"-c",
8686
"import sys; del sys.path[0]; import example_pkg; print(example_pkg.__version__)",
8787
)
88-
assert (
89-
stdout(p) == "0.0.0dev0"
90-
), f"`spin run` stdout did not yield version, but {stdout(p)}"
88+
assert stdout(p) == "0.0.0dev0", (
89+
f"`spin run` stdout did not yield version, but {stdout(p)}"
90+
)
9191

9292

9393
# Detecting whether a file is executable is not that easy on Windows,
@@ -97,9 +97,9 @@ def test_recommend_run_python(example_pkg):
9797
"""If `spin run file.py` is called, is `spin run python file.py` recommended?"""
9898
with tempfile.NamedTemporaryFile(suffix=".py") as f:
9999
p = spin("run", f.name, sys_exit=False)
100-
assert "Did you mean to call" in stdout(
101-
p
102-
), "Failed to recommend `python run python file.py`"
100+
assert "Did you mean to call" in stdout(p), (
101+
"Failed to recommend `python run python file.py`"
102+
)
103103

104104

105105
def test_sdist(example_pkg):

spin/tests/test_editable.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33

44
def test_detect_editable(example_pkg, editable_install):
5-
assert "Editable install of same source detected" in stdout(
6-
spin("build")
7-
), "Failed to detect and warn about editable install"
5+
assert "Editable install of same source detected" in stdout(spin("build")), (
6+
"Failed to detect and warn about editable install"
7+
)
88

99

1010
def test_editable_tests(example_pkg, editable_install):

0 commit comments

Comments
 (0)