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

Error Running App in iOS on Mac #21648

Closed
expertalex opened this issue Oct 10, 2018 · 5 comments
Closed

Error Running App in iOS on Mac #21648

expertalex opened this issue Oct 10, 2018 · 5 comments
Labels
Platform: iOS iOS applications. Resolution: Locked This issue was locked by the bot.

Comments

@expertalex
Copy link

expertalex commented Oct 10, 2018

Hello! I have problems building and running the app form my Mac in iOS

Environment

  React Native Environment Info:
    System:
      OS: macOS 10.14
      CPU: x64 Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz
      Memory: 2.66 GB / 16.00 GB
      Shell: 3.2.57 - /bin/bash
    Binaries:
      Node: 10.11.0 - /usr/local/bin/node
      Yarn: 1.10.1 - /usr/local/bin/yarn
      Watchman: 4.9.0 - /usr/local/bin/watchman
    SDKs:
      iOS SDK:
        Platforms: iOS 12.0, macOS 10.14, tvOS 12.0, watchOS 5.0
    IDEs:
      Android Studio: 3.2 AI-181.5540.7.32.5014246
      Xcode: 10.0/10A255 - /usr/bin/xcodebuild
    npmPackages:
      react: 16.5.0 => 16.5.0 
      react-native: 0.57.2 => 0.57.2 

Description:

Step 1:

react-native init AwesomeProject
cd AwesomeProject
react-native run-ios

Error:


** BUILD FAILED **



The following build commands failed:
	CompileC /Users/alexbel/WebstormProjects/RNProject2/ios/build/Build/Intermediates.noindex/React.build/Debug-iphonesimulator/double-conversion.build/Objects-normal/x86_64/fast-dtoa.o /Users/alexbel/WebstormProjects/RNProject2/node_modules/react-native/third-party/double-conversion-1.1.6/src/fast-dtoa.cc normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
	CompileC /Users/alexbel/WebstormProjects/RNProject2/ios/build/Build/Intermediates.noindex/React.build/Debug-iphonesimulator/double-conversion.build/Objects-normal/x86_64/strtod.o /Users/alexbel/WebstormProjects/RNProject2/node_modules/react-native/third-party/double-conversion-1.1.6/src/strtod.cc normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
	CompileC /Users/alexbel/WebstormProjects/RNProject2/ios/build/Build/Intermediates.noindex/React.build/Debug-iphonesimulator/double-conversion.build/Objects-normal/x86_64/double-conversion.o /Users/alexbel/WebstormProjects/RNProject2/node_modules/react-native/third-party/double-conversion-1.1.6/src/double-conversion.cc normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
	CompileC /Users/alexbel/WebstormProjects/RNProject2/ios/build/Build/Intermediates.noindex/React.build/Debug-iphonesimulator/double-conversion.build/Objects-normal/x86_64/diy-fp.o /Users/alexbel/WebstormProjects/RNProject2/node_modules/react-native/third-party/double-conversion-1.1.6/src/diy-fp.cc normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
	CompileC /Users/alexbel/WebstormProjects/RNProject2/ios/build/Build/Intermediates.noindex/React.build/Debug-iphonesimulator/double-conversion.build/Objects-normal/x86_64/fixed-dtoa.o /Users/alexbel/WebstormProjects/RNProject2/node_modules/react-native/third-party/double-conversion-1.1.6/src/fixed-dtoa.cc normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
	CompileC /Users/alexbel/WebstormProjects/RNProject2/ios/build/Build/Intermediates.noindex/React.build/Debug-iphonesimulator/double-conversion.build/Objects-normal/x86_64/cached-powers.o /Users/alexbel/WebstormProjects/RNProject2/node_modules/react-native/third-party/double-conversion-1.1.6/src/cached-powers.cc normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
	CompileC /Users/alexbel/WebstormProjects/RNProject2/ios/build/Build/Intermediates.noindex/React.build/Debug-iphonesimulator/double-conversion.build/Objects-normal/x86_64/bignum.o /Users/alexbel/WebstormProjects/RNProject2/node_modules/react-native/third-party/double-conversion-1.1.6/src/bignum.cc normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
(7 failures)

