Skip to content

Commit f5f8461

Browse files
committed
add docs for "Creating release with APK + .app.zip"
1 parent 8d9f553 commit f5f8461

File tree

4 files changed

+37
-29
lines changed

4 files changed

+37
-29
lines changed

README.md

Lines changed: 31 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
This is demo repo is used by Solution Engineers when demo'ing Sentry's [React Native](https://docs.sentry.io/platforms/react-native) SDK's capabilties.
1+
This is demo repo is used by Solution Engineers when demo'ing Sentry's [React Native](https://docs.sentry.io/platforms/react-native) SDK's capabilties.
22

33
<!-- ![Empower PLant](./img/empower-plant.png) -->
44
<img src="./img/empower-plant.png" width="200" height="400">
@@ -7,8 +7,8 @@ This is demo repo is used by Solution Engineers when demo'ing Sentry's [React Na
77

88
## Versions
99

10-
| dependency | version
11-
| ------------- |:-------------:|
10+
| dependency | version
11+
| ------------- |:-------------:|
1212
| react-native | 0.64.0 |
1313
| gradle | 6.7 |
1414
| react | 16.13.1 |
@@ -24,7 +24,7 @@ This step was already performed for adding the sdk to sentry_react_native, but i
2424
```
2525
$npx @sentry/wizard -i reactNative -p ios android
2626
```
27-
The above command launches the [Sentry wizard](https://github.com/getsentry/sentry-wizard) allowing you to [link](https://docs.sentry.io/platforms/react-native/#linking) with the correct Sentry react-native project.
27+
The above command launches the [Sentry wizard](https://github.com/getsentry/sentry-wizard) allowing you to [link](https://docs.sentry.io/platforms/react-native/#linking) with the correct Sentry react-native project.
2828
From our [documentation](https://docs.sentry.io/platforms/react-native/), the following changes happen which you should be aware of:
2929
```
3030
- add the sentry-android package for native crash reporting on Android
@@ -45,9 +45,9 @@ From our [documentation](https://docs.sentry.io/platforms/react-native/), the fo
4545
6. `cd ios && pod install`
4646
7. `npm install`
4747

48-
Don't forget to bump your release version depending on platform
49-
iOS: `Info.plist` `CFBundleShortVersionString`
50-
android: `app.build.gradle` `versionName`
48+
Don't forget to bump your release version depending on platform
49+
iOS: `Info.plist` `CFBundleShortVersionString`
50+
android: `app.build.gradle` `versionName`
5151

5252
## Run
5353

@@ -60,20 +60,20 @@ emulator @Pixel_3_API_30_x86_64 -dns-server 8.8.8.8
6060
```
6161

6262
2. Run Ios or Android app
63-
* _iOS version_:
63+
* _iOS version_:
6464
```
6565
# opens the Metro debugger, has hot reload
66-
npx react-native run-ios --configuration Debug
66+
npx react-native run-ios --configuration Debug
6767
6868
## builds a Release (takes longer)
6969
npx react-native run-ios --configuration Release
7070
npx react-native run-ios --simulator="iPhone 11"
7171
```
72-
* _Android version_:
72+
* _Android version_:
7373
```
7474
npx react-native run-android --variant Release
7575
```
76-
^ this command builds APK for the arch and installs to the emulator.
76+
^ this command builds APK for the arch and installs to the emulator.
7777
^ click 'OK' if you get a pop-up, and it should open Metro
7878

7979

@@ -82,21 +82,21 @@ npx react-native run-android --variant Release
8282

8383
EmpowerPlant | Checkout
8484
:-------------------------:|:-------------------------:
85-
![list of tools](./img/toolstore.png) | ![checkout cart](./img/cart.png)|
85+
![list of tools](./img/toolstore.png) | ![checkout cart](./img/cart.png)|
8686

8787
## Upgrade path
8888
1. npm install, then `pod update` if `pod install` is failing. The pod updating depends on node_modules/@sentry/react-native being set.
8989
2. SDK Manager -> install 'emulator' or anything missing
90-
3. Review previous PR so you know what to expect
90+
3. Review previous PR so you know what to expect
9191

92-
## Troubleshooting
92+
## Troubleshooting
9393

9494
#### Repo
95-
This repo borrowed from [original react-native repo ]( https://github.com/sentry-demos/react-native/commit/269f58d63426065a4de67a3f22d2e774787cd996)
96-
The following may have been borrowed: `package.json`, `package-lock.json`, `ios/Podfile`, `ios/Podfile.lock`, see [pull/2](https://github.com/sentry-demos/sentry_react_native/pull/2)
95+
This repo borrowed from [original react-native repo ]( https://github.com/sentry-demos/react-native/commit/269f58d63426065a4de67a3f22d2e774787cd996)
96+
The following may have been borrowed: `package.json`, `package-lock.json`, `ios/Podfile`, `ios/Podfile.lock`, see [pull/2](https://github.com/sentry-demos/sentry_react_native/pull/2)
9797

9898
Please know that react-native generates it own [.gitignore file](https://stackoverflow.com/questions/49099131/recommended-gitignore-for-react-native/49099219
99-
), which is of course part of this repo, so only those [autogenerated files](https://stackoverflow.com/questions/48448426/why-dont-we-gitignore-ios-and-android-in-react-native ) that are required for a baseline setup and the original demo code (files) are part of this repo.
99+
), which is of course part of this repo, so only those [autogenerated files](https://stackoverflow.com/questions/48448426/why-dont-we-gitignore-ios-and-android-in-react-native ) that are required for a baseline setup and the original demo code (files) are part of this repo.
100100

101101
Please see [Steps](#what-were-the-steps-again) or go through the [first ten commits](https://github.com/sentry-demos/sentry_react_native/commits/master) (and their git log) messages in chronological order, to see the exact commands that were run and what files that were autogenerated.
102102

@@ -117,10 +117,10 @@ pod install
117117
```
118118

119119
#### adding Sentry for first time
120-
When running npx @sentry/wizard -i reactNative -p ios android
121-
At this point, you may get an error like:
122-
`TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received undefined`
123-
It should be safe to look past this error. A minor issue is that it blocks creation of `ios/sentry.properties`. So simply make a copy of `android/sentry.properties` and put it in `ios/sentry.properties`:
120+
When running npx @sentry/wizard -i reactNative -p ios android
121+
At this point, you may get an error like:
122+
`TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received undefined`
123+
It should be safe to look past this error. A minor issue is that it blocks creation of `ios/sentry.properties`. So simply make a copy of `android/sentry.properties` and put it in `ios/sentry.properties`:
124124
```
125125
cp andoid/sentry.properties ios/sentry.properties
126126
cd ios
@@ -136,7 +136,7 @@ npx react-native eject
136136
```
137137

138138
#### Emulators
139-
When running emulator...
139+
When running emulator...
140140
If the app launches and suddenly crashes you may need to reinstall your node package with this command:
141141

142142
```
@@ -156,4 +156,12 @@ You may run into issues if you haven't added sdk and sdk platform-tools to path:
156156
If tools don't load, then swipe-away (kill) the app, then relaunch from app menu in the emulator. If still fails, then go to AVD Manager and 'wipe' the device and run the emulator again.
157157
Could also be a problem with the backend container/app you're requesting the tools from (check that URL/Postman, check TDA job)
158158

159-
When developing locally, must point React Native to http://127.0.0.1:8080/products backend instead of https://localhost:8080/products backend.
159+
When developing locally, must point React Native to http://127.0.0.1:8080/products backend instead of https://localhost:8080/products backend.
160+
161+
162+
## Creating release with APK + .app.zip for [Test-Data Automation](https://github.com/sentry-demos/application-monitoring/tree/master/tests)
163+
164+
First generate the apps using `npx react-native run-ios --configuration Release` for iOS, and `npx react-native run-android --variant Release` for Andriod
165+
166+
167+
`gh releaase create <VERSION> <PATH_TO_ANDROID_APK> <PATH_TO_ZIPPED_IOS_APP>`

app-release.apk

21.1 MB
Binary file not shown.

ios/Podfile.lock

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ PODS:
205205
- React-jsi (= 0.64.0)
206206
- React-perflogger (= 0.64.0)
207207
- React-jsinspector (0.64.0)
208-
- react-native-safe-area-context (3.2.0):
208+
- react-native-safe-area-context (3.3.2):
209209
- React-Core
210210
- React-perflogger (0.64.0)
211211
- React-RCTActionSheet (0.64.0):
@@ -271,7 +271,7 @@ PODS:
271271
- React-cxxreact (= 0.64.0)
272272
- React-jsi (= 0.64.0)
273273
- React-perflogger (= 0.64.0)
274-
- RNCMaskedView (0.1.10):
274+
- RNCMaskedView (0.1.11):
275275
- React
276276
- RNGestureHandler (1.10.3):
277277
- React-Core
@@ -408,7 +408,7 @@ SPEC CHECKSUMS:
408408
BVLinearGradient: e3aad03778a456d77928f594a649e96995f1c872
409409
DoubleConversion: cf9b38bf0b2d048436d9a82ad2abe1404f11e7de
410410
FBLazyVector: 49cbe4b43e445b06bf29199b6ad2057649e4c8f5
411-
FBReactNativeSpec: f21132940a8f408886313ded89588b774fbec4b7
411+
FBReactNativeSpec: f4767e8d082aaa92e9b16398b1109cd743d50d90
412412
glog: 73c2498ac6884b13ede40eda8228cb1eee9d9d62
413413
RCT-Folly: ec7a233ccc97cc556cf7237f0db1ff65b986f27c
414414
RCTRequired: 2f8cb5b7533219bf4218a045f92768129cf7050a
@@ -421,7 +421,7 @@ SPEC CHECKSUMS:
421421
React-jsi: 74341196d9547cbcbcfa4b3bbbf03af56431d5a1
422422
React-jsiexecutor: 06a9c77b56902ae7ffcdd7a4905f664adc5d237b
423423
React-jsinspector: 0ae35a37b20d5e031eb020a69cc5afdbd6406301
424-
react-native-safe-area-context: f0906bf8bc9835ac9a9d3f97e8bde2a997d8da79
424+
react-native-safe-area-context: 5cf05f49df9d17261e40e518481f2e334c6cd4b5
425425
React-perflogger: 9c547d8f06b9bf00cb447f2b75e8d7f19b7e02af
426426
React-RCTActionSheet: 3080b6e12e0e1a5b313c8c0050699b5c794a1b11
427427
React-RCTAnimation: 3f96f21a497ae7dabf4d2f150ee43f906aaf516f
@@ -434,7 +434,7 @@ SPEC CHECKSUMS:
434434
React-RCTVibration: 0fd6b21751a33cb72fce1a4a33ab9678416d307a
435435
React-runtimeexecutor: cad74a1eaa53ee6e7a3620231939d8fe2c6afcf0
436436
ReactCommon: cfe2b7fd20e0dbd2d1185cd7d8f99633fbc5ff05
437-
RNCMaskedView: 5a8ec07677aa885546a0d98da336457e2bea557f
437+
RNCMaskedView: f127cd9652acfa31b91dcff613e07ba18b774db6
438438
RNGestureHandler: a479ebd5ed4221a810967000735517df0d2db211
439439
RNReanimated: 514a11da3a2bcc6c3dfd9de32b38e2b9bf101926
440440
RNScreens: f7ad633b2e0190b77b6a7aab7f914fad6f198d8d
@@ -444,4 +444,4 @@ SPEC CHECKSUMS:
444444

445445
PODFILE CHECKSUM: c50650cff1554a5b7988845b549ad6296a091b9d
446446

447-
COCOAPODS: 1.10.1
447+
COCOAPODS: 1.11.2

sentry_react_native.app.zip

6.14 MB
Binary file not shown.

0 commit comments

Comments
 (0)