Skip to content

TypeScript error in @sentry/integrations introduced in 7.16.0 #6183

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

Closed
3 tasks done
tamlyn opened this issue Nov 10, 2022 · 4 comments · Fixed by #6185
Closed
3 tasks done

TypeScript error in @sentry/integrations introduced in 7.16.0 #6183

tamlyn opened this issue Nov 10, 2022 · 4 comments · Fixed by #6185
Assignees

Comments

@tamlyn
Copy link

tamlyn commented Nov 10, 2022

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which package are you using?

@sentry/serverless

SDK Version

7.18.0

Framework Version

Node 16, TypeScript 4.7

Link to Sentry event

No response

Steps to Reproduce

  • upgrade Sentry packages to 7.16.0+
  • make use of import { ExtraErrorData } from "@sentry/integrations";
  • compile with tsc

Note: this appears to be related to #6016 but affects @sentry/integrations rather than @sentry/utils.

Expected Result

No error

Actual Result

node_modules/@sentry/integrations/types/offline.d.ts:2:71 - error TS2304: Cannot find name 'Window'.

2 export declare const WINDOW: import("@sentry/utils").InternalGlobal & Window;
                                                                        ~~~~~~

node_modules/@sentry/integrations/types/reportingobserver.d.ts:2:71 - error TS2304: Cannot find name 'Window'.

2 export declare const WINDOW: import("@sentry/utils").InternalGlobal & Window;
                                                                        ~~~~~~
@AbhiPrasad
Copy link
Member

Hey, thanks for writing in @tamlyn. I think you're correct about the source PR, @timfish seems like we'll have to make the same typescript changes to @sentry/integrations!

@timfish
Copy link
Collaborator

timfish commented Nov 10, 2022

Sorry, I think this was a copy/paste mistake as they should never have been exported!

@AbhiPrasad
Copy link
Member

Hey @tamlyn, this was fixed and released with https://github.com/getsentry/sentry-javascript/releases/tag/7.19.0.

@tamlyn
Copy link
Author

tamlyn commented Nov 10, 2022

Incredible speed – thanks team! 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants