storybookjs / storybook

Storybook is the industry standard workshop for building, documenting, and testing UI components in isolation
https://storybook.js.org
MIT License
84.72k stars 9.32k forks source link

Fix: Disable Telemetry when `--no-version-updates` flag is enabled in cliOptions #29635

Open toothlessdev opened 5 days ago

toothlessdev commented 5 days ago

Closes #29408

What I did

Add test code for disable withTelemetry when --no-version-updates flag is enabled in cliOptions Disable Telemetry when --no-version-updates flag is enabled in cliOptions

Checklist for Contributors

Testing

The changes in this PR are covered in the following automated tests:

Manual testing

This section is mandatory for all contributions. If you believe no manual test is necessary, please state so explicitly. Thanks!

Documentation

Checklist for Maintainers

🦋 Canary release

This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the @storybookjs/core team here.

_core team members can create a canary release here or locally with gh workflow run --repo storybookjs/storybook canary-release-pr.yml --field pr=<PR_NUMBER>_

name before after diff z %
createSize 0 B 0 B 0 B - -
generateSize 78.4 MB 78.4 MB 3.53 kB -0.17 0%
initSize 144 MB 144 MB 3.62 kB -0.59 0%
diffSize 65.1 MB 65.1 MB 90 B -0.83 0%
buildSize 6.83 MB 6.83 MB 0 B -1.05 0%
buildSbAddonsSize 1.51 MB 1.51 MB 0 B - 0%
buildSbCommonSize 195 kB 195 kB 0 B - 0%
buildSbManagerSize 1.86 MB 1.86 MB 0 B -1.09 0%
buildSbPreviewSize 271 kB 271 kB 0 B - 0%
buildStaticSize 0 B 0 B 0 B - -
buildPrebuildSize 3.83 MB 3.83 MB 0 B -1.09 0%
buildPreviewSize 3 MB 3 MB 0 B 0.95 0%
testBuildSize 0 B 0 B 0 B - -
testBuildSbAddonsSize 0 B 0 B 0 B - -
testBuildSbCommonSize 0 B 0 B 0 B - -
testBuildSbManagerSize 0 B 0 B 0 B - -
testBuildSbPreviewSize 0 B 0 B 0 B - -
testBuildStaticSize 0 B 0 B 0 B - -
testBuildPrebuildSize 0 B 0 B 0 B - -
testBuildPreviewSize 0 B 0 B 0 B - -
name before after diff z %
createTime 15.5s 24.7s 9.2s 1.12 37.3%
generateTime 19.4s 19.1s -272ms -0.62 -1.4%
initTime 13.3s 14.2s 863ms -0.35 6.1%
buildTime 7.7s 8.8s 1s -0.12 12%
testBuildTime 0ms 0ms 0ms - -
devPreviewResponsive 5.8s 5.5s -278ms -0.23 -5%
devManagerResponsive 3.5s 3.8s 331ms 1.01 8.5%
devManagerHeaderVisible 587ms 657ms 70ms 1.43 🔺10.7%
devManagerIndexVisible 668ms 683ms 15ms 0.59 2.2%
devStoryVisibleUncached 1.2s 1.4s 228ms 2.26 🔺15.5%
devStoryVisible 624ms 682ms 58ms 0.8 8.5%
devAutodocsVisible 542ms 375ms -167ms -2.63 🔰-44.5%
devMDXVisible 701ms 381ms -320ms -1.8 🔰-84%
buildManagerHeaderVisible 584ms 495ms -89ms -0.92 -18%
buildManagerIndexVisible 603ms 521ms -82ms -0.74 -15.7%
buildStoryVisible 583ms 489ms -94ms -0.98 -19.2%
buildAutodocsVisible 479ms 473ms -6ms 0.01 -1.3%
buildMDXVisible 478ms 414ms -64ms -0.72 -15.5%

Greptile Summary

This PR modifies Storybook's telemetry behavior to respect the --no-version-updates CLI flag, ensuring telemetry is disabled when version updates are disabled.

nx-cloud[bot] commented 5 days ago

☁️ Nx Cloud Report

CI is running/has finished running commands for commit 7b7e3a78a4e071928661661860a2d5220b2ff1bb. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this CI Pipeline Execution


✅ Successfully ran 1 target - [`nx run-many -t build --parallel=3`](https://cloud.nx.app/runs/HUSwuJJnJh?utm_source=pull-request&utm_medium=comment)

Sent with 💌 from NxCloud.