'Flutter iOS App not launching after removing USB

So i'm testing a flutter app that builds and installs successfully on an iOS simulator as well as a physical devices. However, when building and installing the app with xcode via the USB, it successfully installs and launches but when the USB is disconnected from my mac and i try to run the already installed device on the iPhone, it shows only the launch / splash screen and fades and closes.

Is there something i'm doing wrong that causes this to happen? As the app works fine when connected with the USB and it's being run.



Solution 1:[1]

In iOS, debug build doesn't work without USB. To use the app without USB trying making a release build using flutter run --release

Solution 2:[2]

If the build is in debug mode - it won't open.

if you want to open application after disconnecting, try profile / release mode

flutter run --profile

or

flutter run --release

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Alind Sharma
Solution 2 Bharath