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

Build fails on iOS, error: bad json: EOF while parsing a value at line 1 column 0 #135

Closed
Pedneri1 opened this issue Jul 3, 2017 · 12 comments
Assignees

Comments

@Pedneri1
Copy link

Pedneri1 commented Jul 3, 2017

Hello,

After installing Sentry, configuring it following the instructions in the documentation the build for iOS is now working anymore.

It throws this error:

> Found 1 debug symbol files. Checking for missing symbols on server

error: bad json: EOF while parsing a value at line 1 column 0

** BUILD FAILED **

The following build commands failed:

	PhaseScriptExecution Upload\ Debug\ Symbols\ to\ Sentry build/Build/Intermediates/Olhos.build/Debug-iphonesimulator/Olhos.build/Script-CD6E5E94B95B4B5192C5AAC8.sh
(1 failure)

Anybody knows how to solve it ? Thanks

@HazAT
Copy link
Member

HazAT commented Jul 5, 2017

Does this happen every time?
We're pretty sure that's an error on our server, but we are still trying to figure out the exact circumstances when this occurs.

@HazAT HazAT self-assigned this Jul 5, 2017
@Pedneri1
Copy link
Author

Pedneri1 commented Jul 5, 2017

Yes, it happens every time.

I figured out how to avoid this error, maybe a workaround.

In xCode > Build Phases > Upload Debug Symbols to Sentry there is only:

export SENTRY_PROPERTIES=sentry.properties

And now no error is shown. Hope this help you guys to figure out what is going on.

@HazAT HazAT closed this as completed Jul 5, 2017
@vdolbilov
Copy link

Was getting a similar error.

Xcode build phase was

export SENTRY_PROPERTIES=sentry.properties
../node_modules/sentry-cli-binary/bin/sentry-cli upload-dsym

and I changed it to

export NODE_BINARY=node
export SENTRY_PROPERTIES=sentry.properties
../node_modules/sentry-cli-binary/bin/sentry-cli react-native xcode \
../node_modules/react-native/packager/react-native-xcode.sh

via the docs here for RN < 0.46 (using 0.45). Looks like react-native link react-native-sentry doesn't add this properly.

@pvinis
Copy link

pvinis commented Oct 11, 2017

it happens for me too, every time.
if i compile from inside xcode, its fine.
if i compile from fastlane, i get this error.

@MrHubble
Copy link

@pvinis did you find a solution to allow it to compile with fastlane with Sentry?

@pvinis
Copy link

pvinis commented Nov 15, 2018

I ditched sentry and use bugsnag for a while now. I'm happy with it.

@daveols
Copy link

daveols commented Nov 16, 2018

To @MrHubble and future weary travellers from Google...

I had this issue when building with Sentry for iOS but I only saw it in a CI environment. The solution for me was to add a default alias for nvm in the CI installation step, i.e:

nvm install 10
+nvm alias default 10

This will only work if you're using nvm in CI. If you installed it differently, try ensuring the node binary is present when Xcode calls your build scripts.

@cihati
Copy link

cihati commented Dec 14, 2018

EDIT: I looked into /Users/distiller/Library/Logs/gym/mobile-mobile.log inside CircleCI container, and saw that the real issue was "Error: fsevents unavailable (this watcher can only be used on Darwin)". I do brew install watchman and now the issue is gone

I am currently having this issue. Enabled debug level logs for sentry, but still
no clue.

node v11.0.0
sentry-cli 1.37.1
react-native 0.57.5
react-native-sentry 0.39.1
Using CircleCI with Xcode 10.1.0. There is no nvm involved.

▸ Running script 'Bundle React Native code and images'
the transform cache was reset.

❌  error: EOF while parsing a value at line 1 column 0


** ARCHIVE FAILED **


The following build commands failed:
PhaseScriptExecution Bundle\ React\ Native\ code\ and\ images /Users/distiller/Library/Developer/Xcode/DerivedData/mobile-aacuhcnqhpzojtfjnelqujdbjoae/Build/Intermediates.noindex/ArchiveIntermediates/mobile/IntermediateBuildFilesPath/mobile.build/Release-iphoneos/mobile.build/Script-00DD1BFF1BD5951E006B06BC.sh
(1 failure)
[07:46:40]: Exit status: 65
[07:46:40]: 
[07:46:40]: Maybe the error shown is caused by using the wrong version of Xcode
[07:46:40]: Found multiple versions of Xcode in '/Applications/'
[07:46:40]: Make sure you selected the right version for your project
[07:46:40]: This build process was executed using '/Applications/Xcode-10.1.app'
[07:46:40]: If you want to update your Xcode path, either
[07:46:40]: 
[07:46:40]: - Specify the Xcode version in your Fastfile
[07:46:40]: ▸ xcversion(version: "8.1") # Selects Xcode 8.1.0
[07:46:40]: 
[07:46:40]: - Specify an absolute path to your Xcode installation in your Fastfile
[07:46:40]: ▸ xcode_select "/Applications/Xcode8.app"
[07:46:40]: 
[07:46:40]: - Manually update the path using
[07:46:40]: ▸ sudo xcode-select -s /Applications/Xcode.app
[07:46:40]: 

+---------------+------------------------------+
|              Build environment               |
+---------------+------------------------------+
| xcode_path    | /Applications/Xcode-10.1.app |
| gym_version   | 2.104.0                      |
| export_method | app-store                    |
| sdk           | iPhoneOS12.1.sdk             |
+---------------+------------------------------+

[07:46:40]: ▸ + [[ ! -f /Users/distiller/Library/Developer/Xcode/DerivedData/mobile-aacuhcnqhpzojtfjnelqujdbjoae/Build/Intermediates.noindex/ArchiveIntermediates/mobile/BuildProductsPath/Release-iphoneos/mobile.app/main.jsbundle ]]
[07:46:40]: ▸   DEBUG   2018-12-14 07:46:37.791786 -08:00 error: running update nagger
[07:46:40]: ▸   DEBUG   2018-12-14 07:46:37.791846 -08:00 skipping update nagger because session is not attended
[07:46:40]: ▸ error: EOF while parsing a value at line 1 column 0
[07:46:40]: ▸   DEBUG   2018-12-14 07:46:37.792409 -08:00 client close; no transport to shut down  (from sentry)
[07:46:40]:

might be relevant also:

bash-3.2$ cat /Users/distiller/Library/Developer/Xcode/DerivedData/mobile-aacuhcnqhpzojtfjnelqujdbjoae/Build/Intermediates.noindex/ArchiveIntermediates/mobile/IntermediateBuildFilesPath/mobile.build/Release-iphoneos/mobile.build/Script-00DD1BFF1BD5951E006B06BC.sh
#!/bin/sh
export SENTRY_PROPERTIES=sentry.properties
export NODE_BINARY=node
export SENTRY_LOG_LEVEL=debug
/usr/local/bin/sentry-cli react-native xcode ../node_modules/react-native/scripts/react-native-xcode.sh

any ideas @HazAT ?

@anniewey
Copy link

anniewey commented Jan 7, 2019

Same problem as @cihati when run on CI. Any solution yet?

@sibelius
Copy link

we are having this problem on circleci when we moved to pod and xcworkspaces

is there a workaround?

@abury
Copy link

abury commented Jul 18, 2019

Also seeing this on CI

@pablen
Copy link

pablen commented Oct 4, 2019

Thanks @cihati! Had the exact same error when running on Travis. Had to add watchman to my travis.yml file

before_install:
    ...       
    - brew install watchman

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests