Skip to content

feat(ci): enforce min release age for npm dep installation - #43164

Merged
hainenber merged 3 commits into
masterfrom
feat/enforce-min-release-age-for-npm-dep-installation
Aug 28, 2026
Merged

hainenber merged 3 commits into
masterfrom
feat/enforce-min-release-age-for-npm-dep-installation

Conversation

@hainenber

Copy link
Copy Markdown
Contributor

feat(ci): enforce min release age for npm dep installation

SUMMARY

Closes #42983

Enforce npm dep installation process to not download packages that were released too young, to avoid supply-chain attacks.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

N/A

TESTING INSTRUCTIONS

Green CI as acceptance threshold

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

@bito-code-review

bito-code-review Bot commented Aug 14, 2026 •

Copy link
Copy Markdown
Contributor

Code Review Agent Run #1a5949

Actionable Suggestions - 0
Filtered by Review Rules

Bito filtered these suggestions based on rules created automatically for your feedback. Manage rules.

  • superset-frontend/.npmrc - 1
    • CWE-1359: Incompatible Config Option · Line 1-1
Review Details
  • Files reviewed - 3 · Commit Range: afba307..afba307
    • superset-embedded-sdk/.npmrc
    • superset-frontend/.npmrc
    • superset-websocket/.npmrc
  • Files skipped - 1
    • superset-frontend/package-lock.json - Reason: Filter setting
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

  • /pause - Pauses automatic reviews on this pull request.

  • /resume - Resumes automatic reviews.

  • /resolve - Marks all Bito-posted review comments as resolved.

  • /abort - Cancels all in-progress reviews.

Refer to the documentation for additional commands.

Configuration

This repository uses Superset You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.

Documentation & Help

AI Code Review powered by Bito Logo

@codecov

codecov Bot commented Aug 14, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.21%. Comparing base (abf338d) to head (6ea4727).

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #43164   +/-   ##
=======================================
  Coverage   79.21%   79.21%           
=======================================
  Files        2879     2879           
  Lines      165922   165922           
  Branches    38377    38377           
=======================================
  Hits       131427   131427           
  Misses      32018    32018           
  Partials     2477     2477           
Flag Coverage Δ
javascript 74.66% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@netlify

netlify Bot commented Aug 15, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for superset-docs-preview ready!

Name Link
🔨 Latest commit 9ceb6fa
🔍 Latest deploy log https://app.netlify.com/projects/superset-docs-preview/deploys/6a9108037f9f070008660ef5
😎 Deploy Preview https://deploy-preview-43164--superset-docs-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@bito-code-review

bito-code-review Bot commented Aug 15, 2026 •

Copy link
Copy Markdown
Contributor

Code Review Agent Run #d0040b

Actionable Suggestions - 0
Review Details
  • Files reviewed - 1 · Commit Range: afba307..c128c8d
    • .rat-excludes
  • Files skipped - 0
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

  • /pause - Pauses automatic reviews on this pull request.

  • /resume - Resumes automatic reviews.

  • /resolve - Marks all Bito-posted review comments as resolved.

  • /abort - Cancels all in-progress reviews.

Refer to the documentation for additional commands.

Configuration

This repository uses Superset You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.

Documentation & Help

AI Code Review powered by Bito Logo

Comment thread superset-frontend/.npmrc
@@ -0,0 +1 @@
min-release-age=3

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This install policy is paired with a lockfile that no longer satisfies packages/superset-ui-core's dompurify: ^3.4.13 requirement: the remaining hoisted entry is 3.4.12 after the 3.4.13 nested entry was removed. That makes a clean frontend install fail or re-resolve outside the lock; should the lockfile be regenerated so it retains a compatible DOMPurify resolution?

@bito-code-review

Copy link
Copy Markdown
Contributor

Yes, the lockfile should be regenerated. Removing the nested dompurify entry while the package still requires ^3.4.13 creates a dependency mismatch if the hoisted version is older (3.4.12). Regenerating the lockfile ensures that the package manager correctly resolves the dependency to a version that satisfies the requirement, preventing installation failures or unexpected re-resolutions during CI/CD or local builds.

@rusackas

Copy link
Copy Markdown
Member

Heya @hainenber, thanks for this!

Mergeable, but the open thread from @sadpandajoe (dropping the nested dompurify 3.4.13 entry leaving the hoisted version at 3.4.12) seems worth addressing. Mind regenerating the lockfile so it resolves cleanly before merge?

@hainenber

Copy link
Copy Markdown
Contributor Author

Resolved after merging master. Let's see if the CI going green. Thanks for checking by @rusackas!

@rusackas

Copy link
Copy Markdown
Member

@hainenber double-checked the lockfile at 8db0f03 and it's still just the one dompurify entry, 3.4.12, nothing satisfying superset-ui-core's ^3.4.13. Mind confirming npm actually re-resolved that before we call it settled?

@hainenber

Copy link
Copy Markdown
Contributor Author

I kept running npm i and it always dropped the nested dompurify 3.4.13 entry leaving the hoisted version at 3.4.12

I've fixed in latest HEAD commit

@rusackas

Copy link
Copy Markdown
Member

Tests have failed a couple times here... can you check to see if it's a real problem?

Signed-off-by: hainenber <dotronghai96@gmail.com>
Signed-off-by: hainenber <dotronghai96@gmail.com>
Signed-off-by: hainenber <dotronghai96@gmail.com>
@rusackas
rusackas force-pushed the feat/enforce-min-release-age-for-npm-dep-installation branch from 9ceb6fa to 6ea4727 Compare August 28, 2026 15:31
@rusackas rusackas added the merge-if-green If approved and tests are green, please go ahead and merge it for me label Aug 28, 2026
@hainenber
hainenber merged commit 53e76af into master Aug 28, 2026
86 checks passed
@hainenber
hainenber deleted the feat/enforce-min-release-age-for-npm-dep-installation branch August 28, 2026 16:42
@bito-code-review

Copy link
Copy Markdown
Contributor

Bito Automatic Review Skipped – PR Already Merged

Bito scheduled an automatic review for this pull request, but the review was skipped because this PR was merged before the review could be run.
No action is needed if you didn't intend to review it. To get a review, you can type /review in a comment and save it

rusackas pushed a commit that referenced this pull request Aug 29, 2026
Signed-off-by: hainenber <dotronghai96@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies:npm embedded merge-if-green If approved and tests are green, please go ahead and merge it for me size/XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

chore(security): no .npmrc, so the dependency cooldown is advisory only

3 participants