ci: add GitHub Actions CI workflow with python matrix#82
ci: add GitHub Actions CI workflow with python matrix#82chaitanyamedidar wants to merge 2 commits intoAOSSIE-Org:mainfrom
Conversation
WalkthroughRenamed CI job to Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Suggested labels
Poem
🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
pyproject.toml (1)
29-33: 🧹 Nitpick | 🔵 TrivialKeep optional-dependencies and dependency-groups in sync.
The
devdependencies are now declared in both[project.optional-dependencies](for pip) and[dependency-groups](for uv/PEP 735). This duplication is intentional per the PR description, but consider adding a comment noting they should stay synchronized to prevent future drift.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@pyproject.toml` around lines 29 - 33, Add a short explanatory comment near the duplicated dependency definitions to remind future maintainers to keep them synchronized: annotate the [project.optional-dependencies] "dev" entry and the [dependency-groups] "dev" entry with a one-line comment stating they are intentionally duplicated and must be kept in sync (mentioning pip vs PEP 735/uv). This uses the existing "dev" key in both sections to make the intent explicit and prevent drift.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.github/workflows/ci.yml:
- Around line 12-14: CI tests currently target python-version in the GitHub
Actions matrix ["3.10","3.11","3.12"] while pyproject.toml declares
requires-python = ">=3.9"; update the CI matrix to include "3.9" (add "3.9" to
the python-version array in the workflow strategy.matrix) so the declared
minimum supported Python is tested, or alternatively change the requires-python
in pyproject.toml to ">=3.10" if you intend to drop 3.9 support—adjust either
the python-version matrix entry or the requires-python value accordingly.
- Around line 12-14: The CI matrix currently uses the strategy.matrix
(python-version: ["3.10", "3.11", "3.12"]) which defaults to fail-fast; add a
fail-fast: false setting under the strategy block so the workflow runs all
matrix jobs even if one fails. Locate the strategy -> matrix configuration and
insert fail-fast: false at the same level as matrix (i.e., sibling to matrix) to
ensure all Python-version jobs complete and report results.
---
Outside diff comments:
In `@pyproject.toml`:
- Around line 29-33: Add a short explanatory comment near the duplicated
dependency definitions to remind future maintainers to keep them synchronized:
annotate the [project.optional-dependencies] "dev" entry and the
[dependency-groups] "dev" entry with a one-line comment stating they are
intentionally duplicated and must be kept in sync (mentioning pip vs PEP
735/uv). This uses the existing "dev" key in both sections to make the intent
explicit and prevent drift.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 5564687a-6129-4163-a371-f4c9e8396587
📒 Files selected for processing (2)
.github/workflows/ci.ymlpyproject.toml
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@pyproject.toml`:
- Around line 20-26: Add an automated parity check so the duplicated dev lists
in pyproject.toml cannot drift: implement a small script (e.g., check_dev_deps)
that parses pyproject.toml, compares the arrays at
[project.optional-dependencies].dev and [dependency-groups].dev (or equivalent
keys), and exits non‑zero with a clear message if they differ; wire that script
into CI as a pre-merge job so mismatches fail fast. Locate the two sections by
their section names in the file (project.optional-dependencies and
dependency-groups) and ensure the check normalizes ordering/quotes before
comparing to avoid false positives.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 6738bce5-3e28-454a-9b12-86b40a9f3c8e
📒 Files selected for processing (2)
.github/workflows/ci.ymlpyproject.toml
| # Intentionally duplicated from [dependency-groups] below. | ||
| # pip uses this section; uv/PEP 735 uses [dependency-groups]. Keep both in sync. | ||
| [project.optional-dependencies] | ||
| dev = [ | ||
| "pytest>=7.0", | ||
| "ruff>=0.15.4", | ||
| ] |
There was a problem hiding this comment.
🧹 Nitpick | 🔵 Trivial
Protect the duplicated dev dependency lists from drift.
[project.optional-dependencies].dev and [dependency-groups].dev are now separate sources of truth. Comments alone won't prevent them from diverging, and once they do CI and local development will resolve different toolchains. Add a small parity check in CI or a helper script so mismatches fail fast.
Also applies to: 31-37
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@pyproject.toml` around lines 20 - 26, Add an automated parity check so the
duplicated dev lists in pyproject.toml cannot drift: implement a small script
(e.g., check_dev_deps) that parses pyproject.toml, compares the arrays at
[project.optional-dependencies].dev and [dependency-groups].dev (or equivalent
keys), and exits non‑zero with a clear message if they differ; wire that script
into CI as a pre-merge job so mismatches fail fast. Locate the two sections by
their section names in the file (project.optional-dependencies and
dependency-groups) and ensure the check normalizes ordering/quotes before
comparing to avoid false positives.
Addressed Issues:
Repair and Enhance CI workflow with test job and python workflow
fixes the broken existing ci.yml which had
no test job, no matrix strategy, and a broken uv-based install
The existing ci.yml had several problems:
uv sync --lockedwhich failed to resolve dev dependencies declared under[dependency-groups](PEP 735) when using pipScreenshots/Recordings:
Additional Notes:
This PR replaces it with a clean, minimal workflow that:
pip install -e ".[dev]"[project.optional-dependencies]to pyproject.toml so theabove install command resolves correctly alongside the existing
[dependency-groups]block which uv contributors can still useChecklist
We encourage contributors to use AI tools responsibly when creating Pull Requests. While AI can be a valuable aid, it is essential to ensure that your contributions meet the task requirements, build successfully, include relevant tests, and pass all linters. Submissions that do not meet these standards may be closed without warning to maintain the quality and integrity of the project. Please take the time to understand the changes you are proposing and their impact.
Summary by CodeRabbit