-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Remove usage of deprecated event.stacktrace
#4885
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
Merged
AbhiPrasad
merged 18 commits into
getsentry:7.x
from
timfish:v7/remove-deprecated-event.stacktrace
Apr 11, 2022
Merged
Changes from 15 commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
97e6ff3
[v7] feat: Remove references to @sentry/apm (#4845)
AbhiPrasad 57d37c2
[v7] feat(core): Delete API class (#4848)
AbhiPrasad 424df27
[v7] feat: Delete deprecated `startSpan` and `child` methods (#4849)
AbhiPrasad 5a7f145
feat(core): Remove whitelistUrls/blacklistUrls (#4850)
AbhiPrasad f855260
feat(gatsby): Remove Sentry from window (#4857)
AbhiPrasad f1e9da2
feat(hub): Remove getActiveDomain (#4858)
AbhiPrasad 55b0570
feat(types): Remove deprecated user dsn field (#4864)
AbhiPrasad 2fc13c6
feat(hub): Remove setTransaction scope method (#4865)
AbhiPrasad 20c7773
[v7] feat: Drop support for Node 6 (#4851)
AbhiPrasad 244eb0e
[v7] feat(tracing): Rename registerRequestInstrumentation -> instrume…
AbhiPrasad 285ca26
fix(test): Increase MongoMemoryServer creation timeout (#4881)
Lms24 8afb70c
Removes usage of deprecated `event.stacktrace`
timfish 1bfb3aa
add exception value
timfish 4c74bfa
Remove redundent check
timfish 270ce53
Fix tests
timfish 6865b6e
Fix dedup test and lint
timfish 5600f87
Fix integration tests
timfish a91cecd
Merge remote-tracking branch 'upstream/7.x' into v7/remove-deprecated…
timfish File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,38 @@ | ||
/* eslint-disable deprecation/deprecation */ | ||
import { makeDsn } from '@sentry/utils'; | ||
|
||
import { API, getReportDialogEndpoint, getRequestHeaders } from '../../src/api'; | ||
import { | ||
getEnvelopeEndpointWithUrlEncodedAuth, | ||
getReportDialogEndpoint, | ||
getRequestHeaders, | ||
getStoreEndpoint, | ||
getStoreEndpointWithUrlEncodedAuth, | ||
initAPIDetails, | ||
} from '../../src/api'; | ||
|
||
const ingestDsn = 'https://[email protected]:1234/subpath/123'; | ||
const dsnPublic = 'https://[email protected]:1234/subpath/123'; | ||
const legacyDsn = 'https://abc:[email protected]:1234/subpath/123'; | ||
const tunnel = 'https://hello.com/world'; | ||
|
||
const ingestDsnAPI = initAPIDetails(ingestDsn); | ||
const dsnPublicAPI = initAPIDetails(dsnPublic); | ||
|
||
describe('API', () => { | ||
test('getStoreEndpoint', () => { | ||
expect(new API(dsnPublic).getStoreEndpointWithUrlEncodedAuth()).toEqual( | ||
expect(getStoreEndpointWithUrlEncodedAuth(dsnPublicAPI.dsn)).toEqual( | ||
'https://sentry.io:1234/subpath/api/123/store/?sentry_key=abc&sentry_version=7', | ||
); | ||
expect(new API(dsnPublic).getStoreEndpoint()).toEqual('https://sentry.io:1234/subpath/api/123/store/'); | ||
expect(new API(ingestDsn).getStoreEndpoint()).toEqual('https://xxxx.ingest.sentry.io:1234/subpath/api/123/store/'); | ||
expect(getStoreEndpoint(dsnPublicAPI.dsn)).toEqual('https://sentry.io:1234/subpath/api/123/store/'); | ||
expect(getStoreEndpoint(ingestDsnAPI.dsn)).toEqual('https://xxxx.ingest.sentry.io:1234/subpath/api/123/store/'); | ||
}); | ||
|
||
test('getEnvelopeEndpoint', () => { | ||
expect(new API(dsnPublic).getEnvelopeEndpointWithUrlEncodedAuth()).toEqual( | ||
expect(getEnvelopeEndpointWithUrlEncodedAuth(dsnPublicAPI.dsn)).toEqual( | ||
'https://sentry.io:1234/subpath/api/123/envelope/?sentry_key=abc&sentry_version=7', | ||
); | ||
expect(new API(dsnPublic, {}, tunnel).getEnvelopeEndpointWithUrlEncodedAuth()).toEqual(tunnel); | ||
const dsnPublicAPIWithTunnel = initAPIDetails(dsnPublic, {}, tunnel); | ||
expect(getEnvelopeEndpointWithUrlEncodedAuth(dsnPublicAPIWithTunnel.dsn, tunnel)).toEqual(tunnel); | ||
}); | ||
|
||
test('getRequestHeaders', () => { | ||
|
@@ -118,13 +129,13 @@ describe('API', () => { | |
); | ||
}); | ||
|
||
test('getDsn', () => { | ||
expect(new API(dsnPublic).getDsn().host).toEqual(makeDsn(dsnPublic).host); | ||
expect(new API(dsnPublic).getDsn().path).toEqual(makeDsn(dsnPublic).path); | ||
expect(new API(dsnPublic).getDsn().pass).toEqual(makeDsn(dsnPublic).pass); | ||
expect(new API(dsnPublic).getDsn().port).toEqual(makeDsn(dsnPublic).port); | ||
expect(new API(dsnPublic).getDsn().protocol).toEqual(makeDsn(dsnPublic).protocol); | ||
expect(new API(dsnPublic).getDsn().projectId).toEqual(makeDsn(dsnPublic).projectId); | ||
expect(new API(dsnPublic).getDsn().publicKey).toEqual(makeDsn(dsnPublic).publicKey); | ||
test('initAPIDetails dsn', () => { | ||
expect(dsnPublicAPI.dsn.host).toEqual(makeDsn(dsnPublic).host); | ||
expect(dsnPublicAPI.dsn.path).toEqual(makeDsn(dsnPublic).path); | ||
expect(dsnPublicAPI.dsn.pass).toEqual(makeDsn(dsnPublic).pass); | ||
expect(dsnPublicAPI.dsn.port).toEqual(makeDsn(dsnPublic).port); | ||
expect(dsnPublicAPI.dsn.protocol).toEqual(makeDsn(dsnPublic).protocol); | ||
expect(dsnPublicAPI.dsn.projectId).toEqual(makeDsn(dsnPublic).projectId); | ||
expect(dsnPublicAPI.dsn.publicKey).toEqual(makeDsn(dsnPublic).publicKey); | ||
}); | ||
}); |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.