-
Notifications
You must be signed in to change notification settings - Fork 164
Issue 985 - Skip other jobs if any of the job is failing. #998
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Summary by CodeRabbit
WalkthroughThis update restructures GitHub Actions workflows by deleting separate CI and test workflow files, removing most triggers from the CodeQL workflow, and introducing a consolidated workflow that handles build, test, and CodeQL analysis jobs. Additionally, a minor indentation correction is made to an anchor tag in the HTML file. Changes
Sequence Diagram(s)sequenceDiagram
participant GitHub
participant Workflow (workflow.yml)
participant Build Job
participant Test Job
participant Analyze Job (CodeQL)
GitHub->>Workflow (workflow.yml): Pull request opened
Workflow (workflow.yml)->>Build Job: Start build (Node.js setup, npm install, npm check)
Build Job-->>Test Job: On success, start test (Yarn install, Yarn test)
Build Job-->>Analyze Job: On success, allow analyze to start (waits for Test Job too)
Test Job-->>Analyze Job: On success, allow analyze to start
Analyze Job->>Analyze Job: Run CodeQL analysis
Possibly related issues
Poem
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 5
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (5)
.github/workflows/CI.yml(0 hunks).github/workflows/codeql-analysis.yml(0 hunks).github/workflows/tests.yml(0 hunks).github/workflows/workflow.yml(1 hunks)index.html(1 hunks)
💤 Files with no reviewable changes (3)
- .github/workflows/CI.yml
- .github/workflows/codeql-analysis.yml
- .github/workflows/tests.yml
🧰 Additional context used
🪛 actionlint (1.7.4)
.github/workflows/workflow.yml
17-17: the runner of "actions/checkout@v2" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
19-19: the runner of "actions/setup-node@v1" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
28-28: the runner of "actions/checkout@v2" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
56-56: the runner of "actions/checkout@v3" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
60-60: the runner of "github/codeql-action/init@v2" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
73-73: the runner of "github/codeql-action/autobuild@v2" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
86-86: the runner of "github/codeql-action/analyze@v2" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
🪛 YAMLlint (1.35.1)
.github/workflows/workflow.yml
[warning] 3-3: truthy value should be one of [false, true]
(truthy)
[error] 28-28: wrong indentation: expected 6 but found 4
(indentation)
[error] 87-87: trailing spaces
(trailing-spaces)
🔇 Additional comments (4)
index.html (1)
146-148: Fix indentation of the Application button markup.The
<a>element for the "Applications" button is now correctly nested and aligned with its sibling elements, improving readability without affecting functionality..github/workflows/workflow.yml (3)
1-7: Trigger configuration looks sound.The workflow is set to run on all pull requests across any branch (
branches: ['**']), ensuring early detection of failures on every PR.🧰 Tools
🪛 YAMLlint (1.35.1)
[warning] 3-3: truthy value should be one of [false, true]
(truthy)
38-46: Dependency configuration ensures conditional execution.The
needs: [build, test]setting correctly prevents theanalyzejob from running if eitherbuildortestfails, aligning with the PR objective to skip downstream jobs on early failure.
55-61: CodeQL initialization is correctly configured.The checkout action is up-to-date (v3), and CodeQL is initialized for the specified
matrix.language. No issues detected here.🧰 Tools
🪛 actionlint (1.7.4)
56-56: the runner of "actions/checkout@v3" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
60-60: the runner of "github/codeql-action/init@v2" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
|
This pull request sets up GitHub code scanning for this repository. Once the scans have completed and the checks have passed, the analysis results for this pull request branch will appear on this overview. Once you merge this pull request, the 'Security' tab will show more code scanning analysis results (for example, for the default branch). Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results. For more information about GitHub code scanning, check out the documentation. |
Suvidh-kaushik
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please get the neutral check confirmed with Prakash sir everything else
LGTM.!
Above disables a security restriction enforced by Ubuntu's AppArmor on unprivileged user namespaces. What does this mean? Starting with Ubuntu 23.10, AppArmor restricts the use of unprivileged user namespaces by default for security reasons. Unprivileged user namespaces allow processes without administrative rights to create isolated environments (used by sandboxing, containers, etc.). The kernel parameter kernel.apparmor_restrict_unprivileged_userns controls whether AppArmor enforces these restrictions. When set to 1 (default), AppArmor restricts unprivileged user namespaces. When set to 0, it disables this restriction, allowing unprivileged user namespaces to be used freely. Why is this step used in CI workflows? |
|
@prakashchoudhary07 When we are removing the disabled security, all our tests are failing. Referring to the above explanations as stated above, the possible reason this failed is, it is checking for an authorised user. Thus, we are disabling AppArmor. As I am re-using the existing code, I may dedicate separate time to understand if we can achieve this without disabling Ubuntu's Apparmor. If required, I will add this to the new ticket for further investigation. https://github.com/Real-Dev-Squad/website-dashboard/actions/runs/15241161065/job/42861400927 Commented the dependency. Ran the code again to re-verify. |
bb92963
into
RealDevSquad:develop
Date: 11 May 2025
Developer Name: Ashutosh Sahoo
Issue Ticket Number
Description
CI runs all jobs even if early checks like ESLint or Prettier fail. This means tests and deployments still run, even when the code isn't clean or build-ready.
As a part of this task, we want to upgrade the dependencies on the workflow. We want to skip the jobs if any of the tasks fail. We want to optimize the overall experience.
Documentation Updated?
Under Feature Flag
Database Changes
Breaking Changes
Development Tested?
Screenshots
Screenshot
1. When Build failsWhen test fails

When all the jobs pass

Test Coverage
Screenshot 1
Not requiredAdditional Notes