MPT-22385 Add Danger PR-formatting check workflow#349
Conversation
Add a Danger workflow that runs the shared softwareone-platform/one-danger action on pull requests to enforce the PR-formatting rules. MPT-22385
📝 WalkthroughWalkthroughA new GitHub Actions workflow ChangesDanger CI Workflow
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes 🚥 Pre-merge checks | ✅ 3 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
|
There was a problem hiding this comment.
🧹 Nitpick comments (1)
.github/workflows/danger.yml (1)
17-22: ⚡ Quick winPin external actions to immutable commit SHAs.
Using mutable tags (
@v6,@1.1.0) increases supply-chain risk. Pinning to SHAs hardens the workflow without changing behavior.Suggested hardening diff
- - name: Checkout - uses: actions/checkout@v6 + - name: Checkout + uses: actions/checkout@<resolved_checkout_sha> - name: Run Danger - uses: softwareone-platform/one-danger@1.1.0 + uses: softwareone-platform/one-danger@<resolved_one_danger_sha>Use the release/tag refs only to resolve the SHA once, then pin the SHA in workflow.
🤖 Prompt for 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. In @.github/workflows/danger.yml around lines 17 - 22, The GitHub Actions workflow is using mutable version tags (v6 and 1.1.0) for external actions, which creates supply chain security risks. Replace the mutable tags with immutable commit SHAs for both the actions/checkout and softwareone-platform/one-danger actions. First resolve the commit SHA for each action version, then update the workflow to reference the SHAs directly instead of the version tags. This ensures the workflow will always use the exact same version of each action regardless of any future tag changes.
🤖 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.
Nitpick comments:
In @.github/workflows/danger.yml:
- Around line 17-22: The GitHub Actions workflow is using mutable version tags
(v6 and 1.1.0) for external actions, which creates supply chain security risks.
Replace the mutable tags with immutable commit SHAs for both the
actions/checkout and softwareone-platform/one-danger actions. First resolve the
commit SHA for each action version, then update the workflow to reference the
SHAs directly instead of the version tags. This ensures the workflow will always
use the exact same version of each action regardless of any future tag changes.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Organization UI (inherited)
Review profile: CHILL
Plan: Pro
Run ID: 0f22f917-abfe-4258-bf8b-58da9178d91f
📒 Files selected for processing (1)
.github/workflows/danger.yml
🔗 Linked repositories identified
CodeRabbit considers these linked repositories for cross-repo context during reviews:
softwareone-platform/mpt-extension-skills(manual)
📜 Review details
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: build
🔇 Additional comments (1)
.github/workflows/danger.yml (1)
17-17: No issues found. Theactions/checkout@v6tag is valid and published; the workflow will not fail due to a missing tag.



🤖 AI-generated PR — Please review carefully.
What
Add
.github/workflows/danger.ymlrunning the sharedsoftwareone-platform/one-danger@1.1.0action on pull requests. It enforces the PR-formatting rules (Jira key in title, single commit, size threshold, no merge commits, release-branch markers and release→main linkage) via Danger.Part of the org-wide rollout (US-3); the same workflow was smoke-tested in
mpt-extension-sdk.Jira
Closes MPT-22385 (subtask of MPT-22376).
Testing
This PR triggers the new Danger workflow on itself.
Closes MPT-22385
softwareone-platform/one-danger@1.1.0action