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

Bump Sentry JavaScript 7 #2250

Merged
merged 20 commits into from
Jun 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,9 @@ wheelhouse
# Yalc
.yalc/
yalc.lock

# Sample
sample/.vscode/.react/index.bundle
sample/.vscode/.react/index.map
sample/.vscode/.react/debuggerWorker.js
sample/xc-build
90 changes: 49 additions & 41 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,43 +1,51 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Attach to packager",
"cwd": "${workspaceFolder}",
"type": "reactnative",
"request": "attach"
},
{
"type": "node",
"request": "launch",
"name": "Debug e2e:android",
"cwd": "${workspaceFolder}/sample",
"program": "./node_modules/jest/bin/jest",
"args": [
"--runInBand",
"--config=./jest.config.js"
],
"env": {
"PLATFORM": "android"
},
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen"
},
{
"type": "node",
"request": "launch",
"name": "Debug e2e:ios",
"cwd": "${workspaceFolder}/sample",
"program": "./node_modules/jest/bin/jest",
"args": [
"--runInBand",
"--config=./jest.config.js"
],
"env": {
"PLATFORM": "ios"
},
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen"
},
]
"version": "0.2.0",
"configurations": [
{
"name": "Attach to packager",
"cwd": "${workspaceFolder}",
"type": "reactnative",
"request": "attach"
},
{
"type": "node",
"request": "launch",
"name": "Debug e2e:android",
"cwd": "${workspaceFolder}/sample",
"program": "./node_modules/jest/bin/jest",
"args": [
"--runInBand",
"--config=./jest.config.js"
],
"env": {
"PLATFORM": "android"
},
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen"
},
{
"type": "node",
"request": "launch",
"name": "Debug e2e:ios",
"cwd": "${workspaceFolder}/sample",
"program": "./node_modules/jest/bin/jest",
"args": [
"--runInBand",
"--config=./jest.config.js"
],
"env": {
"PLATFORM": "ios"
},
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen"
},
{
"name": "Debug Sample - iOS",
"cwd": "${workspaceFolder}",
"type": "reactnative",
"request": "launch",
"platform": "ios",
"isDynamic": true
},
]
}
7 changes: 5 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
"editor.formatOnType": true,
"editor.formatOnPaste": false,
"editor.formatOnSave": true,
"editor.rulers": [120],
"editor.rulers": [
120
],
"editor.tabSize": 2,
"files.autoSave": "onWindowChange",
"files.trimTrailingWhitespace": true,
Expand All @@ -21,5 +23,6 @@
"editor.formatOnPaste": false,
"editor.formatOnSave": false
},
"react-native-tools.projectRoot": "./sample"
"react-native-tools.projectRoot": "./sample",
"dart.flutterAdbConnectOnChromeOs": false
}
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# Changelog

## Unreleased

