react-native cant run ios device

。_饼干妹妹 提交于 2020-04-16 05:49:25

问题


I try to run react-native app on a ios real device. It works well on simulator or on a device using xcode but I would like to run with command-line I tried this :

>npm install -g ios-deploy 

>react-native run-ios --device "My iPhone"

And this is what I get :

info Found Xcode workspace "Project.xcworkspace"
info Building (using "xcodebuild -workspace Project.xcworkspace -configuration Debug -scheme Project -destination id=00008020-0001395426EA002E")
......................................................................
2020-04-06 11:15:02.836 xcodebuild[16724:402803]  DTDeviceKit: deviceType from 00008020-0001395426EA002E was NULL
2020-04-06 11:15:02.967 xcodebuild[16724:402797]  DTDeviceKit: deviceType from 00008020-0001395426EA002E was NULL
info Installing and launching your app on My iPhone

The app appears in my iPhone but doesnt run.

Metro oppens in a new terminal but I get only this :

               ######                ######               
             ###     ####        ####     ###             
            ##          ###    ###          ##            
            ##             ####             ##            
            ##             ####             ##            
            ##           ##    ##           ##            
            ##         ###      ###         ##            
             ##  ########################  ##             
          ######    ###            ###    ######          
      ###     ##    ##              ##    ##     ###      
   ###         ## ###      ####      ### ##         ###   
  ##           ####      ########      ####           ##  
 ##             ###     ##########     ###             ## 
  ##           ####      ########      ####           ##  
   ###         ## ###      ####      ### ##         ###   
      ###     ##    ##              ##    ##     ###      
          ######    ###            ###    ######          
             ##  ########################  ##             
            ##         ###      ###         ##            
            ##           ##    ##           ##            
            ##             ####             ##            
            ##             ####             ##            
            ##          ###    ###          ##            
             ###     ####        ####     ###             
               ######                ######               

                 Welcome to React Native!
                Learn once, write anywhere



To reload the app press "r"
To open developer menu press "d"

And I doesnt get the progress bar that shows on build with XCode.

EDIT

For the logs :

user@MBP Project % react-native log-ios
error No active iOS device found

Versions installed :

user@MBP Project % react-native -v
react-native-cli: 2.0.1
react-native: 0.62.0

来源:https://stackoverflow.com/questions/61056762/react-native-cant-run-ios-device

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!