Skip to content

Commit 9291222

Browse files
authored
🩹 prevent lock update with tools and uv setup guide (#254)
* 🐛 prevent lock update during tool runs * 📝 `uv` in the contribution guide * 📝 fix the `uv` guidelines
1 parent 16986c0 commit 9291222

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

CONTRIBUTING.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -182,12 +182,11 @@ Enhancement suggestions are tracked as [GitHub issues][bug].
182182

183183
### Your First Code Contribution
184184

185-
Ensure you have [`poetry`](https://python-poetry.org/docs/#installation) and
186-
[`poe`](https://poethepoet.natn.io/installation.html) installed.
187-
Now you can install the dev dependencies:
185+
Ensure you have [`uv`](https://docs.astral.sh/uv/getting-started/installation/) installed.
186+
Now you can install the project with the dev dependencies:
188187

189188
```bash
190-
poetry install
189+
uv sync --frozen
191190
```
192191

193192
### pre-commit

pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,20 +125,20 @@ lint = ["check", "format"]
125125
pre-commit = "pre-commit run --all-files"
126126

127127
_test_bpr = "basedpyright tests"
128-
_test_mypy = "uv run --no-editable --isolated mypy --config-file=pyproject.toml tests"
128+
_test_mypy = "uv run --frozen --no-editable --isolated mypy --config-file=pyproject.toml tests"
129129
typetest = ["_test_bpr", "_test_mypy"]
130130

131131
[tool.poe.tasks.pyright]
132132
cmd = "basedpyright $path"
133133
args = [{name = "path", positional = true, multiple = true, default = "scipy-stubs codegen"}]
134134

135135
[tool.poe.tasks.mypy]
136-
cmd = "uv run --no-editable --isolated mypy --config-file=pyproject.toml $path"
136+
cmd = "uv run --frozen --no-editable --isolated mypy --config-file=pyproject.toml $path"
137137
args = [{name = "path", positional = true, multiple = true, default = "scipy-stubs codegen"}]
138138

139139
[tool.poe.tasks.stubtest]
140140
cmd = """
141-
uv run --no-editable --isolated
141+
uv run --frozen --no-editable --isolated
142142
stubtest
143143
--mypy-config-file=pyproject.toml
144144
--allowlist=.mypyignore

0 commit comments

Comments
 (0)