Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Problem with running IOS simulator for my flutter app

I'm trying to run my flutter app on the IOS simulator and its not working. So tried on the most basic flutter app (create my_app and then tried to run it) and nothing seem to work! Everything seems to work fine when I run it from the terminal until the linking and signing phase and that where I get the error, how can I fix it?

This is the error I get:

Unable to install
/Users/MyUserName/Desktop/my_app/build/ios/iphonesimulator/Runner.app on
82562E3A-E7BD-4FE0-9BF9-8BB9C7AD5F15. This is sometimes caused by a malformed
plist file:
ProcessException: Process exited abnormally:
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 transfer ownership of path
/Users/MyUserName/Library/Developer/CoreSimulator/Devices/82562E3A-E7BD-4FE0-9BF9-8B
B9C7AD5F15/data/Containers/Shared/SystemGroup/systemgroup.com.apple.installcoord
inationd/Library/InstallCoordination/PromiseStaging/98CD703F-760F-4AAE-B991-BC2E
82D37D17/my_app.app to installd
Underlying error (domain=MIInstallerErrorDomain, code=103):
    Failed to transfer ownership of path
    /Users/MyUserName/Library/Developer/CoreSimulator/Devices/82562E3A-E7BD-4FE0-9BF9-8
    BB9C7AD5F15/data/Containers/Shared/SystemGroup/systemgroup.com.apple.installcoo
    rdinationd/Library/InstallCoordination/PromiseStaging/98CD703F-760F-4AAE-B991-B
    C2E82D37D17/my_app.app to installd
  Command: /usr/bin/xcrun simctl install 82562E3A-E7BD-4FE0-9BF9-8BB9C7AD5F15
  /Users/MyUserName/Desktop/my_app/build/ios/iphonesimulator/Runner.app
Error launching application on iPhone 11 Pro Max.

Edit: I updated my MacOS, Deeleted and reinstalled Xcode, I even tried to run the most simple swift app and I get always this same error, it looks like the build was successful but it unable to install. I still get this same error, what can I do?

like image 694
user3240459 Avatar asked May 24 '20 13:05

user3240459


People also ask

How do you run apps on Flutter simulator?

Choose Device: Open your VS Code and from the bottom right corner of your home screen click on the Flutter Device option. Select Device: When you click on the Flutter Device icon, list of available devices will open up in the command palette. Select the emulator you just created.

Can Flutter apps run on iOS?

Flutter is designed to support mobile apps that run on both Android and iOS, as well as interactive apps that you want to run on your web pages or on the desktop.


Video Answer


2 Answers

This occurred when I opened the Simulator first and then updated XCode -- even without running the app until after XCode updated completely.

What worked for me:

  1. Close Simulator completely (from the dock, right-click -> "Quit")
  2. Close XCode (if applicable)
  3. Run flutter clean
  4. Re-open Simulator
  5. Re-open XCode and let it compile
  6. Run the app again

If it still does not work, try resetting the device at "Device" -> "Erase All Content and Settings..." from the Simulator menu.

like image 131
J. Saw Avatar answered Sep 20 '22 23:09

J. Saw


I had the same issue a couple of days ago

What I did - and what fixed the problem - was to reset the simulator (Device -> Erase All Content and Settings), and then run $ flutter clean

You should now be able to run your app again

like image 28
Mads Balslev Avatar answered Sep 16 '22 23:09

Mads Balslev