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

Not able to run ios app in ios simulator #36389

Closed
chaudhary opened this issue Mar 7, 2023 · 9 comments
Closed

Not able to run ios app in ios simulator #36389

chaudhary opened this issue Mar 7, 2023 · 9 comments
Labels
Needs: Triage 🔍 Platform: iOS iOS applications. Stale There has been a lack of activity on this issue and it may be closed soon.

Comments

@chaudhary
Copy link

Description

If I run build through xcode, it works fine.
But running npx react-native run-ios. gives error

React Native Version

0.71.3

Output of npx react-native info

System:
OS: macOS 13.2.1
CPU: (12) x64 Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz
Memory: 137.56 MB / 16.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 19.7.0 - ~/.nvm/versions/node/v19.7.0/bin/node
Yarn: 1.22.19 - ~/.nvm/versions/node/v19.7.0/bin/yarn
npm: 9.5.0 - ~/.nvm/versions/node/v19.7.0/bin/npm
Watchman: 2023.03.06.00 - /usr/local/bin/watchman
Managers:
CocoaPods: 1.12.0 - /Users/amitchaudhary/.rvm/gems/ruby-2.7.6/bin/pod
SDKs:
iOS SDK:
Platforms: DriverKit 22.2, iOS 16.2, macOS 13.1, tvOS 16.1, watchOS 9.1
Android SDK: Not Found
IDEs:
Android Studio: Not Found
Xcode: 14.2/14C18 - /usr/bin/xcodebuild
Languages:
Java: Not Found
npmPackages:
@react-native-community/cli: Not Found
react: 18.2.0 => 18.2.0
react-native: 0.71.3 => 0.71.3
react-native-macos: Not Found
npmGlobalPackages:
react-native: Not Found

Steps to reproduce

  1. create a new app using npx react-native init MyApp
  2. cd MyApp
  3. npx react-native run-ios

Snack, code example, screenshot, or link to a repository

Screenshot 2023-03-07 at 3 52 01 PM

@iBotPeaches
Copy link
Contributor

Based on that error you are pointing to a device that is not available as a destination. You can see the 95Exx device was specified, but the error does not list that as a valid destination.

@chaudhary
Copy link
Author

Why does it find my Macbook Pro as booted device ?
It should look for a simulator and start one if not found

@iBotPeaches
Copy link
Contributor

Why does it find my Macbook Pro as booted device ? It should look for a simulator and start one if not found

You can run applications natively on a Mac as of recently. Chances are some of your native dependencies won't support it, but its possible.

@chaudhary
Copy link
Author

How can I disable that behaviour ?
I don't want to run my application on Mac

@Gnative
Copy link

Gnative commented Mar 9, 2023

Update to 0.71.4 - this should be fixed.

@amnpoosri
Copy link

The fix has been merged react-native-community/cli#1823 but will probably release in the next version of react-native

Alternatively, you can run an iOS app by targeting simlator or use Xcode to run your project

xcrun xctrace list devices
react-native run-ios —udid={device_id}

@roryf
Copy link

roryf commented Mar 10, 2023

Here is the fix above on the current cli version react-native-community/cli#1863 once that's merged hopefully another 0.71 can be released

@github-actions
Copy link

github-actions bot commented Sep 7, 2023

This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Sep 7, 2023
@github-actions
Copy link

This issue was closed because it has been stalled for 7 days with no activity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs: Triage 🔍 Platform: iOS iOS applications. Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

No branches or pull requests

6 participants