skip to Main Content

I started working recently with React Native on my Mac, I set up everything according to the official documentation. Then I use npx react-native init ProjectName to create a new project, everything works without error, but when I try to run it on ios (using npm run ios), it fails with the only two errors I could read below:

  • PhaseScriptExecution [CP-User] Generate Specs /Users/theblsk/Library/Developer/Xcode/DerivedData/ImageTutorial-badaedcsguwjbrafbryakosuwhkp/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/React-rncore.build/Script-46EB2E00018190.sh (in target ‘React-rncore’ from project ‘Pods’)
    (1 failure)
  • error Failed to build iOS project. We ran "xcodebuild" command but it exited with error code 65. To debug build logs further, consider building your app with Xcode.app, by opening ImageTutorial.xcworkspace.

Information about the environment used:

  • Ruby 3.2.2 installed with Rbenv
  • Node version 18 (with NVM)
  • React Native 0.72.3
  • react-native doctor detects no issues

P.S: Another project made with React Native worked like a charm with the same exact configuration, nothing was changed. (seems the error is inconsistent between projects)

Thank you in advance!

I tried everything related to this error on the internet and nothing worked, it seems like my problem is very specific and I can’t figure out the problem.

2

Answers


  1. Chosen as BEST ANSWER

    thought I’d help anyone who finds this question, turns out the whole problem is that I have a space in the name of the immediate parent folder of this app, weird problem in my opinion but it fixes it. Hope this helps someone!


  2. I hope this helps somebody; downgrading the node version to v14.21.3 helped me fix this issue. For me, the bash environment should have v14.21.3.

    Steps I took (bash terminal):

    • brew install node@14
    • brew unlink node
    • brew link –overwrite node@14
    • removed Podfile. lock and deleted pods folder
    • removing all DerivedData (Settings/Locations/DerivedData)
    • Close Xcode
    • cd ios && pod install
    • Try building again

    PS: I am using nvm zsh for node version 18 for all my react native projects; just version 14 is required in bash env for the Xcode build.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search