feat(ci): add auto-fix workflow for transitive dependency vulnerabilities#6
Merged
justanothersynth merged 3 commits intomainfrom Apr 6, 2026
Conversation
…ties When the amera-dependabot Lambda classifies a Dependabot alert as fixable_manual, it dispatches this workflow to check out the target repo, update the vulnerable transitive dependency via poetry/npm, verify the fix, and open a PR with security metadata. Supports pip (Poetry + CodeArtifact auth + pip-audit) and npm (npm update + npm audit) ecosystems. PRs are retargeted to staging when available and include GHSA advisory links, severity, and optional Linear ticket references. Resolves AMR-1897
Pass `inputs.packages` and `inputs.target_repo` via env variables instead of interpolating directly into shell commands, preventing GitHub Actions expression injection. Also surface `alert_url` input in the PR body so it's not declared but unused. AMR-1897
Set `permissions: { contents: read }` on all three workflows to
restrict the default GITHUB_TOKEN scope. All write operations already
use the AMERABOT app token, so this is pure least-privilege hardening.
Resolves CodeQL "workflow does not contain permissions" findings.
AMR-1897
Katyaraa1
approved these changes
Apr 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds a new centralized GitHub Actions workflow (
auto_fix_transitive_dep.yml) that automates fixing transitive dependency vulnerabilities across all org repos.workflow_dispatchwhen an alert is classified asfixable_manualpoetry update, verifies withpip-audit, opens a PRnpm update, verifies withnpm audit, opens a PRstagingbranch, the PR base is retargeted automatically{target_repo}-{ghsa_ids}to prevent duplicate runs from webhook retriesResolves AMR-1897
Risk Level
Rollback Plan
Revert this PR. The workflow is only triggered by explicit
workflow_dispatchcalls from the Lambda, so removing it simply disables the automation — alerts continue to be tracked as before.PHI Impact
Testing