@sentry/react-native 7.0.0-rc.2 → 7.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/RNSentry.podspec +3 -1
- package/android/src/main/java/io/sentry/react/RNSentryModuleImpl.java +2 -5
- package/android/src/main/java/io/sentry/react/RNSentryVersion.java +1 -1
- package/dist/js/client.d.ts.map +1 -1
- package/dist/js/client.js +6 -3
- package/dist/js/client.js.map +1 -1
- package/dist/js/integrations/default.js +4 -4
- package/dist/js/integrations/default.js.map +1 -1
- package/dist/js/options.d.ts +1 -1
- package/dist/js/options.d.ts.map +1 -1
- package/dist/js/options.js.map +1 -1
- package/dist/js/tools/utils.d.ts.map +1 -1
- package/dist/js/tools/utils.js +39 -10
- package/dist/js/tools/utils.js.map +1 -1
- package/dist/js/tools/vendor/metro/utils.d.ts.map +1 -1
- package/dist/js/tools/vendor/metro/utils.js +28 -6
- package/dist/js/tools/vendor/metro/utils.js.map +1 -1
- package/dist/js/tracing/timetodisplay.d.ts.map +1 -1
- package/dist/js/tracing/timetodisplay.js +1 -11
- package/dist/js/tracing/timetodisplay.js.map +1 -1
- package/dist/js/utils/environment.d.ts.map +1 -1
- package/dist/js/utils/environment.js +2 -1
- package/dist/js/utils/environment.js.map +1 -1
- package/dist/js/utils/worldwide.d.ts +1 -0
- package/dist/js/utils/worldwide.d.ts.map +1 -1
- package/dist/js/utils/worldwide.js.map +1 -1
- package/dist/js/version.d.ts +1 -1
- package/dist/js/version.d.ts.map +1 -1
- package/dist/js/version.js +1 -1
- package/dist/js/version.js.map +1 -1
- package/ios/RNSentry+fetchNativeStack.m +101 -0
- package/ios/RNSentry.h +5 -0
- package/ios/RNSentry.mm +23 -81
- package/ios/RNSentryVersion.m +1 -1
- package/package.json +15 -14
- package/plugin/build/withSentryAndroid.js +7 -7
- package/plugin/build/withSentryAndroidGradlePlugin.d.ts +3 -2
- package/plugin/build/withSentryAndroidGradlePlugin.js +11 -22
- package/scripts/expo-upload-sourcemaps.js +1 -1
- package/scripts/sentry_utils.rb +4 -0
- package/ts3.8/dist/js/options.d.ts +1 -1
- package/ts3.8/dist/js/utils/worldwide.d.ts +1 -0
- package/ts3.8/dist/js/version.d.ts +1 -1
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.withSentryAndroidGradlePlugin = exports.sentryAndroidGradlePluginVersion = void 0;
|
|
4
4
|
const config_plugins_1 = require("@expo/config-plugins");
|
|
5
5
|
const utils_1 = require("./utils");
|
|
6
|
-
exports.sentryAndroidGradlePluginVersion = '5.
|
|
6
|
+
exports.sentryAndroidGradlePluginVersion = '5.9.0';
|
|
7
7
|
/**
|
|
8
8
|
* Adds the Sentry Android Gradle Plugin to the project.
|
|
9
9
|
* https://docs.sentry.io/platforms/react-native/manual-setup/manual-setup/#enable-sentry-agp
|
|
@@ -11,32 +11,26 @@ exports.sentryAndroidGradlePluginVersion = '5.8.0';
|
|
|
11
11
|
function withSentryAndroidGradlePlugin(config, { includeProguardMapping = true, dexguardEnabled = false, autoUploadProguardMapping = true, uploadNativeSymbols = true, autoUploadNativeSymbols = true, includeNativeSources = true, includeSourceContext = false, } = {}) {
|
|
12
12
|
// Modify android/build.gradle
|
|
13
13
|
const withSentryProjectBuildGradle = (config) => {
|
|
14
|
-
return (0, config_plugins_1.withProjectBuildGradle)(config,
|
|
15
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
14
|
+
return (0, config_plugins_1.withProjectBuildGradle)(config, projectBuildGradle => {
|
|
16
15
|
if (!projectBuildGradle.modResults?.contents) {
|
|
17
16
|
(0, utils_1.warnOnce)('android/build.gradle content is missing or undefined.');
|
|
18
|
-
return
|
|
17
|
+
return projectBuildGradle;
|
|
19
18
|
}
|
|
20
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
21
19
|
if (projectBuildGradle.modResults.language !== 'groovy') {
|
|
22
20
|
(0, utils_1.warnOnce)('Cannot configure Sentry in android/build.gradle because it is not in Groovy.');
|
|
23
|
-
return
|
|
21
|
+
return projectBuildGradle;
|
|
24
22
|
}
|
|
25
23
|
const dependency = `classpath("io.sentry:sentry-android-gradle-plugin:${exports.sentryAndroidGradlePluginVersion}")`;
|
|
26
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
27
24
|
if (projectBuildGradle.modResults.contents.includes(dependency)) {
|
|
28
25
|
(0, utils_1.warnOnce)('sentry-android-gradle-plugin dependency in already in android/build.gradle.');
|
|
29
|
-
return
|
|
26
|
+
return projectBuildGradle;
|
|
30
27
|
}
|
|
31
28
|
try {
|
|
32
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
33
29
|
const updatedContents = projectBuildGradle.modResults.contents.replace(/dependencies\s*{/, `dependencies {\n ${dependency}`);
|
|
34
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
35
30
|
if (updatedContents === projectBuildGradle.modResults.contents) {
|
|
36
31
|
(0, utils_1.warnOnce)('Failed to inject the dependency. Could not find `dependencies` in build.gradle.');
|
|
37
32
|
}
|
|
38
33
|
else {
|
|
39
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
40
34
|
projectBuildGradle.modResults.contents = updatedContents;
|
|
41
35
|
}
|
|
42
36
|
}
|
|
@@ -48,11 +42,10 @@ function withSentryAndroidGradlePlugin(config, { includeProguardMapping = true,
|
|
|
48
42
|
};
|
|
49
43
|
// Modify android/app/build.gradle
|
|
50
44
|
const withSentryAppBuildGradle = (config) => {
|
|
51
|
-
return (0, config_plugins_1.withAppBuildGradle)(config,
|
|
52
|
-
|
|
53
|
-
if (config.modResults.language !== 'groovy') {
|
|
45
|
+
return (0, config_plugins_1.withAppBuildGradle)(config, appBuildGradle => {
|
|
46
|
+
if (appBuildGradle.modResults.language !== 'groovy') {
|
|
54
47
|
(0, utils_1.warnOnce)('Cannot configure Sentry in android/app/build.gradle because it is not in Groovy.');
|
|
55
|
-
return
|
|
48
|
+
return appBuildGradle;
|
|
56
49
|
}
|
|
57
50
|
const sentryPlugin = 'apply plugin: "io.sentry.android.gradle"';
|
|
58
51
|
const sentryConfig = `
|
|
@@ -71,19 +64,15 @@ function withSentryAndroidGradlePlugin(config, { includeProguardMapping = true,
|
|
|
71
64
|
enabled = false
|
|
72
65
|
}
|
|
73
66
|
}`;
|
|
74
|
-
|
|
75
|
-
let contents = config.modResults.contents;
|
|
76
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
67
|
+
let contents = appBuildGradle.modResults.contents;
|
|
77
68
|
if (!contents.includes(sentryPlugin)) {
|
|
78
69
|
contents = `${sentryPlugin}\n${contents}`;
|
|
79
70
|
}
|
|
80
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
81
71
|
if (!contents.includes('sentry {')) {
|
|
82
72
|
contents = `${contents}\n${sentryConfig}`;
|
|
83
73
|
}
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
return config;
|
|
74
|
+
appBuildGradle.modResults.contents = contents;
|
|
75
|
+
return appBuildGradle;
|
|
87
76
|
});
|
|
88
77
|
};
|
|
89
78
|
return withSentryAppBuildGradle(withSentryProjectBuildGradle(config));
|
|
@@ -234,7 +234,7 @@ if (numAssetsUploaded === totalAssets) {
|
|
|
234
234
|
console.log('✅ Uploaded bundles and sourcemaps to Sentry successfully.');
|
|
235
235
|
} else {
|
|
236
236
|
console.warn(
|
|
237
|
-
`⚠️ Uploaded ${numAssetsUploaded} of ${totalAssets} bundles and sourcemaps. ${numAssetsUploaded === 0 ? 'Ensure you are running `expo export` with the `--
|
|
237
|
+
`⚠️ Uploaded ${numAssetsUploaded} of ${totalAssets} bundles and sourcemaps. ${numAssetsUploaded === 0 ? 'Ensure you are running `expo export` with the `--source-maps` flag.' : ''
|
|
238
238
|
}`,
|
|
239
239
|
);
|
|
240
240
|
}
|
package/scripts/sentry_utils.rb
CHANGED
|
@@ -6,7 +6,7 @@ import type { TouchEventBoundaryProps } from './touchevents';
|
|
|
6
6
|
type ProfilerProps = React.ComponentProps<typeof Profiler>;
|
|
7
7
|
type BrowserTransportOptions = Parameters<typeof makeFetchTransport>[0];
|
|
8
8
|
type BrowserExperiments = NonNullable<BrowserOptions['_experiments']>;
|
|
9
|
-
type SharedExperimentsSubset =
|
|
9
|
+
type SharedExperimentsSubset = BrowserExperiments;
|
|
10
10
|
export interface BaseReactNativeOptions {
|
|
11
11
|
/**
|
|
12
12
|
* Enables native transport + device info + offline caching.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export declare const SDK_PACKAGE_NAME = "npm:@sentry/react-native";
|
|
2
2
|
export declare const SDK_NAME = "sentry.javascript.react-native";
|
|
3
|
-
export declare const SDK_VERSION = "7.0.
|
|
3
|
+
export declare const SDK_VERSION = "7.0.1";
|
|
4
4
|
//# sourceMappingURL=version.d.ts.map
|