Repository navigation
dev: move every check into one noxfile - #4208
Open
oresttokovenko wants to merge 8 commits into
Open
oresttokovenko wants to merge 8 commits into
oresttokovenko wants to merge 8 commits into
Conversation
This was referenced Oct 30, 2026
Collaborator
|
Part of the CI failures will be fixed by #4216 |
The Makefile, the pre-commit config, and the CI workflows each described the same checks in their own way, and tool versions were pinned in two of them. One noxfile now holds the sessions, the justfile names them, and CI runs the same sessions a developer runs locally.
The sdist carries no .gitignore, and release verification loads the noxfile from an unpacked sdist, so the read must tolerate its absence.
The justfile is a convenience for local runs. CI has no reason to install a task runner to reach the sessions it already names.
`uv run` syncs the project environment on demand, and the test and coverage sessions build their own environments from uv.lock, so the explicit install only synced the extras a second time.
The wrapper named every member after the string it held, and only two of the six reached a call site, so it added a lookup without removing a literal.
Those files are not new: the Makefile ran coverage with --parallel-mode as well, and noxfile's clean session still removes them.
coverage already reads [tool.coverage.run] source from pyproject.toml, so the session stops repeating --source, and the 85 default moves next to it as [tool.coverage.report] fail_under. COVERAGE_FAIL_UNDER still overrides it, because the integration job accepts lower coverage than the unit suite.
oresttokovenko
force-pushed
the
migrate-tooling-to-nox-just
branch
from
October 31, 2026 22:31
3c7a297 to
1cf216c
Compare
mypy finds the config file on its own, so --config-file was redundant, and --scripts-are-modules is a setting rather than an invocation choice.
oresttokovenko
force-pushed
the
migrate-tooling-to-nox-just
branch
from
October 31, 2026 22:36
1cf216c to
5486c97
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
This change replaces
Makefileand.pre-commit-config.yamlwith a singlenoxfile.py, and leaves thejustfileas a thin entry point with one command line per recipe. CI now calls the same nox sessions that a developer runs locally, so there is one place to look when a check fails.noxfile.pydefines 24 sessions, six of which form the gate while the rest are test suites and local actionsjustfileholds no logic and is 141 lines longpyproject.tomlanduv.lockonly, so each session installs the dependency group it needs by namepyproject.tomlrather than from a workflow matrixThis is not the shortest way to write this file, because I copied the old behaviour first. The pre-commit hooks let
pre-commitchoose the files to check, which nox does not do, sonoxfile.pycarries helpers that walk the tree, read.gitignore, and separate text files from binary ones. This will be cleaned in up in a future commit.Also, I've had added new dependencies groups into the project so that nox sessions install only what they need, this makes the sessions faster and less prone to weird bugs.
Why
This is an effort to modernize/centralize dev tooling, reduce version drift, and make the project easier to reason about/improve the dev experience. Currently three files describe the same checks in three different ways and contain some logic in them, so learning what CI runs meant opening the
Makefile, then.pre-commit-config.yaml, and then the workflow.Pre-commit adds another YAML-based configuration layer instead of respecting
pyproject.toml, and the maintainers have explicitly declined to supportpyproject.tomlconfiguration . That leaves hook definitions, versions, and additional dependencies outside the dependency configuration used by the rest of the project, which causes version drift. In addition, commands were sometimes nested: CI ranmake lintwhich ranprek run -a, which ran a hook, which ran a tool in an environment that pre-commit had built, etc. This introduces many opportunities for misalignment between local and CI results.The mypy hook is a concrete example. Its isolated environment and pre-commit's tracked-file selection do not match a direct mypy cli run from the development environment, so for example a passing hook cannot serve as an apples to apples baseline for comparing a potential mypy with ty migration.
With this PR, the logic exists in one place, in Python, and reads native dependencies, so a version bump touches
pyproject.tomlanduv.lockand nothing else. CI and local development invoke the same nox sessions with the same files and dependenciesWhere the old recipes and checks live now
Makefile targets:
helpjust --listinstall-uvjust install-uvinstalljust installinstallcheck-licensejust check-licensedev/check-licenseunchangedlintjust check,just fixtestjust testtests-3.11totests-3.14test-integrationjust test-integrationintegrationtest-integration-setupjust test-integration_start_servicestest-integration-execjust test-integration_pytesttest-integration-cleanupjust test-integration_stop_servicestest-integration-rebuildjust test-integration-rebuildintegration-rebuildtest-s3just test-s3s3test-adlsjust test-adlsadlstest-gcsjust test-gcsgcstest-coveragejust test-coveragetests,integration,s3,adls,gcs, thencoveragecoverage-reportjust coverage-reportcoveragetest-notebookjust test-notebooktest-notebookdocs-servejust docs-servedocs-servedocs-buildjust docs-builddocs-buildnotebookjust notebooknotebooknotebook-infrajust notebook-infranotebook-infracleanjust cleancleanPre-commit hooks:
trailing-whitespacehygieneend-of-file-fixerhygienecheck-yamlhygienecheck-asthygienerufflintruff-formatformatnbqa-rufflintmypytypecheck-mypytytypecheck-ty, local and experimentalmarkdownlintmarkdownlintcodespellcodespelluv-lockjust lock-checkBehaviour changes
just checkbefore you push, which is exactly what CI runs.just checkwrites no files, whilejust fixapplies the fixes.just install --force-python 3.12, default runs the python version matrixdefault=False, so a new check session joins it by default instead of needing a second registration.rumdlfrom PyPI, which reads the existing.markdownlint.yamland avoids a Node.js install. RuleMD057stays off because thereference/pages are generated by mkdocstrings at build time.check-yamlruns with--unsafebecausemkdocs/mkdocs.ymluses the!!python/name:tag.mypychecks every tracked Python file again, 215 in total and with--scripts-are-modules; an earlier draft of this change had narrowed it to the package alone.hive-kerberosextra, which pullskerberos, a package that publishes no Windows wheels and would need MIT Kerberos headers the runner does not have.pyiceberg.avro.decoder_fast.notebook-infrastops the Docker services when JupyterLab exits, unlessKEEP_COMPOSE=1asks to keep them.Small fixes the port needed
.gitignoreonly if the file is there, because the sdist does not ship one anddev/release/verify_rc.shrunsjust installandjust test-coveragefrom inside an unpacked sdist.Tests
just checkruns six sessions in about 13 seconds and is green.just testruns the four interpreters in parallel: 37 seconds on a cold tree, and the full unit suite on 3.13 takes a minute.just install --force-python 3.12 -- --dry-runprintsuv sync --all-extras --python 3.12while the plain form leaves the environment alone, andjust docs-buildbuilds in seven seconds.just cleanthenjust installrebuilds from an empty tree, an unpacked sdist lets nox read the noxfile, and a deliberately dirty Markdown file failsjust checkwhile a clean one passes.