Extract backend tests workflow and remove docker layer#4635
Extract backend tests workflow and remove docker layer#4635ahmedxgouda wants to merge 8 commits into
Conversation
|
ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
Summary by CodeRabbit
WalkthroughExtracts backend test steps into a reusable ChangesBackend Tests Workflow Extraction
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
Suggested reviewers
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: The best way for teams to turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. 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.
1 issue found across 2 files
Confidence score: 2/5
- There is a high-confidence, high-severity CI risk in
.github/workflows/run-ci-cd.yaml:run-backend-testsis called without job-levelpermissionswhile top-levelpermissions: {}is set. - This can block the reusable workflow from getting required
contents: readandid-token: writescopes, making backend test execution and related pipeline steps likely to fail. - Given the concrete misconfiguration and likely pipeline regression, this is higher merge risk until permissions are explicitly set on the job call.
- Pay close attention to
.github/workflows/run-ci-cd.yaml- missing job-level permissions can prevent the called workflow from obtaining required scopes.
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name=".github/workflows/run-ci-cd.yaml">
<violation number="1" location=".github/workflows/run-ci-cd.yaml:38">
P1: The reusable `run-backend-tests` call is missing job-level `permissions`, so with top-level `permissions: {}` the called workflow cannot obtain its required `contents: read` and `id-token: write` scopes.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## feature/ci-cd-optimization #4635 +/- ##
===========================================================
Coverage 98.92% 98.92%
===========================================================
Files 527 527
Lines 16956 16956
Branches 2360 2360
===========================================================
Hits 16774 16774
Misses 97 97
Partials 85 85
Flags with carried forward coverage won't be shown. Click here to find out more. Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
a7d3511
There was a problem hiding this comment.
1 issue found across 1 file (changes from recent commits).
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name=".github/workflows/run-backend-tests.yaml">
<violation number="1" location=".github/workflows/run-backend-tests.yaml:36">
P2: The cache path points to the wrong directory. Poetry creates the venv in `backend/.venv`, so caching `./.venv` won’t cache the environment used by tests.</violation>
</file>
Tip: Review your code locally with the cubic CLI to iterate faster.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.github/workflows/run-backend-tests.yaml:
- Line 44: The workflow contains an unused command "touch
.venv/dependencies_installed" which creates a file never referenced later;
remove that line from the run-backend-tests.yaml job to clean up dead code
(search for the exact string "touch .venv/dependencies_installed" and delete the
command).
🪄 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: 0835ca37-82c9-449c-b787-a3b1261d2190
📒 Files selected for processing (2)
.github/workflows/run-backend-tests.yaml.github/workflows/run-ci-cd.yaml
9863bfe
|



Proposed change
Resolves #4634
Extracted backend tests workflow and removed docker layer
Checklist
make check-testlocally: all warnings addressed, tests passed