Skip to content

fix: auto-stamp SDK_VERSION from package.json during build#1383

Draft
ankita10119 wants to merge 1 commit into
v5from
SDK-10345-1
Draft

fix: auto-stamp SDK_VERSION from package.json during build#1383
ankita10119 wants to merge 1 commit into
v5from
SDK-10345-1

Conversation

@ankita10119

Copy link
Copy Markdown
Contributor

Changes

What: Added scripts/update-version.js to auto-stamp SDK_VERSION in src/management/version.ts from package.json before compilation. Hooked into the build script so thisnruns automatically during CI publish.

Why: In 5.14.0 and 6.0.0 releases, src/management/version.ts was not updated manually before release, causing the published npm package to report the wrong SDK_VERSION in the Auth0-Client telemetry header. This fix eliminates the manual step entirely, the correct version is always stamped at build time regardless.

No public API changes. No endpoints added, removed, or modified.

References

  • Affected versions: auth0@5.14.0, auth0@6.0.0

Testing

  • This change adds unit test coverage
  • This change adds integration test coverage

Checklist

@ankita10119
ankita10119 requested a review from a team as a code owner July 25, 2026 07:30
@ankita10119
ankita10119 marked this pull request as draft July 25, 2026 07:30
@codecov

codecov Bot commented Jul 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.62%. Comparing base (ec645b1) to head (1f25d30).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##               v5    #1383    +/-   ##
========================================
  Coverage   89.62%   89.62%            
========================================
  Files         428      428            
  Lines       19886    19886            
  Branches     9400     9757   +357     
========================================
  Hits        17823    17823            
  Misses       2063     2063            
Flag Coverage Δ
alltests 89.62% <100.00%> (ø)

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

Files with missing lines Coverage Δ
src/management/version.ts 100.00% <100.00%> (ø)
🚀 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.

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.

1 participant