Error running Expo app on iOS Simulator - react-native

When attempting to launch an Expo project from the XDE, I am presented with the following issue where the Expo simulator app will not install:
Error running xcrun simctl install booted
/Users/username/.expo/ios-simulator-app-cache/Exponent-X.Y.Z.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.
Error installing or running app. Error: Process exited with non-zero
code: 22
Which will display like the following image in the XDE:

This appears to be a corrupted or incompatible version of the simulator app that is stored on your computer. The Expo Development Environment (XDE) does not resolve this issue automatically.
As mentioned on the Expo and XDE forums, the way to resolve this issue is to navigate to:
~/.expo/ios-simulator-app-cache/
In the Finder, and delete the file Exponent-X.Y.Z where X, Y, and Z represent the version of the app.
Source: https://forums.expo.io/t/error-installing-expo-on-ios-simulator/741

Related

adb: failed to install google.apk: Failure [INSTALL_FAILED_DUPLICATE_PERMISSION: Package com.google.android

i cant insatll main google app(package: com.google.android.googlequicksearchbox) from play store on my android vivo y15s android 12.
on android the error was something about package name conflicting.
then i tried to install the apk file from CMD of google of version 13.48.11.26.arm64 then it showed the error...
adb: failed to install google.apk: Failure [INSTALL_FAILED_DUPLICATE_PERMISSION: Package com.google.android.googlequicksearchbox attempting to redeclare permiss ion com.google.android.apps.now.OPT_IN_WIZARD already owned by com.google.androi d.apps.searchlite]
then i uninstalled the com.google.android.apps.searchlite] but nothing changed...same error
then i tried to uninstall com.google.android.apps.now.OPT_IN_WIZARD then error occured
Failure [DELETE_FAILED_INTERNAL_ERROR]

Ejecting to bare expo can't install on iOS simulator

I recently had to switch to the bare workflow from the managed workflow. After running expo eject I tested on android, which suffered from an issue with expo-constants not being available, after installing that it worked just fine. I moved on to installing it on the iOS simulator and got an error trying to install. Been trying to debug it but not having any luck. Logs are below:
success Successfully built the app
info Installing "/Users/***/Library/Developer/Xcode/DerivedData/***-dtoeptcccdubmbcvblrjlzhwexaq/Build/Products/Debug-iphonesimulator/***.app"
An error was encountered processing the command (domain=IXUserPresentableErrorDomain, code=1):
This app could not be installed at this time.
Could not install at this time.
Failed to chmod /Users/***/Library/Developer/CoreSimulator/Devices/8666E576-E2C9-4711-B8EB-2A7720C08B84/data/Bundle/Application/F519E6C9-3AFC-49F4-B0E5-9D40C41F54D6/***.app/*** : No such file or directory
Underlying error (domain=MIInstallerErrorDomain, code=4):
Failed to chmod /Users/pedromcunha/Library/Developer/CoreSimulator/Devices/8666E576-E2C9-4711-B8EB-2A7720C08B84/data/Bundle/Application/F519E6C9-3AFC-49F4-B0E5-9D40C41F54D6/***.app/*** : No such file or directory
info Launching "com.***.***"
error Failed to launch the app on simulator, An error was encountered processing the command (domain=FBSOpenApplicationServiceErrorDomain, code=1):
The request to open "com.***.***" failed.
The request was denied by service delegate (SBMainWorkspace) for reason: NotFound ("Application "com.***.***" is unknown to FrontBoard").
Underlying error (domain=FBSOpenApplicationErrorDomain, code=4):
The operation couldn’t be completed. Application "com.***.***" is unknown to FrontBoard.
Application "com.***.***" is unknown to FrontBoard.
I redacted any sensitive info with ***. It says that the build was successful but after looking into the build itself I don't see any executable. Here's the folder contents of the .app package.
Any help is much appreciated.

Getting Building iOS bundle error when trying to build an android app - expo -react-native

I was able to build app using expo build:android previously. However, after upgrading to latest expo version I get following error:
connect ECONNREFUSED 127.0.0.1:19001
Set EXPO_DEBUG=true in your env to view the stack trace.
I also see the following lines in the log:
Publishing to channel 'default'...
Building iOS bundle
I don't added ios to my app.json, I only need to build an android apk. To do that I use expo build:android -t app-bundle
I also removed package-lock.json and node_modules and run npm install, but I get the same error.
I run expo start on another cmd and then run expo build:android -t app-bundle still get same error
Also when I clear expo cache, see the following log:
Restarting Metro Bundler...
Starting Metro Bundler on port 19001.
Couldn't adb reverse: adb.exe: error: Invalid source port: 'undefined'
I had faced same issue myself and found the solution. Expo is looking for localhost:19001 which is not running. Just follow following steps and it should work as expected:
Run expo start no terminal and once it opens up the
browser where you will find this line written Starting Metro
Bundler on port 19001.
Now open another terminal instance and run expo build:android.

why i receive this error (Unable to resolve "expo-av") when trying to run a react-native-gifted-chat project?

This is the error:
Unable to resolve "expo-av" from "node_modules\react-native-gifted-chat\lib\ExpoMessageVideo.js"
Failed building JavaScript bundle.
#Jaime, I had the same issue.
I did the following and the issue is resolved
What did I do?
1.In my computer, opened the command prompt
2.changed the directory to the project directory
3.In the command prompt, ran the following command
expo install expo-av
4.Closed the command prompt
5.Started the project , ran the simulator and could see the app running

ReactNative fails to deploy build to iOS simulator but does deploy it to Android emulator

ReactNative fails to deploy build to iOS simulator but does deploy it to Android emulator
Attached are screenshots showing this on both.
Steps:
Created react native app
react-native init proto
Run app on Android emulator after I started emulator
react-native run-android
this is running fine on Android emulator
Run app on iOS simmulator
react-native run-ios
This produces error as per screenshot
Error
** BUILD FAILED **
The following build commands failed:
CompileC /Users/dinob/reactnativework/proto/ios/build/Build/Intermediates/React.build/Debug-iphonesimulator/React.build/Objects-normal/x86_64/RCTShadowView+Internal.o Views/RCTShadowView+Internal.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
Installing build/Build/Products/Debug-iphonesimulator/proto.app
An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=2):
Failed to install the requested application
An application bundle was not found at the provided path.
Provide a valid path to the desired application bundle.
Print: Entry, ":CFBundleIdentifier", Does Not Exist
Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/proto.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist
Versions
MacBookPro OSX El Capitain
react-native 0.55.3
react-native-cli 2.0.1
npm 5.5.1
node v8.9.1
watchman 4.9.0
Please have a look here for help with troubleshooting
I would suggest you try all the solutions described in that thread to try and fix this issue. Good Luck!