@@ -375,7 +375,7 @@ To make sure these integrations work properly you'll have to change how you
375
375
### General
376
376
377
377
Removed top-level exports: ` tracingOrigins ` , ` MetricsAggregator ` , ` metricsAggregatorIntegration ` , ` Severity ` ,
378
- ` Sentry.configureScope ` , ` Span ` , ` spanStatusfromHttpCode ` , ` makeMain ` , ` lastEventId ` , ` pushScope ` , ` popScope ` ,
378
+ ` Sentry.configureScope ` , ` Span ` , ` spanStatusfromHttpCode ` , ` makeMain ` , ` pushScope ` , ` popScope ` ,
379
379
` addGlobalEventProcessor ` , ` timestampWithMs ` , ` addExtensionMethods ` , ` addGlobalEventProcessor ` , ` getActiveTransaction `
380
380
381
381
Removed ` @sentry/utils ` exports: ` timestampWithMs ` , ` addOrUpdateIntegration ` , ` tracingContextFromHeaders ` , ` walk `
@@ -389,7 +389,6 @@ Removed `@sentry/utils` exports: `timestampWithMs`, `addOrUpdateIntegration`, `t
389
389
- [ Removal of ` Span ` class export from SDK packages] ( ./MIGRATION.md#removal-of-span-class-export-from-sdk-packages )
390
390
- [ Removal of ` spanStatusfromHttpCode ` in favour of ` getSpanStatusFromHttpCode ` ] ( ./MIGRATION.md#removal-of-spanstatusfromhttpcode-in-favour-of-getspanstatusfromhttpcode )
391
391
- [ Removal of ` addGlobalEventProcessor ` in favour of ` addEventProcessor ` ] ( ./MIGRATION.md#removal-of-addglobaleventprocessor-in-favour-of-addeventprocessor )
392
- - [ Removal of ` lastEventId() ` method] ( ./MIGRATION.md#deprecate-lasteventid )
393
392
- [ Remove ` void ` from transport return types] ( ./MIGRATION.md#remove-void-from-transport-return-types )
394
393
- [ Remove ` addGlobalEventProcessor ` in favor of ` addEventProcessor ` ] ( ./MIGRATION.md#remove-addglobaleventprocessor-in-favor-of-addeventprocessor )
395
394
@@ -568,10 +567,6 @@ Sentry.getGlobalScope().addEventProcessor(event => {
568
567
});
569
568
```
570
569
571
- #### Removal of ` lastEventId() ` method
572
-
573
- The ` lastEventId ` function has been removed. See [ below] ( ./MIGRATION.md#deprecate-lasteventid ) for more details.
574
-
575
570
#### Removal of ` void ` from transport return types
576
571
577
572
The ` send ` method on the ` Transport ` interface now always requires a ` TransportMakeRequestResponse ` to be returned in
@@ -1569,7 +1564,7 @@ If you are using the `Hub` right now, see the following table on how to migrate
1569
1564
| captureException() | ` Sentry.captureException() ` |
1570
1565
| captureMessage() | ` Sentry.captureMessage() ` |
1571
1566
| captureEvent() | ` Sentry.captureEvent() ` |
1572
- | lastEventId() | REMOVED - Use event processors or beforeSend instead |
1567
+ | lastEventId() | ` Sentry.lastEventId() ` |
1573
1568
| addBreadcrumb() | ` Sentry.addBreadcrumb() ` |
1574
1569
| setUser() | ` Sentry.setUser() ` |
1575
1570
| setTags() | ` Sentry.setTags() ` |
@@ -1690,35 +1685,6 @@ app.get('/your-route', req => {
1690
1685
});
1691
1686
```
1692
1687
1693
- ## Deprecate ` Sentry.lastEventId() ` and ` hub.lastEventId() `
1694
-
1695
- ` Sentry.lastEventId() ` sometimes causes race conditions, so we are deprecating it in favour of the ` beforeSend `
1696
- callback.
1697
-
1698
- ``` js
1699
- // Before
1700
- Sentry .init ({
1701
- beforeSend (event , hint ) {
1702
- const lastCapturedEventId = Sentry .lastEventId ();
1703
-
1704
- // Do something with `lastCapturedEventId` here
1705
-
1706
- return event ;
1707
- },
1708
- });
1709
-
1710
- // After
1711
- Sentry .init ({
1712
- beforeSend (event , hint ) {
1713
- const lastCapturedEventId = event .event_id ;
1714
-
1715
- // Do something with `lastCapturedEventId` here
1716
-
1717
- return event ;
1718
- },
1719
- });
1720
- ```
1721
-
1722
1688
## Deprecated fields on ` Span ` and ` Transaction `
1723
1689
1724
1690
In v8, the Span class is heavily reworked. The following properties & methods are thus deprecated:
@@ -1786,25 +1752,6 @@ Instead, import this directly from `@sentry/utils`.
1786
1752
Generally, in most cases you should probably use ` continueTrace ` instead, which abstracts this away from you and handles
1787
1753
scope propagation for you.
1788
1754
1789
- ## Deprecate ` lastEventId() `
1790
-
1791
- Instead, if you need the ID of a recently captured event, we recommend using ` beforeSend ` instead:
1792
-
1793
- ``` ts
1794
- import * as Sentry from ' @sentry/browser' ;
1795
-
1796
- Sentry .init ({
1797
- dsn: ' __DSN__' ,
1798
- beforeSend(event , hint ) {
1799
- const lastCapturedEventId = event .event_id ;
1800
-
1801
- // Do something with `lastCapturedEventId` here
1802
-
1803
- return event ;
1804
- },
1805
- });
1806
- ```
1807
-
1808
1755
## Deprecate ` timestampWithMs ` export - #7878
1809
1756
1810
1757
The ` timestampWithMs ` util is deprecated in favor of using ` timestampInSeconds ` .
0 commit comments