Installing build/Build/Products/Debug-iphonesimulator/RNProject2.app
An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=22):
Failed to install the requested application
The bundle identifier of the application could not be determined.
Ensure that the application's Info.plist contains a value for CFBundleIdentifier.
Print: Entry, ":CFBundleIdentifier", Does Not Exist

Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/RNProject2.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist


Error: Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/RNProject2.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist

Step 2:

  1. Open Project in Xcode
  2. Run (Error In Signing)
  3. Sign the project [to fix the Xcode Error]
  4. Run Again (Running Metro Bundler on port 8081. terminal window appears + Build Succeed)
  5. App Launches With Error [Red Screen]
Failed to load bundle(http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false) with error:(Unable to resolve module `./../react-transform-hmr/lib/index.js` from `/Users/alexbel/WebstormProjects/RNProject2/App.js`: The module `./../react-transform-hmr/lib/index.js` could not be found from `/Users/alexbel/WebstormProjects/RNProject2/App.js`. Indeed, none of these files exist:
  * `/Users/alexbel/WebstormProjects/react-transform-hmr/lib/index.js(.native||.ios.js|.native.js|.js|.ios.json|.native.json|.json|.ios.ts|.native.ts|.ts|.ios.tsx|.native.tsx|.tsx)`
  * `/Users/alexbel/WebstormProjects/react-transform-hmr/lib/index.js/index(.native||.ios.js|.native.js|.js|.ios.json|.native.json|.json|.ios.ts|.native.ts|.ts|.ios.tsx|.native.tsx|.tsx)` (null))

__38-[RCTCxxBridge loadSource:onProgress:]_block_invoke.248
    RCTCxxBridge.mm:429
___ZL36attemptAsynchronousLoadOfBundleAtURLP5NSURLU13block_pointerFvP18RCTLoadingProgressEU13block_pointerFvP7NSErrorP9RCTSourceE_block_invoke.118
__80-[RCTMultipartDataTask URLSession:streamTask:didBecomeInputStream:outputStream:]_block_invoke
-[RCTMultipartStreamReader emitChunk:headers:callback:done:]
-[RCTMultipartStreamReader readAllPartsWithCompletionCallback:progressCallback:]
-[RCTMultipartDataTask URLSession:streamTask:didBecomeInputStream:outputStream:]
__88-[NSURLSession delegate_streamTask:didBecomeInputStream:outputStream:completionHandler:]_block_invoke
__NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__
-[NSBlockOperation main]
-[__NSOperationInternal _start:]
__NSOQSchedule_f
_dispatch_call_block_and_release
_dispatch_client_callout
_dispatch_continuation_pop
_dispatch_async_redirect_invoke
_dispatch_root_queue_drain
_dispatch_worker_thread2
_pthread_wqthread
start_wqthread

screenshot 2018-10-10 at 19 44 32

Questions

  1. Why I can't run the project without signing?
  2. Why this error Appears? & How to solve it?

Thanks

@react-native-bot react-native-bot added the Platform: iOS iOS applications. label Oct 10, 2018
@felimoles
Copy link

felimoles commented Oct 10, 2018

same problem (with react-native 0.57.2) , downgrade the react-native version (0.57.1)
rm -rm node_modules

in package.json

  "dependencies": {
    "react": "16.5.0",
    "react-native": "0.57.1"
  },
  "devDependencies": {
    "babel-jest": "23.6.0",
    "jest": "23.6.0",
    "metro-react-native-babel-preset": "0.48.0",
    "react-test-renderer": "16.5.0"
  },

is weird but.. i dont know whats is the problem, the package is react-native lib
grettings

@sw-tt-keyurprajapati
Copy link

In terminal perform,
react-native start --reset-cache
and then
react-native run-ios or react-native run-android
in new terminal window works for me.

@saxenanickk
Copy link
Contributor

saxenanickk commented Oct 11, 2018

yarn add @babel/runtime or npm install @babel/runtime --save

@rodrigoelp
Copy link

You don't need to add the babel runtime... react-native run-ios is broken in general #21741

@kelset
Copy link
Contributor

kelset commented Oct 12, 2018

Duplicate of #21490

@kelset kelset marked this as a duplicate of #21490 Oct 12, 2018
@kelset kelset closed this as completed Oct 12, 2018
@facebook facebook locked as spam and limited conversation to collaborators Oct 12, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Oct 12, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Platform: iOS iOS applications. Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

7 participants