Skip to content

Reduce frequency of data staleness warnings - #108

Merged
tonypconway merged 12 commits into
web-platform-dx:mainfrom
tonypconway:refactor-staleness-warnings
Dec 3, 2025
Merged

tonypconway merged 12 commits into
web-platform-dx:mainfrom
tonypconway:refactor-staleness-warnings

Conversation

@tonypconway

@tonypconway tonypconway commented Nov 27, 2025 •

Copy link
Copy Markdown
Collaborator

This PR introduces several changes:

  • Data staleness warnings are now only shown if the getCompatibleVersions() or getAllVersions() functions are called - previously they were shown whenever the module was loaded, which meant many browserslist consumers were seeing the warning despite not targeting Baseline, especially those who were consuming browserslist in a pre-compiled format via next.js.
  • Adds new conditions for these warnings to be displayed which should only warn users for whom data freshness is critical:
    • The feature cut off data must be within the last two months, i.e. widelyAvailableOnDate: today + >2 years and 4 months or newly available in a browserslist query.
    • The module data must be more than 2 months old.
  • Introduces suppression options for these warning via the options objects and environment variables:
    • Adds a new suppressWarnings boolean to the getCompatibleVersions() and getAllVersions()
    • Respects the existing BROWSERSLIST_IGNORE_OLD_DATA
    • Respects a new BASELINE_BROWSER_MAPPING_IGNORE_OLD_DATA environment variable.
  • Adds explanatory text to the docs for how to avoid such warnings when reproducible builds are a requirement.
  • Change warning text to be package manager agnostic and mention the possibility of pre-compiled data.

Fixes: #105 #107 #109

…s, remove old 2-month warning, and update build configuration.
…ion for updates and warning suppression, and update build configuration.
@tonypconway tonypconway changed the title Rebuild staleness warnings process Reduce frequency of data staleness warnings Nov 27, 2025
@tonypconway
tonypconway merged commit 226fd01 into web-platform-dx:main Dec 3, 2025
@tonypconway
tonypconway deleted the refactor-staleness-warnings branch December 3, 2025 15:43
@olympiaindians

Copy link
Copy Markdown

yes updating to 2.9.0 and nextjs to 16.0.7 did the trick

malibio added a commit to NodeSpaceAI/nodespace-core that referenced this pull request Jan 6, 2026
Add BROWSERSLIST_IGNORE_OLD_DATA=1 env var to dev and quality scripts.
This is forward-compatible - once baseline-browser-mapping publishes
a new version with PR #108 fix (merged Dec 3, 2025), the warning about
"data over two months old" will automatically stop appearing.

Also updates:
- svelte-check to 4.3.5
- browserslist to 4.28.1
- Adds overrides/resolutions to pin versions

Note: The warning still appears until npm package is updated upstream.
See: web-platform-dx/baseline-browser-mapping#108

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
malibio added a commit to NodeSpaceAI/nodespace-core that referenced this pull request Feb 4, 2026
Add BROWSERSLIST_IGNORE_OLD_DATA=1 env var to dev and quality scripts.
This is forward-compatible - once baseline-browser-mapping publishes
a new version with PR #108 fix (merged Dec 3, 2025), the warning about
"data over two months old" will automatically stop appearing.

Also updates:
- svelte-check to 4.3.5
- browserslist to 4.28.1
- Adds overrides/resolutions to pin versions

Note: The warning still appears until npm package is updated upstream.
See: web-platform-dx/baseline-browser-mapping#108

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
malibio added a commit to NodeSpaceAI/nodespace-core that referenced this pull request Feb 5, 2026
Add BROWSERSLIST_IGNORE_OLD_DATA=1 env var to dev and quality scripts.
This is forward-compatible - once baseline-browser-mapping publishes
a new version with PR #108 fix (merged Dec 3, 2025), the warning about
"data over two months old" will automatically stop appearing.

Also updates:
- svelte-check to 4.3.5
- browserslist to 4.28.1
- Adds overrides/resolutions to pin versions

Note: The warning still appears until npm package is updated upstream.
See: web-platform-dx/baseline-browser-mapping#108

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
malibio added a commit to NodeSpaceAI/nodespace-core that referenced this pull request Feb 26, 2026
Add BROWSERSLIST_IGNORE_OLD_DATA=1 env var to dev and quality scripts.
This is forward-compatible - once baseline-browser-mapping publishes
a new version with PR #108 fix (merged Dec 3, 2025), the warning about
"data over two months old" will automatically stop appearing.

Also updates:
- svelte-check to 4.3.5
- browserslist to 4.28.1
- Adds overrides/resolutions to pin versions

Note: The warning still appears until npm package is updated upstream.
See: web-platform-dx/baseline-browser-mapping#108

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
frankmueller-msft added a commit to microsoft/FluidFramework that referenced this pull request Feb 26, 2026
## Summary
- Adds `BASELINE_BROWSER_MAPPING_IGNORE_OLD_DATA=1` to both the build
and lint steps in `include-build-lint.yml`
- **Eliminates 100+ identical warnings** ("data is over two months old")
from `baseline-browser-mapping`, a transitive dependency of
`browserslist` that fires once per package during builds
- The env var is the [upstream-supported suppression
mechanism](web-platform-dx/baseline-browser-mapping#107)
(implemented in
[#108](web-platform-dx/baseline-browser-mapping#108))

## Note
This suppresses the warning in CI only — local builds still surface it
so developers know the data is stale. A follow-up should add a Renovate
rule or periodic `npx update-browserslist-db` to keep the data current
rather than permanently silencing the staleness signal.

## Test plan
- [x] repo-policy-check passes
- [ ] Verify CI build logs no longer contain "data is over two months
old" warnings (requires triggering `Build - client packages` pipeline,
which only runs when client code is changed)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
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.

baseline-browser-mapping prevents reproducible builds.

2 participants