getsentry / getsentry/sentry-react-native

Sentry wizard install into bare react-native project breaks use of react-native-version because of code added to project.pbxproj

Offen
#3,888 2 Kommentare 1 Reaktion 0 zugewiesene Personen Auf GitHub ansehen
Errors Improvement React-Native
Vorherrschende Sprache
TypeScript
Sterne
1.8k
Forks
366
Ø Merge
1 T. 6 Std.
Gemergte PRs (30 T.)
94

Beschreibung

**OS:**

- [ ] Windows
- \[ X\] MacOS
- [ ] Linux

**Platform:**

- \[ X\] iOS
- [ ] Android

**SDK:**

- \[X \] `@sentry/react-native` (>= 1.0.0)
- [ ] `react-native-sentry` (<= 0.43.2)

**SDK version:** 0.0.0

`react-native` version: 0.0.0

**Are you using Expo?**

- [ ] Yes
- \[X \] No

**Are you using **[**sentry.io**]()** or on-premise?**

- \[ X\] [sentry.io]() (SaaS)
- [ ] on-premise

---

**I have the following issue:**

The sentry install wizard updated my project.pbxproj file and made it unparseable by react-native-version

**Previous bits**

```
shellScript = "set -e\n\nWITH_ENVIRONMENT=\"../node_modules/react-native/scripts/xcode/with-environment.sh\"\nREACT_NATIVE_XCODE=\"../node_modules/react-native/scripts/react-native-xcode.sh\"\n\n/bin/sh -c \"$WITH_ENVIRONMENT $REACT_NATIVE_XCODE\"\n";
```

**New (and unparse-able bits) result:**

```
shellScript = "set -e\n\nWITH_ENVIRONMENT=\"../node_modules/react-native/scripts/xcode/with-environment.sh\"\nREACT_NATIVE_XCODE=\"../node_modules/react-native/scripts/react-native-xcode.sh\"\n\n/bin/sh -c \"$WITH_ENVIRONMENT \\\"/bin/sh ../node_modules/@sentry/react-native/scripts/sentry-xcode.sh $REACT_NATIVE_XCODE\\\"\"\n";
```

**Error from react-nativer-version**

```
[RNV] SyntaxError: Expected "\"", "\\'", "\\\"", "\\n", or [^\\"] but "\\" found.
```

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Reproduziere den Sentry-Installationsassistenten in einem unveränderten React Native iOS-Projekt und untersuche den generierten project.pbxproj-Eintrag shellScript. Vergleiche ihn mit dem Beispiel vor der Installation und führe react-native-version mit dem Ergebnis aus. Als erledigt gilt, wenn das vom Assistenten installierte project.pbxproj für react-native-version weiterhin analysierbar bleibt und dabei die Sentry- und React-Native-Befehle beibehält.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
react-native
Bereich
build-system, mobile
Issue-Typ
Bug
Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.