aneebhiba614
aneebhiba614

Reputation: 31

flutter app doesn't run from VsCode, but it runs fine from terminal

iam a newbie to flutter and mobile development. I am facing a problem for the first time.

When I run my code through the terminal:

flutter run 

But when I try to run it through VSCode - either I use with debugging or without debugging - it just hangs at a white screen in my mobile and the debug console shows Built build\app\outputs\flutter-apk\app-debug.apk. and is stuck there for eternity. On the debug consoloe it also shows Running Gradle task 'assembleDebug'... in the bottom left of the debug console and it keeps loading . I am using a physical device for testing my app. I am using Vivo S1.

These are the things I have already tried:

  1. Reinstalling VsCode clean
  2. Clearing my mobile cache
  3. Restarting my mobile/Laptop
  4. The adb device is connected and showing my device.
  5. Checked a different USB port to connect my mobile
  6. flutter clean

It is working fine when i run it using terminal.

Below is the result of flutter run --debug -v:

[ +441 ms] executing: [C:\Users\Aneeb\flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%H
[ +463 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%H
[   +4 ms] f4abaa0735eba4dfd8f33f73363911d63931fe03
[   +4 ms] executing: [C:\Users\Aneeb\flutter/] git tag --points-at f4abaa0735eba4dfd8f33f73363911d63931fe03
[ +211 ms] Exit code 0 from: git tag --points-at f4abaa0735eba4dfd8f33f73363911d63931fe03
[   +3 ms] 2.2.3
[  +45 ms] executing: [C:\Users\Aneeb\flutter/] git rev-parse --abbrev-ref --symbolic @{u}
[ +177 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[   +3 ms] origin/stable
[   +1 ms] executing: [C:\Users\Aneeb\flutter/] git ls-remote --get-url origin
[ +307 ms] Exit code 0 from: git ls-remote --get-url origin
[   +2 ms] https://github.com/flutter/flutter.git
[ +644 ms] executing: [C:\Users\Aneeb\flutter/] git rev-parse --abbrev-ref HEAD
[ +166 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[   +2 ms] stable
[ +685 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.
[  +28 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping update.
[   +2 ms] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[ +387 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe devices -l
[ +244 ms] List of devices attached
                    AEDI7DEQXCGUJJAQ       device product:1907 model:vivo_1907_19 device:1907 transport_id:1
[  +43 ms] C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe -s AEDI7DEQXCGUJJAQ shell getprop
[ +444 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[  +25 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping update.
[   +3 ms] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping update.
[   +4 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping update.
[   +1 ms] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping update.
[   +1 ms] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[   +2 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[ +611 ms] Skipping pub get: version match.
[ +764 ms] Generating C:\Flutter\MyApps\shop_app\android\app\src\main\java\io\flutter\plugins\GeneratedPluginRegistrant.java
[ +322 ms] ro.hardware = mt6768
[   +3 ms] ro.build.characteristics = default
[ +286 ms] Initializing file store
[  +65 ms] Skipping target: gen_localizations
[  +56 ms] complete
[  +40 ms] Launching lib\main.dart on vivo 1907 19 in debug mode...
[  +66 ms] C:\Users\Aneeb\flutter\bin\cache\dart-sdk\bin\dart.exe --disable-dart-dev C:\Users\Aneeb\flutter\bin\cache\artifacts\engine\windows-x64\frontend_server.dart.snapshot
--sdk-root C:\Users\Aneeb\flutter\bin\cache\artifacts\engine\common\flutter_patched_sdk/ --incremental --target=flutter --debugger-module-names --experimental-emit-debug-metadata 
-DFLUTTER_WEB_AUTO_DETECT=true --output-dill C:\Users\Aneeb\AppData\Local\Temp\flutter_tools.87cfdec5\flutter_tool.a1785061\app.dill --packages
C:\Flutter\MyApps\shop_app\.dart_tool\package_config.json -Ddart.vm.profile=false -Ddart.vm.product=false --enable-asserts --track-widget-creation --filesystem-scheme
org-dartlang-root --initialize-from-dill build\3c113a45063dc6628e68a4111abcacad.cache.dill.track.dill --enable-experiment=alternative-invalidation-strategy
[ +102 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\build-tools\31.0.0\aapt dump xmltree C:\Flutter\MyApps\shop_app\build\app\outputs\flutter-apk\app.apk
AndroidManifest.xml
[  +79 ms] Exit code 0 from: C:\Users\Aneeb\AppData\Local\Android\sdk\build-tools\31.0.0\aapt dump xmltree C:\Flutter\MyApps\shop_app\build\app\outputs\flutter-apk\app.apk
AndroidManifest.xml
[   +5 ms] N: android=http://schemas.android.com/apk/res/android
             E: manifest (line=2)
               A: android:versionCode(0x0101021b)=(type 0x10)0x1
               A: android:versionName(0x0101021c)="1.0.0" (Raw: "1.0.0")
               A: android:compileSdkVersion(0x01010572)=(type 0x10)0x1e
               A: android:compileSdkVersionCodename(0x01010573)="11" (Raw: "11")
               A: package="com.example.shop_app" (Raw: "com.example.shop_app")
               A: platformBuildVersionCode=(type 0x10)0x1e
               A: platformBuildVersionName=(type 0x10)0xb
               E: uses-sdk (line=7)
                 A: android:minSdkVersion(0x0101020c)=(type 0x10)0x10
                 A: android:targetSdkVersion(0x01010270)=(type 0x10)0x1e
               E: uses-permission (line=14)
                 A: android:name(0x01010003)="android.permission.INTERNET" (Raw: "android.permission.INTERNET")
               E: application (line=16)
                 A: android:label(0x01010001)="shop_app" (Raw: "shop_app")
                 A: android:icon(0x01010002)=@0x7f080000
                 A: android:debuggable(0x0101000f)=(type 0x12)0xffffffff
                 A: android:appComponentFactory(0x0101057a)="androidx.core.app.CoreComponentFactory" (Raw: "androidx.core.app.CoreComponentFactory")
                 E: activity (line=21)
                   A: android:theme(0x01010000)=@0x7f0a0000
                   A: android:name(0x01010003)="com.example.shop_app.MainActivity" (Raw: "com.example.shop_app.MainActivity")
                   A: android:launchMode(0x0101001d)=(type 0x10)0x1
                   A: android:configChanges(0x0101001f)=(type 0x11)0x40003fb4
                   A: android:windowSoftInputMode(0x0101022b)=(type 0x11)0x10
                   A: android:hardwareAccelerated(0x010102d3)=(type 0x12)0xffffffff
                   E: meta-data (line=35)
                     A: android:name(0x01010003)="io.flutter.embedding.android.NormalTheme" (Raw: "io.flutter.embedding.android.NormalTheme")
                     A: android:resource(0x01010025)=@0x7f0a0001
                   E: meta-data (line=45)
                     A: android:name(0x01010003)="io.flutter.embedding.android.SplashScreenDrawable" (Raw: "io.flutter.embedding.android.SplashScreenDrawable")
                     A: android:resource(0x01010025)=@0x7f040000
                   E: intent-filter (line=49)
                     E: action (line=50)
                       A: android:name(0x01010003)="android.intent.action.MAIN" (Raw: "android.intent.action.MAIN")
                     E: category (line=52)
                       A: android:name(0x01010003)="android.intent.category.LAUNCHER" (Raw: "android.intent.category.LAUNCHER")
                 E: meta-data (line=59)
                   A: android:name(0x01010003)="flutterEmbedding" (Raw: "flutterEmbedding")
                   A: android:value(0x01010024)=(type 0x10)0x2
[  +93 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe -s AEDI7DEQXCGUJJAQ shell -x logcat -v time -t 1
[  +96 ms] <- compile package:shop_app_course/main.dart
[ +371 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe version
[ +530 ms] Android Debug Bridge version 1.0.41
                    Version 31.0.3-7562133
                    Installed as C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe
[  +16 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe start-server
[ +102 ms] Building APK
[ +127 ms] Running Gradle task 'assembleDebug'...
[  +33 ms] Using gradle from C:\Flutter\MyApps\shop_app\android\gradlew.bat.
[  +43 ms] executing: C:\Program Files\Android\Android Studio\jre\bin\java -version
[ +477 ms] Exit code 0 from: C:\Program Files\Android\Android Studio\jre\bin\java -version
[  +27 ms] openjdk version "11.0.8" 2020-07-14
           OpenJDK Runtime Environment (build 11.0.8+10-b944.6842174)
           OpenJDK 64-Bit Server VM (build 11.0.8+10-b944.6842174, mixed mode)
[   +9 ms] executing: [C:\Flutter\MyApps\shop_app\android/] C:\Flutter\MyApps\shop_app\android\gradlew.bat -Pverbose=true -Ptarget-platform=android-arm64
-Ptarget=C:\Flutter\MyApps\shop_app\lib\main.dart -Pdart-defines=RkxVVFRFUl9XRUJfQVVUT19ERVRFQ1Q9dHJ1ZQ== -Pdart-obfuscation=false -Ptrack-widget-creation=true
-Ptree-shake-icons=false -Pfilesystem-scheme=org-dartlang-root assembleDebug
[+6211 ms] > Task :app:compileFlutterBuildDebug
[   +3 ms] [ +141 ms] executing: [C:\Users\Aneeb\flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%H
[  +86 ms] [  +88 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%H
[  +84 ms] [        ] f4abaa0735eba4dfd8f33f73363911d63931fe03
[  +27 ms] [   +2 ms] executing: [C:\Users\Aneeb\flutter/] git tag --points-at f4abaa0735eba4dfd8f33f73363911d63931fe03
[  +66 ms] [  +62 ms] Exit code 0 from: git tag --points-at f4abaa0735eba4dfd8f33f73363911d63931fe03
[   +4 ms] [        ] 2.2.3
[  +25 ms] [  +13 ms] executing: [C:\Users\Aneeb\flutter/] git rev-parse --abbrev-ref --symbolic @{u}
[   +2 ms] [  +90 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[   +1 ms] [        ] origin/stable
[   +3 ms] [        ] executing: [C:\Users\Aneeb\flutter/] git ls-remote --get-url origin
[   +1 ms] [  +41 ms] Exit code 0 from: git ls-remote --get-url origin
[   +2 ms] [        ] https://github.com/flutter/flutter.git
[  +72 ms] [ +135 ms] executing: [C:\Users\Aneeb\flutter/] git rev-parse --abbrev-ref HEAD
[  +22 ms] [  +37 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[  +31 ms] [        ] stable
[   +7 ms] [ +109 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.
[        ] [   +5 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[        ] [ +315 ms] Artifact Instance of 'MaterialFonts' is not required, skipping update.
[   +3 ms] [   +5 ms] Artifact Instance of 'GradleWrapper' is not required, skipping update.
[  +11 ms] [   +7 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[  +44 ms] [        ] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[  +89 ms] [        ] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.
[  +61 ms] [        ] Artifact Instance of 'FlutterSdk' is not required, skipping update.
[ +101 ms] [        ] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[  +66 ms] [        ] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping update.
[  +43 ms] [        ] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping update.
[  +94 ms] [        ] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping update.
[  +86 ms] [        ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping update.
[  +28 ms] [        ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[  +30 ms] [        ] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[   +3 ms] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[  +42 ms] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[  +49 ms] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[   +6 ms] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[   +2 ms] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[   +2 ms] [        ] Artifact Instance of 'FontSubsetArtifacts' is not required, skipping update.
[  +38 ms] [        ] Artifact Instance of 'PubDependencies' is not required, skipping update.
[   +2 ms] [ +158 ms] Initializing file store
[   +2 ms] [  +72 ms] Skipping target: gen_localizations
[  +62 ms] [  +19 ms] kernel_snapshot: Starting due to {}
[  +10 ms] [  +45 ms] C:\Users\Aneeb\flutter\bin\cache\dart-sdk\bin\dart.exe --disable-dart-dev
C:\Users\Aneeb\flutter\bin\cache\artifacts\engine\windows-x64\frontend_server.dart.snapshot --sdk-root
C:\Users\Aneeb\flutter\bin\cache\artifacts\engine\common\flutter_patched_sdk/ --target=flutter --no-print-incremental-dependencies -DFLUTTER_WEB_AUTO_DETECT=true
-Ddart.vm.profile=false -Ddart.vm.product=false --enable-asserts --track-widget-creation --no-link-platform --packages C:\Flutter\MyApps\shop_app\.dart_tool\package_config.json   
--output-dill C:\Flutter\MyApps\shop_app\.dart_tool\flutter_build\1af984f4dfa72c51502439bab9fced1e\app.dill --depfile
C:\Flutter\MyApps\shop_app\.dart_tool\flutter_build\1af984f4dfa72c51502439bab9fced1e\kernel_snapshot.d package:shop_app_course/main.dart
[+27038 ms] [+27763 ms] kernel_snapshot: Complete
[+2995 ms] [+3040 ms] debug_android_application: Starting due to {}
[ +811 ms] [ +855 ms] debug_android_application: Complete
[+3199 ms] [+3173 ms] Persisting file store
[  +96 ms] [  +67 ms] Done persisting file store
[  +95 ms] [  +55 ms] build succeeded.
[  +97 ms] [ +110 ms] "flutter assemble" took 35,667ms.
[ +301 ms] [ +292 ms] ensureAnalyticsSent: 259ms
[   +3 ms] [   +9 ms] Running shutdown hooks
[   +3 ms] [   +1 ms] Shutdown hooks complete
[   +4 ms] [  +20 ms] exiting with code 0
[+1194 ms] > Task :app:packLibsflutterBuildDebug UP-TO-DATE
[   +5 ms] > Task :app:preBuild UP-TO-DATE
[  +11 ms] > Task :app:preDebugBuild UP-TO-DATE
[   +4 ms] > Task :app:compileDebugAidl NO-SOURCE
[   +3 ms] > Task :app:compileDebugRenderscript NO-SOURCE
[   +5 ms] > Task :app:generateDebugBuildConfig UP-TO-DATE
[ +172 ms] > Task :app:checkDebugAarMetadata UP-TO-DATE
[ +145 ms] > Task :app:cleanMergeDebugAssets
[ +109 ms] > Task :app:mergeDebugShaders UP-TO-DATE
[  +70 ms] > Task :app:compileDebugShaders NO-SOURCE
[   +6 ms] > Task :app:generateDebugAssets UP-TO-DATE
[   +7 ms] > Task :app:mergeDebugAssets
[+1449 ms] > Task :app:copyFlutterAssetsDebug
[  +44 ms] > Task :app:generateDebugResValues UP-TO-DATE
[  +16 ms] > Task :app:generateDebugResources UP-TO-DATE
[   +4 ms] > Task :app:mergeDebugResources UP-TO-DATE
[  +51 ms] > Task :app:createDebugCompatibleScreenManifests UP-TO-DATE
[  +27 ms] > Task :app:extractDeepLinksDebug UP-TO-DATE
[   +3 ms] > Task :app:processDebugMainManifest UP-TO-DATE
[  +55 ms] > Task :app:processDebugManifest UP-TO-DATE
[  +45 ms] > Task :app:processDebugManifestForPackage UP-TO-DATE
[ +114 ms] > Task :app:processDebugResources UP-TO-DATE
[ +325 ms] > Task :app:compileDebugKotlin UP-TO-DATE
[ +286 ms] > Task :app:javaPreCompileDebug UP-TO-DATE
[   +6 ms] > Task :app:compileDebugJavaWithJavac UP-TO-DATE
[   +7 ms] > Task :app:compileDebugSources UP-TO-DATE
[   +5 ms] > Task :app:mergeDebugNativeDebugMetadata NO-SOURCE
[   +8 ms] > Task :app:compressDebugAssets UP-TO-DATE
[   +4 ms] > Task :app:processDebugJavaRes NO-SOURCE
[  +10 ms] > Task :app:mergeDebugJavaResource UP-TO-DATE
[   +9 ms] > Task :app:checkDebugDuplicateClasses UP-TO-DATE
[   +7 ms] > Task :app:dexBuilderDebug UP-TO-DATE
[  +24 ms] > Task :app:desugarDebugFileDependencies UP-TO-DATE
[   +5 ms] > Task :app:mergeExtDexDebug UP-TO-DATE
[   +4 ms] > Task :app:mergeDexDebug UP-TO-DATE
[   +5 ms] > Task :app:mergeDebugJniLibFolders UP-TO-DATE
[   +3 ms] > Task :app:mergeDebugNativeLibs UP-TO-DATE
[  +27 ms] > Task :app:stripDebugDebugSymbols UP-TO-DATE
[  +11 ms] > Task :app:validateSigningDebug UP-TO-DATE
[   +5 ms] > Task :app:packageDebug UP-TO-DATE
[ +774 ms] > Task :app:assembleDebug
[  +96 ms] Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
[   +3 ms] Use '--warning-mode all' to show the individual deprecation warnings.
[   +4 ms] See https://docs.gradle.org/6.7/userguide/command_line_interface.html#sec:command_line_warnings
[   +4 ms] BUILD SUCCESSFUL in 46s
[   +6 ms] 32 actionable tasks: 5 executed, 27 up-to-date
[ +792 ms] Running Gradle task 'assembleDebug'... (completed in 48.7s)
[ +179 ms] calculateSha: LocalDirectory: 'C:\Flutter\MyApps\shop_app\build\app\outputs\flutter-apk'/app.apk
[+3418 ms] √  Built build\app\outputs\flutter-apk\app-debug.apk.
[  +22 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\build-tools\31.0.0\aapt dump xmltree C:\Flutter\MyApps\shop_app\build\app\outputs\flutter-apk\app.apk
AndroidManifest.xml
[  +88 ms] Exit code 0 from: C:\Users\Aneeb\AppData\Local\Android\sdk\build-tools\31.0.0\aapt dump xmltree C:\Flutter\MyApps\shop_app\build\app\outputs\flutter-apk\app.apk
AndroidManifest.xml
[   +7 ms] N: android=http://schemas.android.com/apk/res/android
             E: manifest (line=2)
               A: android:versionCode(0x0101021b)=(type 0x10)0x1
               A: android:versionName(0x0101021c)="1.0.0" (Raw: "1.0.0")
               A: android:compileSdkVersion(0x01010572)=(type 0x10)0x1e
               A: android:compileSdkVersionCodename(0x01010573)="11" (Raw: "11")
               A: package="com.example.shop_app" (Raw: "com.example.shop_app")
               A: platformBuildVersionCode=(type 0x10)0x1e
               A: platformBuildVersionName=(type 0x10)0xb
               E: uses-sdk (line=7)
                 A: android:minSdkVersion(0x0101020c)=(type 0x10)0x10
                 A: android:targetSdkVersion(0x01010270)=(type 0x10)0x1e
               E: uses-permission (line=14)
                 A: android:name(0x01010003)="android.permission.INTERNET" (Raw: "android.permission.INTERNET")
               E: application (line=16)
                 A: android:label(0x01010001)="shop_app" (Raw: "shop_app")
                 A: android:icon(0x01010002)=@0x7f080000
                 A: android:debuggable(0x0101000f)=(type 0x12)0xffffffff
                 A: android:appComponentFactory(0x0101057a)="androidx.core.app.CoreComponentFactory" (Raw: "androidx.core.app.CoreComponentFactory")
                 E: activity (line=21)
                   A: android:theme(0x01010000)=@0x7f0a0000
                   A: android:name(0x01010003)="com.example.shop_app.MainActivity" (Raw: "com.example.shop_app.MainActivity")
                   A: android:launchMode(0x0101001d)=(type 0x10)0x1
                   A: android:configChanges(0x0101001f)=(type 0x11)0x40003fb4
                   A: android:windowSoftInputMode(0x0101022b)=(type 0x11)0x10
                   A: android:hardwareAccelerated(0x010102d3)=(type 0x12)0xffffffff
                   E: meta-data (line=35)
                     A: android:name(0x01010003)="io.flutter.embedding.android.NormalTheme" (Raw: "io.flutter.embedding.android.NormalTheme")
                     A: android:resource(0x01010025)=@0x7f0a0001
                   E: meta-data (line=45)
                     A: android:name(0x01010003)="io.flutter.embedding.android.SplashScreenDrawable" (Raw: "io.flutter.embedding.android.SplashScreenDrawable")
                     A: android:resource(0x01010025)=@0x7f040000
                   E: intent-filter (line=49)
                     E: action (line=50)
                       A: android:name(0x01010003)="android.intent.action.MAIN" (Raw: "android.intent.action.MAIN")
                     E: category (line=52)
                       A: android:name(0x01010003)="android.intent.category.LAUNCHER" (Raw: "android.intent.category.LAUNCHER")
                 E: meta-data (line=59)
                   A: android:name(0x01010003)="flutterEmbedding" (Raw: "flutterEmbedding")
                   A: android:value(0x01010024)=(type 0x10)0x2
[  +40 ms] Stopping app 'app.apk' on vivo 1907 19.
[   +3 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe -s AEDI7DEQXCGUJJAQ shell am force-stop com.example.shop_app
[ +260 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe -s AEDI7DEQXCGUJJAQ shell pm list packages com.example.shop_app
[ +183 ms] package:com.example.shop_app
[  +11 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe -s AEDI7DEQXCGUJJAQ shell cat /data/local/tmp/sky.com.example.shop_app.sha1
[ +146 ms] 7a59f4e109ce148beba3995878fb471da3afa32e
[   +8 ms] Latest build already installed.
[   +2 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe -s AEDI7DEQXCGUJJAQ shell -x logcat -v time -t 1
[ +157 ms] executing: C:\Users\Aneeb\AppData\Local\Android\sdk\platform-tools\adb.exe -s AEDI7DEQXCGUJJAQ shell am start -a android.intent.action.RUN -f 0x20000000 --ez
enable-background-compilation true --ez enable-dart-profiling true --ez enable-checked-mode true --ez verify-entry-points true
com.example.shop_app/com.example.shop_app.MainActivity
[ +186 ms] Starting: Intent { act=android.intent.action.RUN flg=0x20000000 cmp=com.example.shop_app/.MainActivity (has extras) }
[   +3 ms] Waiting for observatory port to be available...
[  +30 ms] Error waiting for a debug connection: The log reader stopped unexpectedly
[  +12 ms] Error launching application on vivo 1907 19.
[  +18 ms] "flutter run" took 58,788ms.
[  +29 ms] 
           #0      throwToolExit (package:flutter_tools/src/base/common.dart:10:3)
           #1      RunCommand.runCommand (package:flutter_tools/src/commands/run.dart:663:9)
           <asynchronous suspension>
           #2      FlutterCommand.run.<anonymous closure> (package:flutter_tools/src/runner/flutter_command.dart:1043:27)
           <asynchronous suspension>
           #3      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #4      CommandRunner.runCommand (package:args/command_runner.dart:196:13)
           <asynchronous suspension>
           #5      FlutterCommandRunner.runCommand.<anonymous closure> (package:flutter_tools/src/runner/flutter_command_runner.dart:284:9)
           <asynchronous suspension>
           #6      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #7      FlutterCommandRunner.runCommand (package:flutter_tools/src/runner/flutter_command_runner.dart:232:5)
           <asynchronous suspension>
           #8      run.<anonymous closure>.<anonymous closure> (package:flutter_tools/runner.dart:62:9)
           <asynchronous suspension>
           #9      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #10     main (package:flutter_tools/executable.dart:91:3)
           <asynchronous suspension>


[ +286 ms] ensureAnalyticsSent: 260ms
[   +8 ms] Running shutdown hooks
[   +2 ms] Shutdown hooks complete
[   +3 ms] exiting with code 1

Upvotes: 2

Views: 7391

Answers (1)

Omatt
Omatt

Reputation: 10549

If the device that you're trying to run the app on is connected properly, it should appear in the list of connected devices when flutter devices is run from the terminal. Though since the app runs without issues using flutter run, this issue does seem to be odd. By default, clicking on Run on either VS Code or Android Studio should execute the run config set on the app. It's best to revisit the run config selected on VS Code. If the issue persists, it's best to file this as a bug

Upvotes: 0

Related Questions