Skip to content

[MINOR] Add daily npm audit remediation workflow - #5390

Open
jongyoul wants to merge 1 commit into
apache:masterfrom
jongyoul:codex/daily-npm-audit-fix-pr
Open

[MINOR] Add daily npm audit remediation workflow#5390
jongyoul wants to merge 1 commit into
apache:masterfrom
jongyoul:codex/daily-npm-audit-fix-pr

Conversation

@jongyoul

@jongyoul jongyoul commented Aug 6, 2026

Copy link
Copy Markdown
Member

What is this PR for?

Add a daily and manually triggered workflow that detects high/critical npm audit failures in zeppelin-react.

When a lockfile-only fix is available, the workflow:

  • changes only zeppelin-react/package-lock.json;
  • validates audit, lint, tests, and production build;
  • creates or updates one Draft PR from a fixed automation branch;
  • skips creating a duplicate when the lockfile content is unchanged.

It never uses npm audit fix --force, pushes directly to master, or merges automatically.

What type of PR is it?

Improvement

What is the Jira issue?

N/A

How should this be tested?

  • The workflow's prepare job passed on this PR.
  • The end-to-end remediation path passed audit, lint, 14 tests, and production build locally.

@jongyoul
jongyoul marked this pull request as ready for review August 10, 2026 11:22
Copilot AI lite review requested due to automatic review settings August 10, 2026 11:22

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new GitHub Actions workflow to automatically detect high/critical npm audit issues in zeppelin-web-angular/projects/zeppelin-react and (when safeguards pass) prepare a lockfile-only remediation via a dedicated automation branch and draft PR. This fits into the repo’s CI/automation layer by standardizing a repeatable, validated dependency-audit remediation path for the React subproject.

Changes:

  • Introduces a scheduled + manually dispatchable workflow to run npm audit (high+) and, when needed, generate a lockfile-only fix validated by install/audit/lint/test/build.
  • Splits the workflow into a read-only “prepare” job and a write-capable “publish” job that updates a fixed automation branch and creates/updates a draft PR.
  • Adds content-based duplicate suppression to avoid recreating identical automation PRs.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +154 to +160
publish:
needs: prepare
if: >-
needs.prepare.outputs.needs_remediation == 'true' &&
github.event_name != 'pull_request' &&
github.repository == 'apache/zeppelin'
runs-on: ubuntu-24.04
@jongyoul

Copy link
Copy Markdown
Member Author

@tbonelee @voidmatcha How about this idea? 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants