flutter run taking hours

For some reason, flutter run is taking hours to even run (?) on Linux. I have no problem running it on Windows with the same phone, cable, computer and which port the cable is inserted. Below are the logs before I had to go to sleep because it just took hours and didn’t even know if I could run it.

I have tried:

  • Reinstalling flutter,
  • Doing the chain of commands:
flutter channel stable
flutter upgrade --force
flutter pub cache repair
flutter clean
  • ./gradlew clean build on gradle version 6.8.2 and keeps saying build failed finished with non-zero exit value 1 after ~23 mins in Task :app:compleFlutterBuildDebug,
  • Running it on Android Studio, trying Invalidate caches and restart

Steps to Reproduce

  1. Run flutter create bug.
  2. Run cd bug.
  3. Run flutter run -v.

Expected results: Flutter application running on phone
Actual results: ‘flutter run’ taking an unexpectedly long time

Logs

flutter run -v

[  +87 ms] executing: [/opt/flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%%H
[  +23 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%%H
[        ] 9b2d32b605630f28625709ebd9d78ab3016b2bf6
[        ] executing: [/opt/flutter/] git tag --points-at HEAD
[   +8 ms] Exit code 0 from: git tag --points-at HEAD
[        ] 1.22.6
[   +6 ms] executing: [/opt/flutter/] git rev-parse --abbrev-ref --symbolic @{u}
[   +3 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[        ] origin/stable
[        ] executing: [/opt/flutter/] git ls-remote --get-url origin
[   +3 ms] Exit code 0 from: git ls-remote --get-url origin
[        ] https://github.com/flutter/flutter.git
[  +28 ms] executing: [/opt/flutter/] git rev-parse --abbrev-ref HEAD
[   +3 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[        ] stable
[  +31 ms] Artifact Instance of 'AndroidMavenArtifacts' is not required, skipping update.
[        ] 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.
[   +1 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.
[  +11 ms] executing: /opt/android-sdk/platform-tools/adb devices -l
[  +29 ms] List of devices attached
           ce11160b3002a83705     device usb:1-1 product:hero2ltexx model:SM_G935F device:hero2lte transport_id:44
[   +6 ms] /opt/android-sdk/platform-tools/adb -s ce11160b3002a83705 shell getprop
[  +73 ms] Artifact Instance of 'AndroidMavenArtifacts' is not required, skipping update.
[   +5 ms] 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.
[   +2 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.
[  +67 ms] Running "flutter pub get" in habitualise...
[   +3 ms] executing: [/mnt/d/University/IndividualProject/Application/habitualise/] /opt/flutter/bin/cache/dart-sdk/bin/pub --verbose get
--no-precompile
[  +73 ms] FINE: Pub 2.10.5
[  +44 ms] MSG : Resolving dependencies...
[  +47 ms] SLVR: fact: habitualise is 1.0.0+1
[   +6 ms] SLVR: derived: habitualise
[  +21 ms] SLVR: fact: habitualise depends on flutter any from sdk
[        ] SLVR: fact: habitualise depends on cupertino_icons ^1.0.0
[        ] SLVR: fact: habitualise depends on flutter_test any from sdk
[        ] SLVR:   selecting habitualise
[        ] SLVR:   derived: flutter_test any from sdk
[        ] SLVR:   derived: cupertino_icons ^1.0.0
[        ] SLVR:   derived: flutter any from sdk
[  +14 ms] SLVR:   fact: flutter_test 0.0.0 from dk depends on flutter any from sdk
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on test_api 0.2.19-nullsafety.2
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on path 1.8.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on fake_async 1.2.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on clock 1.1.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on stack_trace 1.10.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on vector_math 2.1.0-nullsafety.3
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on async 2.5.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on boolean_selector 2.1.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on characters 1.1.0-nullsafety.3
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on charcode 1.2.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on collection 1.15.0-nullsafety.3
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on matcher 0.12.10-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on meta 1.3.0-nullsafety.3
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on source_span 1.8.0-nullsafety.2
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on stream_channel 2.1.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on string_scanner 1.1.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on term_glyph 1.2.0-nullsafety.1
[        ] SLVR:   fact: flutter_test 0.0.0 from sdk depends on typed_data 1.3.0-nullsafety.3
[        ] SLVR:     selecting flutter_test 0.0.0 from sdk
[        ] SLVR:     derived: typed_data 1.3.0-nullsafety.3
[        ] SLVR:     derived: term_glyph 1.2.0-nullsafety.1
[        ] SLVR:     derived: string_scanner 1.1.0-nullsafety.1
[        ] SLVR:     derived: stream_channel 2.1.0-nullsafety.1
[        ] SLVR:     derived: source_span 1.8.0-nullsafety.2
[        ] SLVR:     derived: meta 1.3.0-nullsafety.3
[        ] SLVR:     derived: matcher 0.12.10-nullsafety.1
[        ] SLVR:     derived: collection 1.15.0-nullsafety.3
[        ] SLVR:     derived: charcode 1.2.0-nullsafety.1
[        ] SLVR:     derived: characters 1.1.0-nullsafety.3
[        ] SLVR:     derived: boolean_selector 2.1.0-nullsafety.1
[        ] SLVR:     derived: async 2.5.0-nullsafety.1
[        ] SLVR:     derived: vector_math 2.1.0-nullsafety.3
[        ] SLVR:     derived: stack_trace 1.10.0-nullsafety.1
[        ] SLVR:     derived: clock 1.1.0-nullsafety.1
[        ] SLVR:     derived: fake_async 1.2.0-nullsafety.1
[        ] SLVR:     derived: path 1.8.0-nullsafety.1
[        ] SLVR:     derived: test_api 0.2.19-nullsafety.2
[  +17 ms] SLVR:       selecting cupertino_icons 1.0.0
[   +7 ms] SLVR:       fact: flutter 0.0.0 from sdk depends on characters 1.1.0-nullsafety.3
[        ] SLVR:       fact: flutter 0.0.0 from sdk depends on collection 1.15.0-nullsafety.3
[        ] SLVR:       fact: flutter 0.0.0 from sdk depends on meta 1.3.0-nullsafety.3
[        ] SLVR:       fact: flutter 0.0.0 from sdk depends on typed_data 1.3.0-nullsafety.3
[        ] SLVR:       fact: flutter 0.0.0 from sdk depends on vector_math 2.1.0-nullsafety.3
[        ] SLVR:       fact: flutter 0.0.0 from sdk depends on sky_engine any from sdk
[        ] SLVR:         selecting flutter 0.0.0 from sdk
[        ] SLVR:         derived: sky_engine any from sdk
[   +6 ms] SLVR:         fact: typed_data 1.3.0-nullsafety.3 depends on collection >=1.15.0-nullsafety <1.15.0
[        ] SLVR:           selecting typed_data 1.3.0-nullsafety.3
[   +4 ms] SLVR:             selecting term_glyph 1.2.0-nullsafety.1
[   +3 ms] SLVR:             fact: string_scanner 1.1.0-nullsafety.1 depends on charcode >=1.2.0-nullsafety <1.2.0
[        ] SLVR:             fact: string_scanner 1.1.0-nullsafety.1 depends on source_span >=1.8.0-nullsafety <1.8.0
[        ] SLVR:               selecting string_scanner 1.1.0-nullsafety.1
[   +3 ms] SLVR:               fact: stream_channel 2.1.0-nullsafety.1 depends on async >=2.5.0-nullsafety <2.5.0
[        ] SLVR:                 selecting stream_channel 2.1.0-nullsafety.1
[   +3 ms] SLVR:                 fact: source_span 1.8.0-nullsafety.2 depends on charcode >=1.2.0-nullsafety <1.2.0
[        ] SLVR:                 fact: source_span 1.8.0-nullsafety.2 depends on collection >=1.15.0-nullsafety <1.15.0
[        ] SLVR:                 fact: source_span 1.8.0-nullsafety.2 depends on path >=1.8.0-nullsafety <1.8.0
[        ] SLVR:                 fact: source_span 1.8.0-nullsafety.2 depends on term_glyph >=1.2.0-nullsafety <1.2.0
[        ] SLVR:                   selecting source_span 1.8.0-nullsafety.2
[   +4 ms] SLVR:                     selecting meta 1.3.0-nullsafety.3
[   +3 ms] SLVR:                     fact: matcher 0.12.10-nullsafety.1 depends on stack_trace >=1.10.0-nullsafety <1.10.0
[        ] SLVR:                       selecting matcher 0.12.10-nullsafety.1
[   +3 ms] SLVR:                         selecting collection 1.15.0-nullsafety.3
[   +3 ms] SLVR:                           selecting charcode 1.2.0-nullsafety.1
[   +3 ms] SLVR:                             selecting characters 1.1.0-nullsafety.3
[   +3 ms] SLVR:                             fact: boolean_selector 2.1.0-nullsafety.1 depends on source_span >=1.8.0-nullsafety <1.8.0
[        ] SLVR:                             fact: boolean_selector 2.1.0-nullsafety.1 depends on string_scanner >=1.1.0-nullsafety <1.1.0
[        ] SLVR:                               selecting boolean_selector 2.1.0-nullsafety.1
[   +2 ms] SLVR:                               fact: async 2.5.0-nullsafety.1 depends on collection >=1.15.0-nullsafety <1.15.0
[        ] SLVR:                                 selecting async 2.5.0-nullsafety.1
[   +2 ms] SLVR:                                   selecting vector_math 2.1.0-nullsafety.3
[   +3 ms] SLVR:                                   fact: stack_trace 1.10.0-nullsafety.1 depends on path >=1.8.0-nullsafety <1.8.0
[        ] SLVR:                                     selecting stack_trace 1.10.0-nullsafety.1
[   +2 ms] SLVR:                                       selecting clock 1.1.0-nullsafety.1
[   +2 ms] SLVR:                                       fact: fake_async 1.2.0-nullsafety.1 depends on clock >=1.1.0-nullsafety <1.1.0
[        ] SLVR:                                       fact: fake_async 1.2.0-nullsafety.1 depends on collection >=1.15.0-nullsafety <1.15.0
[        ] SLVR:                                         selecting fake_async 1.2.0-nullsafety.1
[   +2 ms] SLVR:                                           selecting path 1.8.0-nullsafety.1
[   +3 ms] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on async >=2.5.0-nullsafety <2.5.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on boolean_selector >=2.1.0-nullsafety <2.1.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on collection >=1.15.0-nullsafety <1.15.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on meta >=1.3.0-nullsafety <1.3.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on path >=1.8.0-nullsafety <1.8.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on source_span >=1.8.0-nullsafety <1.8.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on stack_trace >=1.10.0-nullsafety <1.10.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on stream_channel >=2.1.0-nullsafety <2.1.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on string_scanner >=1.1.0-nullsafety <1.1.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on term_glyph >=1.2.0-nullsafety <1.2.0
[        ] SLVR:                                           fact: test_api 0.2.19-nullsafety.2 depends on matcher >=0.12.10-nullsafety <0.12.10
[        ] SLVR:                                             selecting test_api 0.2.19-nullsafety.2
[        ] SLVR:                                               selecting sky_engine 0.0.99 from sdk
[   +4 ms] SLVR: Version solving took 0:00:00.154169 seconds.
[        ]     | Tried 1 solutions.
[        ] FINE: Resolving dependencies finished (0.198s).
[  +30 ms] IO  : Writing 3680 characters to text file ./pubspec.lock.
[        ] FINE: Contents:
[        ]     | # Generated by pub
[        ]     | # See https://dart.dev/tools/pub/glossary#lockfile
[        ]     | packages:
[        ]     |   async:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: async
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "2.5.0-nullsafety.1"
[        ]     |   boolean_selector:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: boolean_selector
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "2.1.0-nullsafety.1"
[        ]     |   characters:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: characters
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.1.0-nullsafety.3"
[        ]     |   charcode:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: charcode
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.2.0-nullsafety.1"
[        ]     |   clock:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: clock
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.1.0-nullsafety.1"
[        ]     |   collection:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: collection
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.15.0-nullsafety.3"
[        ]     |   cupertino_icons:
[        ]     |     dependency: "direct main"
[        ]     |     description:
[        ]     |       name: cupertino_icons
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.0.0"
[        ]     |   fake_async:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: fake_async
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.2.0-nullsafety.1"
[        ]     |   flutter:
[        ]     |     dependency: "direct main"
[        ]     |     description: flutter
[        ]     |     source: sdk
[        ]     |     version: "0.0.0"
[        ]     |   flutter_test:
[        ]     |     dependency: "direct dev"
[        ]     |     description: flutter
[        ]     |     source: sdk
[        ]     |     version: "0.0.0"
[        ]     |   matcher:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: matcher
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "0.12.10-nullsafety.1"
[        ]     |   meta:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: meta
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.3.0-nullsafety.3"
[        ]     |   path:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: path
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.8.0-nullsafety.1"
[        ]     |   sky_engine:
[        ]     |     dependency: transitive
[        ]     |     description: flutter
[        ]     |     source: sdk
[        ]     |     version: "0.0.99"
[        ]     |   source_span:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: source_span
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.8.0-nullsafety.2"
[        ]     |   stack_trace:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: stack_trace
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.10.0-nullsafety.1"
[        ]     |   stream_channel:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: stream_channel
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "2.1.0-nullsafety.1"
[        ]     |   string_scanner:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: string_scanner
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.1.0-nullsafety.1"
[        ]     |   term_glyph:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: term_glyph
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.2.0-nullsafety.1"
[        ]     |   test_api:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: test_api
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "0.2.19-nullsafety.2"
[        ]     |   typed_data:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: typed_data
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "1.3.0-nullsafety.3"
[        ]     |   vector_math:
[        ]     |     dependency: transitive
[        ]     |     description:
[        ]     |       name: vector_math
[        ]     |       url: "https://pub.dartlang.org"
[        ]     |     source: hosted
[        ]     |     version: "2.1.0-nullsafety.3"
[        ]     | sdks:
[        ]     |   dart: ">=2.10.0-110 <2.11.0"
[ +122 ms] MSG : Got dependencies!
[  +27 ms] IO  : Writing 2211 characters to text file ./.packages.
[        ] FINE: Contents:
[        ]     | # Generated by pub on 2021-02-20 00:54:06.897512.
[        ]     | async:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/async-2.5.0-nullsafety.1/lib/
[        ]     | boolean_selector:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/boolean_selector-2.1.0-nullsafety.1/lib/
[        ]     | characters:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/characters-1.1.0-nullsafety.3/lib/
[        ]     | charcode:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/charcode-1.2.0-nullsafety.1/lib/
[        ]     | clock:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/clock-1.1.0-nullsafety.1/lib/
[        ]     | collection:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/collection-1.15.0-nullsafety.3/lib/
[        ]     | cupertino_icons:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/cupertino_icons-1.0.0/lib/
[        ]     | fake_async:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/fake_async-1.2.0-nullsafety.1/lib/
[        ]     | flutter:file:///opt/flutter/packages/flutter/lib/
[        ]     | flutter_test:file:///opt/flutter/packages/flutter_test/lib/
[        ]     | matcher:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/matcher-0.12.10-nullsafety.1/lib/
[        ]     | meta:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/meta-1.3.0-nullsafety.3/lib/
[        ]     | path:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/path-1.8.0-nullsafety.1/lib/
[        ]     | sky_engine:file:///opt/flutter/bin/cache/pkg/sky_engine/lib/
[        ]     | source_span:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/source_span-1.8.0-nullsafety.2/lib/
[        ]     | stack_trace:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/stack_trace-1.10.0-nullsafety.1/lib/
[        ]     | stream_channel:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/stream_channel-2.1.0-nullsafety.1/lib/
[        ]     | string_scanner:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/string_scanner-1.1.0-nullsafety.1/lib/
[        ]     | term_glyph:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/term_glyph-1.2.0-nullsafety.1/lib/
[        ]     | test_api:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/test_api-0.2.19-nullsafety.2/lib/
[        ]     | typed_data:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/typed_data-1.3.0-nullsafety.3/lib/
[        ]     | vector_math:file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/vector_math-2.1.0-nullsafety.3/lib/
[        ]     | habitualise:lib/
[ +258 ms] IO  : Writing 4722 characters to text file ./.dart_tool/package_config.json.
[        ] FINE: Contents:
[        ]     | {
[        ]     |   "configVersion": 2,
[        ]     |   "packages": [
[        ]     |     {
[        ]     |       "name": "async",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/async-2.5.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "boolean_selector",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/boolean_selector-2.1.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "characters",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/characters-1.1.0-nullsafety.3",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "charcode",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/charcode-1.2.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "clock",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/clock-1.1.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "collection",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/collection-1.15.0-nullsafety.3",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "cupertino_icons",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/cupertino_icons-1.0.0",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.0"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "fake_async",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/fake_async-1.2.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "flutter",
[        ]     |       "rootUri": "file:///opt/flutter/packages/flutter",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "flutter_test",
[        ]     |       "rootUri": "file:///opt/flutter/packages/flutter_test",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.2"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "matcher",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/matcher-0.12.10-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "meta",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/meta-1.3.0-nullsafety.3",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "path",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/path-1.8.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "sky_engine",
[        ]     |       "rootUri": "file:///opt/flutter/bin/cache/pkg/sky_engine",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "1.11"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "source_span",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/source_span-1.8.0-nullsafety.2",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "stack_trace",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/stack_trace-1.10.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "stream_channel",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/stream_channel-2.1.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "string_scanner",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/string_scanner-1.1.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "term_glyph",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/term_glyph-1.2.0-nullsafety.1",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "test_api",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/test_api-0.2.19-nullsafety.2",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "typed_data",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/typed_data-1.3.0-nullsafety.3",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "vector_math",
[        ]     |       "rootUri": "file:///home/jrmallorca/.pub-cache/hosted/pub.dartlang.org/vector_math-2.1.0-nullsafety.3",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.10"
[        ]     |     },
[        ]     |     {
[        ]     |       "name": "habitualise",
[        ]     |       "rootUri": "../",
[        ]     |       "packageUri": "lib/",
[        ]     |       "languageVersion": "2.7"
[        ]     |     }
[        ]     |   ],
[        ]     |   "generated": "2021-02-20T00:54:07.172667Z",
[        ]     |   "generator": "pub",
[        ]     |   "generatorVersion": "2.10.5"
[        ]     | }
[ +312 ms] Running "flutter pub get" in habitualise... (completed in 1.1s)
[ +552 ms] Generating
/mnt/d/University/IndividualProject/Application/habitualise/android/app/src/main/java/io/flutter/plugins/GeneratedPluginRegistrant.java
[ +294 ms] ro.hardware = samsungexynos8890
[  +47 ms] Starting incremental build...
[ +171 ms] Initializing file store
[  +31 ms] Skipping target: gen_localizations
[ +227 ms] complete
[  +13 ms] Launching lib/main.dart on SM G935F in debug mode...
[  +15 ms] /opt/flutter/bin/cache/dart-sdk/bin/dart --disable-dart-dev
/opt/flutter/bin/cache/artifacts/engine/linux-x64/frontend_server.dart.snapshot --sdk-root
/opt/flutter/bin/cache/artifacts/engine/common/flutter_patched_sdk/ --incremental --target=flutter --debugger-module-names
--experimental-emit-debug-metadata -Ddart.developer.causal_async_stacks=true --output-dill /tmp/flutter_tools.HMUJHB/flutter_tool.ICRGQE/app.dill
--packages .packages -Ddart.vm.profile=false -Ddart.vm.product=false
--bytecode-options=source-positions,local-var-info,debugger-stops,instance-field-initializers,keep-unreachable-code,avoid-closure-call-instructions
--enable-asserts --track-widget-creation --filesystem-scheme org-dartlang-root --initialize-from-dill build/cache.dill.track.dill
[  +16 ms] executing: /opt/android-sdk/platform-tools/adb -s ce11160b3002a83705 shell -x logcat -v time -t 1
[ +128 ms] Exit code 0 from: /opt/android-sdk/platform-tools/adb -s ce11160b3002a83705 shell -x logcat -v time -t 1
[        ] --------- beginning of main
           02-20 00:54:06.341 E/adbd    (16873): service_to_fd: shell:logcat -v time -t 1
[   +3 ms] executing: /opt/android-sdk/platform-tools/adb -s ce11160b3002a83705 shell -x logcat -v time -t 1
[ +112 ms] Exit code 0 from: /opt/android-sdk/platform-tools/adb -s ce11160b3002a83705 shell -x logcat -v time -t 1
[        ] --------- beginning of main
           02-20 00:54:06.479 E/adbd    (16873): service_to_fd: shell:logcat -v time -t 1
[  +36 ms] <- compile package:habitualise/main.dart
[  +13 ms] executing: /opt/android-sdk/platform-tools/adb version
[  +12 ms] Android Debug Bridge version 1.0.41
           Version 30.0.5-6877874
           Installed as /opt/android-sdk/platform-tools/adb
[   +1 ms] executing: /opt/android-sdk/platform-tools/adb start-server
[   +5 ms] Building APK
[  +10 ms] Running Gradle task 'assembleDebug'...
[   +1 ms] gradle.properties already sets `android.enableR8`
[   +2 ms] Using gradle from /mnt/d/University/IndividualProject/Application/habitualise/android/gradlew.
[        ] /mnt/d/University/IndividualProject/Application/habitualise/android/gradlew mode: 33261 rwxr-xr-x.
[   +3 ms] executing: [/mnt/d/University/IndividualProject/Application/habitualise/android/]
/mnt/d/University/IndividualProject/Application/habitualise/android/gradlew -Pverbose=true -Ptarget-platform=android-arm64
-Ptarget=/mnt/d/University/IndividualProject/Application/habitualise/lib/main.dart -Ptrack-widget-creation=true
-Pfilesystem-scheme=org-dartlang-root assembleDebug
[+3873 ms] > Task :app:compileFlutterBuildDebug
[        ] [  +89 ms] executing: [/opt/flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%%H
[        ] [  +23 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%%H
[        ] [        ] 9b2d32b605630f28625709ebd9d78ab3016b2bf6
[        ] [        ] executing: [/opt/flutter/] git tag --points-at HEAD
[        ] [   +8 ms] Exit code 0 from: git tag --points-at HEAD
[        ] [        ] 1.22.6
[        ] [   +5 ms] executing: [/opt/flutter/] git rev-parse --abbrev-ref --symbolic @{u}
[        ] [   +2 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[        ] [        ] origin/stable
[        ] [        ] executing: [/opt/flutter/] git ls-remote --get-url origin
[        ] [   +2 ms] Exit code 0 from: git ls-remote --get-url origin
[        ] [        ] https://github.com/flutter/flutter.git
[        ] [  +26 ms] executing: [/opt/flutter/] git rev-parse --abbrev-ref HEAD
[        ] [   +2 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[        ] [        ] stable
[        ] [  +25 ms] Artifact Instance of 'AndroidMavenArtifacts' is not required, skipping update.
[        ] [        ] 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.
[        ] [   +1 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.
[        ] [   +6 ms] Artifact Instance of 'MaterialFonts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'GradleWrapper' is not required, skipping update.
[        ] [        ] Artifact Instance of 'AndroidMavenArtifacts' is not required, skipping update.
[        ] [        ] 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.
[        ] [        ] Artifact Instance of 'FlutterSdk' is not required, skipping update.
[        ] [        ] 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.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[        ] [        ] Artifact Instance of 'FontSubsetArtifacts' is not required, skipping update.
[        ] [ +205 ms] Initializing file store
[        ] [  +12 ms] Skipping target: gen_localizations
[  +85 ms] [ +216 ms] kernel_snapshot: Starting due to {}
[ +100 ms] [ +112 ms] /opt/flutter/bin/cache/dart-sdk/bin/dart --disable-dart-dev
/opt/flutter/bin/cache/artifacts/engine/linux-x64/frontend_server.dart.snapshot --sdk-root
/opt/flutter/bin/cache/artifacts/engine/common/flutter_patched_sdk/ --target=flutter -Ddart.developer.causal_async_stacks=true
-Ddart.vm.profile=false -Ddart.vm.product=false
--bytecode-options=source-positions,local-var-info,debugger-stops,instance-field-initializers,keep-unreachable-code,avoid-closure-call-instructions
--enable-asserts --track-widget-creation --no-link-platform --packages /mnt/d/University/IndividualProject/Application/habitualise/.packages
--output-dill /mnt/d/University/IndividualProject/Application/habitualise/.dart_tool/flutter_build/5e18e7372aaba70cbdf36b47cd95f0e1/app.dill
--depfile /mnt/d/University/IndividualProject/Application/habitualise/.dart_tool/flutter_build/5e18e7372aaba70cbdf36b47cd95f0e1/kernel_snapshot.d
package:habitualise/main.dart
[+1143299 ms] [+1143310 ms] kernel_snapshot: Complete
[+2300 ms] [+2295 ms] debug_android_application: Starting due to {}
[+1158299 ms] [+1158276 ms] debug_android_application: Complete
[+1900 ms] [+1939 ms] Persisting file store
[+2599 ms] [+2598 ms] Done persisting file store
[ +300 ms] [ +340 ms] build succeeded.
[+1199 ms] [+1211 ms] "flutter assemble" took 2,310,519ms.
[        ] [   +3 ms] ensureAnalyticsSent: 0ms
[        ] [   +1 ms] Running shutdown hooks
[        ] [        ] Shutdown hooks complete
[        ] [        ] exiting with code 0
[+9800 ms] > Task :app:packLibsflutterBuildDebug
[        ] > Task :app:preBuild UP-TO-DATE
[        ] > Task :app:preDebugBuild UP-TO-DATE
[ +998 ms] > Task :app:compileDebugAidl NO-SOURCE
[  +99 ms] > Task :app:compileDebugRenderscript NO-SOURCE
[ +600 ms] > Task :app:checkDebugManifest
[+4000 ms] > Task :app:generateDebugBuildConfig
[ +800 ms] > Task :app:cleanMergeDebugAssets UP-TO-DATE
[+2099 ms] > Task :app:mergeDebugShaders
[+2699 ms] > Task :app:compileDebugShaders
[        ] > Task :app:generateDebugAssets
[+18199 ms] > Task :app:mergeDebugAssets
[+30000 ms] > Task :app:copyFlutterAssetsDebug
[+1140800 ms] > Task :app:mainApkListPersistenceDebug
[+3199 ms] > Task :app:generateDebugResValues
[        ] > Task :app:generateDebugResources
[+29999 ms] > Task :app:mergeDebugResources
[+45299 ms] > Task :app:createDebugCompatibleScreenManifests
[+30000 ms] > Task :app:processDebugManifest
[+34099 ms] > Task :app:processDebugJavaRes NO-SOURCE
[+30000 ms] > Task :app:checkDebugDuplicateClasses
[+89999 ms] > Task :app:desugarDebugFileDependencies
[+144499 ms] > Task :app:processDebugResources
[+53599 ms] > Task :app:compileDebugKotlin
[+33900 ms] > Task :app:validateSigningDebug
[+2999 ms] > Task :app:signingConfigWriterDebug
[+3000 ms] > Task :app:mergeDebugJniLibFolders
[+20200 ms] > Task :app:javaPreCompileDebug
[+9799 ms] > Task :app:mergeDebugNativeLibs
[+39199 ms] > Task :app:mergeExtDexDebug
[+95800 ms] > Task :app:compileDebugJavaWithJavacs

flutter doctor -v

[✓] Flutter (Channel stable, 1.22.6, on Linux, locale en_GB.UTF-8)
    • Flutter version 1.22.6 at /opt/flutter
    • Framework revision 9b2d32b605 (4 weeks ago), 2021-01-22 14:36:39
      -0800
    • Engine revision 2f0af37152
    • Dart version 2.10.5

[✓] Android toolchain - develop for Android devices (Android SDK version
    30.0.3)
    • Android SDK at /opt/android-sdk
    • Platform android-30, build-tools 30.0.3
    • ANDROID_HOME = /opt/android-sdk
    • ANDROID_SDK_ROOT = /opt/android-sdk
    • Java binary at: /usr/lib/jvm/java-8-openjdk/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_282-b08)
    • All Android licenses accepted.

[!] Android Studio (not installed)
    • Android Studio not found; download from
      https://developer.android.com/studio/index.html
      (or visit
      https://flutter.dev/docs/get-started/install/linux#android-setup
      for detailed instructions).

[✓] Connected device (1 available)
    • SM G935F (mobile) • ce11160b3002a83705 • android-arm64 • Android
      8.0.0 (API 26)

1 possible answer(s) on “flutter run taking hours

  1. Hello again,
    I think I found the issue: I did flutter create in my HDD drive with NTFS file system. When I did it in the Linux drive it was very fast.

    Thanks for the help!