Hi there! Thanks for this project, setup process is pretty smooth. I am, however, seeing an issue with the dSYM upload script phase. The script runs fine, but my Info.plist file fails to parse, with the reason "invalid data".
My info.plist is not terribly crazy. I had one env var in there that I removed, but the problem seems to persist. Here's a somewhat obfuscated info.plist (nothing important missing):
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleDisplayName</key>
<string>Acme</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleURLSchemes</key>
<array>
<string>obfuscated FB token</string>
</array>
</dict>
</array>
<key>CFBundleVersion</key>
<string>25</string>
<key>Fabric</key>
<dict>
<key>APIKey</key>
<string>obfuscated fabric token</string>
<key>Kits</key>
<array>
<dict>
<key>KitInfo</key>
<dict/>
<key>KitName</key>
<string>Crashlytics</string>
</dict>
</array>
</dict>
<key>FacebookAppID</key>
<string>obfuscated FB app ID</string>
<key>FacebookDisplayName</key>
<string>obfuscated FB display name</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSApplicationQueriesSchemes</key>
<array>
<string>fbapi</string>
<string>fb-messenger-api</string>
<string>fb-messenger-share-api</string>
<string>fbauth2</string>
<string>fbshareextension</string>
</array>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
<key>localhost</key>
<dict>
<key>NSExceptionAllowsInsecureHTTPLoads</key>
<true/>
</dict>
</dict>
</dict>
<key>NSCameraUsageDescription</key>
<string>$(PRODUCT_NAME) would like to use your camera.</string>
<key>NSLocationWhenInUseUsageDescription</key>
<string></string>
<key>NSPhotoLibraryAddUsageDescription</key>
<string>$(PRODUCT_NAME) would like to save photos to your photo gallery.</string>
<key>NSPhotoLibraryUsageDescription</key>
<string>$(PRODUCT_NAME) would like access to your photo gallery.</string>
<key>UIAppFonts</key>
<array>
<string>Lato-Black.ttf</string>
<string>Lato-BlackItalic.ttf</string>
<string>Lato-Bold.ttf</string>
<string>Lato-BoldItalic.ttf</string>
<string>Lato-Hairline.ttf</string>
<string>Lato-HairlineItalic.ttf</string>
<string>Lato-Italic.ttf</string>
<string>Lato-LightItalic.ttf</string>
<string>Lato-Regular.ttf</string>
</array>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UIStatusBarHidden</key>
<true/>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
</array>
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
</dict>
</plist>
Any idea what might be causing the issue in there? Might it be possible to patch the parser to output the line number on which it fails? Could help folks in the future diagnose their property list files.
Cheers!
I am facing the same issue. When I run my Info.plist through plutil it says OK
Xcode 9.2
"react-native": 0.51.0
"react-native-sentry": 0.32.1
I am having the same issue but it only occurs for me when I set an Info.plist Preprocessor Prefix File as described in the extra iOS steps for react-native-config. Not sure if this helps at all.
@threesquared Very interesting! I'm using react-native-config as well and had that flag set to YES. Setting it to NO solves the problem for me. My guess then is that the sentry/cli script gets tripped up with prefix for preprocessed info.plist files. I don't use config values in my info.plist so for now I can just keep that flag off.
This is fixed preliminarily in 1.28.4. Please feel free to reopen, if you keep getting errors.
@mitsuhiko we should tackle this in Feb.
Reopening this, as there is still no ideal solution in place. See https://github.com/getsentry/sentry-cli/pull/232#issuecomment-360443186
Hi @jan-auer, Is this solved ?
@jeiemgi sadly not. the workaround is to not require the preprocessor for now.
I know this is not ideal but fixing this issue showed that we went down a stupid road with this and a correct fix requires a different workflow which is a bigger deal to implement.
So much thanks @mitsuhiko . I was o ly confused because I saw they did a merge that was fixing g this, but I'll wait then
@mitsuhiko Has there been any plans to implement the different workflow? This has been an issue for almost a year. This breaks compatibility with react-native-config which really sucks.
I would like to see some kind of plan and timeline to resolve this, especially for paying customers.
The solution @threesquared and @michael-gillett mentioned above unfortunately doesn't work for me, perhaps due to some further changes to the codebase during this time period. Any workaround, if a proper fix to this is not coming anytime soon?
My situation is fixed by sentry-cli v1.38.1
Is this one bug already fixed?? @mitsuhiko @jan-auer
@gsklee There was a bug introduced in sentry-cli v1.38.0 and fixed in 1.38.1 that you might have run into (see also https://github.com/getsentry/sentry-cli/issues/476).
This issue refers to sentry-cli not being able to expand XCode variables when parsing Info.plist. I'm afraid that this is still not fixed in the latest release.
I just ran into this issue, and for me it was a comment in Info.plist 🤦♂️
Closing the issue, as it seems like the original issue has been resolved.
Please do not hesitate to ping me if it is still relevant, and I will happily reopen and work on it.
Cheers!
Most helpful comment
@mitsuhiko Has there been any plans to implement the different workflow? This has been an issue for almost a year. This breaks compatibility with
react-native-configwhich really sucks.I would like to see some kind of plan and timeline to resolve this, especially for paying customers.