[ISSUE-15] Add offline e2e fixtures and modernize core CI (pytest + Ruff)#83
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 26c3e12c55
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| - name: Ruff check | ||
| run: ruff check . | ||
| - name: Ruff format check | ||
| run: ruff format --check . |
There was a problem hiding this comment.
Limit Ruff CI gates to files that are currently clean
This workflow makes the core job fail before tests even run because it lints and formats the entire repository (ruff check . and ruff format --check .), while the repo still has existing violations outside this change set. I verified in this tree that both commands exit non-zero (e.g., lint errors in files/ and notebooks, and 36 files needing reformat), and ruff check --help confirms it exits with status 1 when diagnostics are found unless --exit-zero is used. As written, every push/PR on these branches will report failing CI even when pytest tests/unit tests/stages tests/integration passes.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Summary
- Updated the CI workflow to scope Ruff lint gating to the offline core test surface (
tests/conftest.py,tests/unit,tests/stages,tests/integration) so unrelated repository lint debt no longer blocks this PR’s core pipeline. - Removed the
ruff format --checkgate from this workflow as part of the follow-up fix, while keeping the core pytest gate intact. - Committed the change on the current branch with commit
f328c1fand created a follow-up PR message viamake_prsummarizing these updates.
Testing
- ✅
ruff check tests/conftest.py tests/unit tests/stages tests/integration - ✅
pytest -q tests/unit tests/stages tests/integration - ✅
git add .github/workflows/ci.yml && git commit -m "ci: scope ruff gate to offline core test paths"
Web check performed
- ✅ Searched Ruff’s official docs to confirm exit-code behavior and gate semantics: https://docs.astral.sh/ruff/linter/ and https://docs.astral.sh/ruff/formatter/
Motivation
pytestandruffthat runs only compiler tests (unit,stages,integration).Description
.github/workflows/ci.ymlthat installs the package with test extras and runsruff check .,ruff format --check ., andpytest tests/unit tests/stages tests/integrationon Python 3.10/3.11.pyproject.tomltopytest>=7,<9and add a pytest marker configuration forautomationtests under[tool.pytest.ini_options].tests/conftest.py(in-memorysbol2.Document,default_build_options,minimal_lvl2_request) and add integration teststests/integration/test_full_build_happy_path.pyandtests/integration/test_missing_lvl1_then_domestication.pythat run offline using fake stage implementations.tests/stages/, a unit import boundary testtests/unit/test_core_imports.py(ensures optional automation deps are not side-effect imported), optional/manual automation placeholdertests/automation/test_opentrons_simulation_optional.py, and docstests/README.mdandRELEASE_CHECKLIST.md.Testing
python -c "from buildcompiler.api import BuildCompiler, full_build",python -c "from buildcompiler.execution import BuildContext, FullBuildExecutor", andpython -c "from buildcompiler.reporting import BuildSummary, BuildReport, BuildGraph"and the PUDU adapter imports; these succeeded.pytest tests/unit tests/stages tests/integrationand observed all core tests pass (89 passedin ~0.44s) verifying the new integration and orchestration fixtures succeeded.ruff check .as part of validation and it failed due to pre-existing repository lint debt outside this issue scope (legacy files/notebooks); this is noted and left for separate cleanup.uv run ...verification and it failed while installing the optional automation git dependencySBOLInventorydue to environment/network restrictions (git fetch HTTP 403), confirming automation extras remain optional and are not required by core CI.Codex Task