- Bump Sentry JavaScript 7.0.0 ([#2250](https://github.com/getsentry/sentry-react-native/pull/2250))
- [changelog](https://github.com/getsentry/sentry-javascript/blob/7.0.0/CHANGELOG.md)
- [diff](https://github.com/getsentry/sentry-javascript/compare/6.19.2...7.0.0)

## Breaking changes

By bumping Sentry Javascript, new breaking changes were introduced, to know more what was changed, check the [breaking changes changelog](https://github.com/getsentry/sentry-javascript/blob/7.0.0/CHANGELOG.md#breaking-changes) from Sentry Javascript.

## 3.4.3

- feat: Support macOS (#2240) by @ospfranco
Expand Down
22 changes: 11 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,20 +40,20 @@
"react-native": ">=0.56.0"
},
"dependencies": {
"@sentry/browser": "6.19.2",
"@sentry/browser": "7.0.0",
"@sentry/cli": "^1.74.2",
"@sentry/core": "6.19.2",
"@sentry/hub": "6.19.2",
"@sentry/integrations": "6.19.2",
"@sentry/react": "6.19.2",
"@sentry/tracing": "6.19.2",
"@sentry/types": "6.19.2",
"@sentry/utils": "6.19.2",
"@sentry/core": "7.0.0",
"@sentry/hub": "7.0.0",
"@sentry/integrations": "7.0.0",
"@sentry/react": "7.0.0",
"@sentry/tracing": "7.0.0",
"@sentry/types": "7.0.0",
"@sentry/utils": "7.0.0",
"@sentry/wizard": "^1.2.17"
},
"devDependencies": {
"@sentry-internal/eslint-config-sdk": "6.19.2",
"@sentry-internal/eslint-plugin-sdk": "6.19.2",
"@sentry-internal/eslint-config-sdk": "7.0.0",
"@sentry-internal/eslint-plugin-sdk": "7.0.0",
"@sentry/typescript": "^5.20.1",
"@types/jest": "^26.0.15",
"@types/react": "^16.9.49",
Expand All @@ -69,7 +69,7 @@
"replace-in-file": "^6.0.0",
"rimraf": "^3.0.0",
"ts-jest": "^24.3.0",
"typescript": "^3.4.5"
"typescript": "3.8.3"
},
"rnpm": {
"commands": {
Expand Down
10 changes: 6 additions & 4 deletions sample/ios/sample.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@
);
inputPaths = (
"${PODS_ROOT}/Target Support Files/Pods-sample-sampleTests/Pods-sample-sampleTests-frameworks.sh",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/hermes/hermes.framework/hermes",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/hermes-engine/hermes.framework/hermes",
);
name = "[CP] Embed Pods Frameworks";
outputPaths = (
Expand Down Expand Up @@ -495,7 +495,7 @@
);
inputPaths = (
"${PODS_ROOT}/Target Support Files/Pods-sample/Pods-sample-frameworks.sh",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/hermes/hermes.framework/hermes",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/hermes-engine/hermes.framework/hermes",
);
name = "[CP] Embed Pods Frameworks";
outputPaths = (
Expand Down Expand Up @@ -723,6 +723,7 @@
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_TEAM = 62L9982P5R;
ENABLE_BITCODE = NO;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "i386 arm64";
GCC_PREPROCESSOR_DEFINITIONS = (
"$(inherited)",
"FB_SONARKIT_ENABLED=1",
Expand Down Expand Up @@ -750,6 +751,7 @@
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_TEAM = 97JCY7859U;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "i386 arm64";
INFOPLIST_FILE = sample/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
OTHER_LDFLAGS = (
Expand Down Expand Up @@ -907,7 +909,7 @@
COPY_PHASE_STRIP = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "arm64 i386";
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
Expand Down Expand Up @@ -969,7 +971,7 @@
COPY_PHASE_STRIP = YES;
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "arm64 i386";
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,37 +2,52 @@
"images" : [
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "2x"
"scale" : "2x",
"size" : "20x20"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "3x"
"scale" : "3x",
"size" : "20x20"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "2x"
"scale" : "2x",
"size" : "29x29"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
"scale" : "3x",
"size" : "29x29"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "2x"
"scale" : "2x",
"size" : "40x40"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
"scale" : "3x",
"size" : "40x40"
},
{
"idiom" : "iphone",
"scale" : "2x",
"size" : "60x60"
},
{
"idiom" : "iphone",
"scale" : "3x",
"size" : "60x60"
},
{
"idiom" : "ios-marketing",
"scale" : "1x",
"size" : "1024x1024"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
"author" : "xcode",
"version" : 1
}
}
27 changes: 14 additions & 13 deletions sample/src/screens/HomeScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,14 @@ import {
TouchableOpacity,
View,
} from 'react-native';
import {StackNavigationProp} from '@react-navigation/stack';
import {CommonActions} from '@react-navigation/native';
import { StackNavigationProp } from '@react-navigation/stack';
import { CommonActions } from '@react-navigation/native';

import * as Sentry from '@sentry/react-native';

import {getTestProps} from '../../utils/getTestProps';
import {SENTRY_INTERNAL_DSN} from '../dsn';
import { getTestProps } from '../../utils/getTestProps';
import { SENTRY_INTERNAL_DSN } from '../dsn';
import { SeverityLevel } from '@sentry/types';

interface Props {
navigation: StackNavigationProp<any, 'HomeScreen'>;
Expand Down Expand Up @@ -51,7 +52,7 @@ const HomeScreen = (props: Props) => {
Sentry.setExtra('SINGLE-EXTRA-OBJECT', {
message: 'I am a teapot',
status: 418,
array: ['boo', 100, 400, {objectInsideArray: 'foobar'}],
array: ['boo', 100, 400, { objectInsideArray: 'foobar' }],
});
Sentry.setExtras({
'MULTI-EXTRA-0': dateString,
Expand All @@ -71,23 +72,23 @@ const HomeScreen = (props: Props) => {
});

Sentry.addBreadcrumb({
level: Sentry.Severity.Info,
level: 'info' as SeverityLevel,
message: `TEST-BREADCRUMB-INFO: ${dateString}`,
});
Sentry.addBreadcrumb({
level: Sentry.Severity.Debug,
level: 'debug' as SeverityLevel,
message: `TEST-BREADCRUMB-DEBUG: ${dateString}`,
});
Sentry.addBreadcrumb({
level: Sentry.Severity.Error,
level: 'error' as SeverityLevel,
message: `TEST-BREADCRUMB-ERROR: ${dateString}`,
});
Sentry.addBreadcrumb({
level: Sentry.Severity.Fatal,
level: 'fatal' as SeverityLevel,
message: `TEST-BREADCRUMB-FATAL: ${dateString}`,
});
Sentry.addBreadcrumb({
level: Sentry.Severity.Info,
level: 'info' as SeverityLevel,
message: `TEST-BREADCRUMB-DATA: ${dateString}`,
data: {
stringTest: 'Hello',
Expand Down Expand Up @@ -210,7 +211,7 @@ const HomeScreen = (props: Props) => {
</TouchableOpacity>
<View style={styles.spacer} />
<Sentry.ErrorBoundary
fallback={({eventId}) => (
fallback={({ eventId }) => (
<Text>Error boundary caught with event id: {eventId}</Text>
)}>
<TouchableOpacity
Expand Down Expand Up @@ -245,10 +246,10 @@ const HomeScreen = (props: Props) => {
CommonActions.reset({
index: 1,
routes: [
{name: 'Home'},
{ name: 'Home' },
{
name: 'PerformanceTiming',
params: {someParam: 'hello'},
params: { someParam: 'hello' },
},
],
}),
Expand Down
Loading