Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ref: Use getCurrentScope()/hub.getScope() instead of configureScope() #9846

Merged
merged 4 commits into from
Dec 15, 2023

Conversation

mydea
Copy link
Member

@mydea mydea commented Dec 14, 2023

In preparation for #9841, as we want to deprecate configureScope, refactor our own usage of this away.

I used a new transformer of sentry-migr8 for this, which did most of the heavy lifting. I only needed to fix the block usage (which is more a stylistic issue than an actual problem).

In some follow up, I'll also create a migr8 transform to refactor hub usage away, to e.g. refactor getCurrentHub().getScope() to getCurrentScope() etc. But for now this is OK I think.

@mydea mydea self-assigned this Dec 14, 2023
Copy link
Contributor

github-actions bot commented Dec 14, 2023

size-limit report 📦

Path Size
@sentry/browser (incl. Tracing, Replay, Feedback) - Webpack (gzipped) 75 KB (-0.06% 🔽)
@sentry/browser (incl. Tracing, Replay) - Webpack (gzipped) 66.38 KB (-0.02% 🔽)
@sentry/browser (incl. Tracing, Replay) - Webpack with treeshaking flags (gzipped) 59.99 KB (-0.02% 🔽)
@sentry/browser (incl. Tracing) - Webpack (gzipped) 31.12 KB (-0.03% 🔽)
@sentry/browser (incl. Feedback) - Webpack (gzipped) 29.74 KB (0%)
@sentry/browser - Webpack (gzipped) 21.39 KB (0%)
@sentry/browser (incl. Tracing, Replay, Feedback) - ES6 CDN Bundle (gzipped) 71.6 KB (-0.01% 🔽)
@sentry/browser (incl. Tracing, Replay) - ES6 CDN Bundle (gzipped) 63.32 KB (-0.02% 🔽)
@sentry/browser (incl. Tracing) - ES6 CDN Bundle (gzipped) 29.66 KB (-0.02% 🔽)
@sentry/browser - ES6 CDN Bundle (gzipped) 21.72 KB (0%)
@sentry/browser (incl. Tracing, Replay) - ES6 CDN Bundle (minified & uncompressed) 199.56 KB (-0.01% 🔽)
@sentry/browser (incl. Tracing) - ES6 CDN Bundle (minified & uncompressed) 89.93 KB (-0.02% 🔽)
@sentry/browser - ES6 CDN Bundle (minified & uncompressed) 64.92 KB (0%)
@sentry/browser (incl. Tracing) - ES5 CDN Bundle (gzipped) 32.33 KB (-0.01% 🔽)
@sentry/react (incl. Tracing, Replay) - Webpack (gzipped) 66.74 KB (-0.01% 🔽)
@sentry/react - Webpack (gzipped) 21.44 KB (0%)
@sentry/nextjs Client (incl. Tracing, Replay) - Webpack (gzipped) 83.47 KB (-0.02% 🔽)
@sentry/nextjs Client - Webpack (gzipped) 48.22 KB (-0.03% 🔽)
@sentry-internal/feedback - Webpack (gzipped) 16.19 KB (0%)

Copy link
Member

@Lms24 Lms24 left a comment

Choose a reason for hiding this comment

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

LGTM!
I can already see incoming version discrepancy issues 😅 (but there's not a lot we can do here as long as we don't bundle everything into one file, no worries)

@mydea mydea merged commit 1e8d2b3 into develop Dec 15, 2023
93 checks passed
@mydea mydea deleted the fn/deprecate-configureScope branch December 15, 2023 09:16
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.

None yet

2 participants