Skip to content

Commit 3077ae4

Browse files
committed
Update mypy and add --no-sync throughout ci.yaml
1 parent 8ec7db4 commit 3077ae4

4 files changed

Lines changed: 9 additions & 11 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
uv-dependency-install-flags: "--all-extras --group dev"
2424
- name: mypy
2525
run: |
26-
MYPYPATH=stubs uv run mypy src
26+
MYPYPATH=stubs uv run --no-sync mypy src
2727
2828
docs:
2929
if: ${{ !github.event.pull_request.draft }}
@@ -41,16 +41,16 @@ jobs:
4141
uv-dependency-install-flags: "--all-extras --group docs"
4242
- name: docs
4343
run: |
44-
uv run mkdocs build --strict
44+
uv run --no-sync mkdocs build --strict
4545
- uses: ./.github/actions/setup
4646
with:
4747
python-version: "3.11"
4848
uv-dependency-install-flags: "--all-extras --group docs --group dev"
4949
- name: docs-with-changelog
5050
run: |
5151
# Check CHANGELOG will build too
52-
uv run towncrier build --yes
53-
uv run mkdocs build --strict
52+
uv run --no-sync towncrier build --yes
53+
uv run --no-sync mkdocs build --strict
5454
# Just in case, undo the staged changes
5555
git restore --staged . && git restore .
5656
@@ -230,7 +230,7 @@ jobs:
230230
python-version: ${{ matrix.python-version }}
231231
- name: Build package
232232
run: |
233-
uv run python scripts/add-locked-targets-to-pyproject-toml.py
233+
uv run --no-sync python scripts/add-locked-targets-to-pyproject-toml.py
234234
cat pyproject.toml
235235
uv build
236236
# Just in case, undo the changes to `pyproject.toml`
@@ -258,5 +258,5 @@ jobs:
258258
run: |
259259
TEMP_FILE=$(mktemp)
260260
uv export --no-dev > $TEMP_FILE
261-
uv run liccheck -r $TEMP_FILE -R licence-check.txt
261+
uv run --no-sync liccheck -r $TEMP_FILE -R licence-check.txt
262262
cat licence-check.txt

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ help: ## print short description of each target
2828

2929
.PHONY: checks
3030
checks: ## run all the linting checks of the codebase
31-
@echo "=== pre-commit ==="; uv run pre-commit run --all-files || echo "--- pre-commit failed ---" >&2; \
32-
echo "=== mypy ==="; MYPYPATH=stubs uv run mypy src || echo "--- mypy failed ---" >&2; \
31+
@echo "=== pre-commit ==="; uv run --no-sync pre-commit run --all-files || echo "--- pre-commit failed ---" >&2; \
32+
echo "=== mypy ==="; MYPYPATH=stubs uv run --no-sync mypy src || echo "--- mypy failed ---" >&2; \
3333
echo "======"
3434

3535
.PHONY: ruff-fixes

src/example_fgen_basic/__init__.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,3 @@
55
import importlib.metadata
66

77
__version__ = importlib.metadata.version("example_fgen_basic")
8-
9-
__all__ = []

src/example_fgen_basic/get_wavelength.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def get_wavelength_plain(frequency: float) -> float:
3535
:
3636
Wavelength of light for given `frequency`
3737
"""
38-
res = m_get_wavelength_w.get_wavelength(frequency)
38+
res: float = m_get_wavelength_w.get_wavelength(frequency)
3939

4040
return res
4141

0 commit comments

Comments
 (0)