I use cirrusci/flutter:stable-web:
FROM cirrusci/flutter:stable-web
RUN flutter create flutter_web_test
RUN cd flutter_web_test
RUN flutter test --platform chrome -v
ENTRYPOINT [ "/bin/bash" ]
And get endless process:
cirrus#eaf974f2ad7b:~/flutter_web_test$ flutter test --platform chrome -v
...
[ +28 ms] executing: [/home/cirrus/sdks/flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%H
[+13418 ms] Starting daemon...
[+1515 ms] About to build [web, test]...
[ +9 ms] Running build...
[ +308 ms] Running build completed, took 167ms
[ +2 ms] Caching finalized dependency graph...
[ +17 ms] Caching finalized dependency graph completed, took 198ms
[ +7 ms] Succeeded after 377ms with 0 outputs (0 actions)
00:00 +0: loading /home/cirrus/flutter_web_test/test/widget_test.dart [ +778 ms] Serving tests at http://localhost:43001/static/index.html?managerUrl=ws%3A%2F%2Flocalhost%3A43001%2F0&debug=false
02:13 +0: loading /home/cirrus/flutter_web_test/test/widget_test.dart
How I can run flutter tests on chrome platform in docker?
Related
I am having an issue in experimenting with flutter integration tests. My goal is to be able to run headless tests for training purposes (a student produces an app, that I will test automatically). As it runs on servers it has to be headless and as quick as possible, so I chose chromedriver (I am not sure this is the best choice though, if you have other ideas please feel free to tell me).
I followed the tutorial here: https://flutter.dev/docs/cookbook/testing/integration/introduction
I created an empty project, filled lib/main.dart, test_driver/app.dart, test_driver/app_test.dart and pubspec.yaml exactly as suggested on the link above.
Then I tried to run this command:
flutter drive --target=test_driver/app.dart
Everything works properly, all tests passed
Then I launched chromedriver with chromedriver --port=4444 and tried to launch the test on chrome as suggested in the tutorial:
flutter drive test_driver/app.dart --browser-name=chrome --release
In this situation, after some time chrome opens and immediately crash ("Application finished"), juste before app_test.dart is launched:
Running "flutter pub get" in test_simple... 657ms
Launching test_driver/app.dart on Chrome in debug mode...
Waiting for connection from debug service on Chrome... 17,1s
This app is linked to the debug service: ws://127.0.0.1:33437/_FLIixzh_w0=/ws
Debug service listening on ws://127.0.0.1:33437/_FLIixzh_w0=/ws
💪 Running with sound null safety 💪
Application finished.
00:00 +0: Counter App (setUpAll)
Then the tests hang here forever until I kill it manually. Adding the "-v" flag does not give more information on why the application itself has finished:
[ +23 ms] Running "flutter pub get" in test_simple... (completed in 828ms)
[ +172 ms] Generating /home/bolgar/StudioProjects/test_simple/android/app/src/main/java/io/flutter/plugins/GeneratedPluginRegistrant.java
[ +90 ms] Launching test_driver/app.dart on Chrome in debug mode...
[ +125 ms] Updating assets
[ +99 ms] Waiting for connection from debug service on Chrome...
[ +102 ms] <- reset
[ +5 ms] /home/bolgar/snap/flutter/common/flutter/bin/cache/dart-sdk/bin/dart --disable-dart-dev /home/bolgar/snap/flutter/common/flutter/bin/cache/artifacts/engine/linux-x64/frontend_server.dart.snapshot
--sdk-root /home/bolgar/snap/flutter/common/flutter/bin/cache/flutter_web_sdk/ --incremental --target=dartdevc --debugger-module-names --experimental-emit-debug-metadata -DFLUTTER_WEB_AUTO_DETECT=true
--output-dill /tmp/flutter_tools.KSIJUI/flutter_tool.EKPQRL/app.dill --libraries-spec file:///home/bolgar/snap/flutter/common/flutter/bin/cache/flutter_web_sdk/libraries.json --packages
/home/bolgar/StudioProjects/test_simple/.dart_tool/package_config.json -Ddart.vm.profile=false -Ddart.vm.product=false --enable-asserts --track-widget-creation --filesystem-root
/home/bolgar/StudioProjects/test_simple/test_driver --filesystem-root /home/bolgar/StudioProjects/test_simple/test --filesystem-root /tmp/flutter_tools.KSIJUI/flutter_tools.XZNNYT --filesystem-scheme
org-dartlang-app --initialize-from-dill build/b1b715402d823b7fd5c2b68d2edcb2ce.cache.dill.track.dill --platform
file:///home/bolgar/snap/flutter/common/flutter/bin/cache/flutter_web_sdk/kernel/flutter_ddc_sdk_sound.dill --sound-null-safety
[ +8 ms] <- compile org-dartlang-app:/web_entrypoint.dart
[+15724 ms] Waiting for connection from debug service on Chrome... (completed in 15,8s)
[ ] Synced 30.4MB.
[ ] <- accept
[ ] Caching compiled dill
[ +73 ms] Using Google Chrome 93.0.4577.63
[ +491 ms] [CHROME]:
[ ] [CHROME]:DevTools listening on ws://127.0.0.1:45213/devtools/browser/359be11c-4ac2-4ec0-b7ff-4fb67b69bf85
[ +169 ms] DwdsInjector: Received request for entrypoint at http://localhost:36257/main_module.bootstrap.js
[ +4 ms] MetadataProvider: Loading debug metadata...
[ +11 ms] MetadataProvider: Loaded debug metadata (sound null safety)
[ +5 ms] DwdsInjector: Injected debugging metadata for entrypoint at http://localhost:36257/main_module.bootstrap.js
[+1576 ms] ChromeProxyService: Initializing expression compiler for main_module.bootstrap.js with sound null safety: true
[ +47 ms] DevHandler: Debug service listening on ws://127.0.0.1:39027/zQL0xCzGkSU=/ws
[ +15 ms] This app is linked to the debug service: ws://127.0.0.1:39027/zQL0xCzGkSU=/ws
[ +4 ms] Debug service listening on ws://127.0.0.1:39027/zQL0xCzGkSU=/ws
[ ] 💪 Running with sound null safety 💪
[ +522 ms] Application finished.
[ +27 ms] DevHandler: Stopped debug service on ws://127.0.0.1:38021
[ +355 ms] executing: /home/bolgar/snap/flutter/common/flutter/bin/cache/dart-sdk/bin/dart /home/bolgar/StudioProjects/test_simple/test_driver/app_test.dart -rexpanded
[+1584 ms] 00:00 +0: Counter App (setUpAll)
[ +180 ms] DwdsInjector: Received request for entrypoint at http://localhost:36257/main_module.bootstrap.js
[ ] MetadataProvider: Loading debug metadata...
[ +6 ms] MetadataProvider: Loaded debug metadata (sound null safety)
[ +2 ms] DwdsInjector: Injected debugging metadata for entrypoint at http://localhost:36257/main_module.bootstrap.js
[+104632 ms] DwdsInjector: Received request for entrypoint at http://localhost:36257/main_module.bootstrap.js
[ ] MetadataProvider: Loading debug metadata...
[ +6 ms] MetadataProvider: Loaded debug metadata (sound null safety)
[ +2 ms] DwdsInjector: Injected debugging metadata for entrypoint at http://localhost:36257/main_module.bootstrap.js
Can anyone help me here on how to debug this situation ? I must admit that I am stuck.
Thanks a lot,
PS: I would also like to output the results of the drive test in JSON format, as you do with flutter test --machine ..., but I can't find a way to do it with flutter drive ..., so if anyone has a clue please tell me, otherwise I will open another post.
I have a huge project built with flutter, I left the project for a couple of days, Now when I try to run the app I face this error:
FAILURE: Build failed with an exception.
* What went wrong:
Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'.
> Could not resolve all dependencies for configuration ':app:debugCompileClasspath'.
> Problems reading data from Binary store in C:\Users\mrabi\AppData\Local\Temp\gradle7134895285543263727.bin offset 373739 exists? true
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 44s
Exception: Gradle task assembleDebug failed with exit code 1
I tried to flutter clean,
flutter pub cache repair,
even removing the flutter version and reinstall it again. And did not work.
Any solution except creating a new project, because I have a lot of implementation.
my Flutter version is 1.22.6
sdk: ">=2.2.2 <3.0.0"
flutter run --verbose:
[ +81 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%H
[ +1 ms] 9b2d32b605630f28625709ebd9d78ab3016b2bf6
[ +1 ms] executing: [C:\Users\mrabi\fvm\default/] git tag --points-at HEAD
[ +82 ms] Exit code 0 from: git tag --points-at HEAD
[ ] 1.22.6
[ +9 ms] executing: [C:\Users\mrabi\fvm\default/] git rev-parse --abbrev-ref --symbolic #{u}
[ +55 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic #{u}
[ ] origin/stable
[ ] executing: [C:\Users\mrabi\fvm\default/] git ls-remote --get-url origin
[ +50 ms] Exit code 0 from: git ls-remote --get-url origin
[ ] https://github.com/flutter/flutter.git
[ +85 ms] executing: [C:\Users\mrabi\fvm\default/] git rev-parse --abbrev-ref HEAD
[ +52 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[ ] stable
[ +85 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.
[ +4 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.
[ +27 ms] executing: C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe devices -l
[ +54 ms] List of devices attached
5200e3d5f0466523 device product:j6ltecis model:SM_J600F device:j6lte transport_id:1
[ +9 ms] C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe -s 5200e3d5f0466523 shell getprop
[ +132 ms] Artifact Instance of 'AndroidMavenArtifacts' is not required, skipping update.
[ +6 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[ +1 ms] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.
[ +3 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.
[ +1 ms] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[ +1 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[ +158 ms] Found plugin connectivity at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\connectivity-0.4.9+5\
[ +9 ms] Found plugin connectivity_for_web at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\connectivity_for_web-0.3.1+4\
[ +7 ms] Found plugin connectivity_macos at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\connectivity_macos-0.1.0+7\
[ +8 ms] Found plugin device_info at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\device_info-1.0.0\
[ +17 ms] Found plugin firebase_analytics at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_analytics-6.3.0\
[ +6 ms] Found plugin firebase_analytics_web at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_analytics_web-0.1.1\
[ +4 ms] Found plugin firebase_core at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_core-0.5.3\
[ +5 ms] Found plugin firebase_core_web at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_core_web-0.2.1+1\
[ +3 ms] Found plugin firebase_messaging at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_messaging-6.0.16\
[ +9 ms] Found plugin flutter_device_locale at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_device_locale-0.4.0\
[ +2 ms] Found plugin flutter_image_compress at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_image_compress-0.7.0\
[ +3 ms] Found plugin flutter_local_notifications at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_local_notifications-1.5.0+1\
[ +6 ms] Found plugin flutter_plugin_android_lifecycle at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_plugin_android_lifecycle-1.0.11\
[ +7 ms] Found plugin flutter_uploader at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_uploader-1.2.1\
[ +3 ms] Found plugin geolocator at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\geolocator-6.2.1\
[ +3 ms] Found plugin geolocator_web at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\geolocator_web-1.0.1\
[ +3 ms] Found plugin get_version at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\get_version-0.2.2\
[ +4 ms] Found plugin google_maps_flutter at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\google_maps_flutter-0.5.33\
[ +5 ms] Found plugin image_picker at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\image_picker-0.6.7+22\
[ +10 ms] Found plugin location at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\location-3.2.4\
[ +2 ms] Found plugin location_web at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\location_web-1.0.1\
[ +6 ms] Found plugin package_info at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\package_info-0.4.3+4\
[ +7 ms] Found plugin path_provider at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\path_provider-1.6.28\
[ +2 ms] Found plugin path_provider_linux at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\path_provider_linux-0.0.1+2\
[ +2 ms] Found plugin path_provider_macos at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\path_provider_macos-0.0.4+8\
[ +3 ms] Found plugin path_provider_windows at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\path_provider_windows-0.0.4+3\
[ +5 ms] Found plugin permission_handler at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-5.1.0+2\
[ +11 ms] Found plugin shared_preferences at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences-0.5.12+4\
[ +3 ms] Found plugin shared_preferences_linux at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences_linux-0.0.2+4\
[ +3 ms] Found plugin shared_preferences_macos at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences_macos-0.0.1+11\
[ +3 ms] Found plugin shared_preferences_web at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences_web-0.1.2+7\
[ +2 ms] Found plugin shared_preferences_windows at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences_windows-0.0.2+3\
[ +3 ms] Found plugin sms_autofill at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\sms_autofill-1.3.1\
[ +8 ms] Found plugin store_redirect at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\store_redirect-1.0.2\
[ +10 ms] Found plugin url_launcher at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher-5.7.10\
[ +22 ms] Found plugin url_launcher_linux at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher_linux-0.0.1+4\
[ +4 ms] Found plugin url_launcher_macos at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher_macos-0.0.1+9\
[ +3 ms] Found plugin url_launcher_web at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher_web-0.1.5+3\
[ +2 ms] Found plugin url_launcher_windows at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher_windows-0.0.1+3\
[ +123 ms] Found plugin connectivity at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\connectivity-0.4.9+5\
[ +2 ms] Found plugin connectivity_for_web at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\connectivity_for_web-0.3.1+4\
[ +2 ms] Found plugin connectivity_macos at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\connectivity_macos-0.1.0+7\
[ +6 ms] Found plugin device_info at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\device_info-1.0.0\
[ +15 ms] Found plugin firebase_analytics at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_analytics-6.3.0\
[ +6 ms] Found plugin firebase_analytics_web at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_analytics_web-0.1.1\
[ +2 ms] Found plugin firebase_core at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_core-0.5.3\
[ +3 ms] Found plugin firebase_core_web at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_core_web-0.2.1+1\
[ +2 ms] Found plugin firebase_messaging at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_messaging-6.0.16\
[ +8 ms] Found plugin flutter_device_locale at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_device_locale-0.4.0\
[ +2 ms] Found plugin flutter_image_compress at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_image_compress-0.7.0\
[ +3 ms] Found plugin flutter_local_notifications at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_local_notifications-1.5.0+1\
[ +4 ms] Found plugin flutter_plugin_android_lifecycle at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_plugin_android_lifecycle-1.0.11\
[ +5 ms] Found plugin flutter_uploader at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flutter_uploader-1.2.1\
[ +3 ms] Found plugin geolocator at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\geolocator-6.2.1\
[ +2 ms] Found plugin geolocator_web at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\geolocator_web-1.0.1\
[ +1 ms] Found plugin get_version at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\get_version-0.2.2\
[ +2 ms] Found plugin google_maps_flutter at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\google_maps_flutter-0.5.33\
[ +9 ms] Found plugin image_picker at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\image_picker-0.6.7+22\
[ +5 ms] Found plugin location at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\location-3.2.4\
[ +2 ms] Found plugin location_web at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\location_web-1.0.1\
[ +7 ms] Found plugin package_info at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\package_info-0.4.3+4\
[ +3 ms] Found plugin path_provider at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\path_provider-1.6.28\
[ +2 ms] Found plugin path_provider_linux at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\path_provider_linux-0.0.1+2\
[ +2 ms] Found plugin path_provider_macos at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\path_provider_macos-0.0.4+8\
[ +3 ms] Found plugin path_provider_windows at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\path_provider_windows-0.0.4+3\
[ +5 ms] Found plugin permission_handler at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-5.1.0+2\
[ +10 ms] Found plugin shared_preferences at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences-0.5.12+4\
[ +4 ms] Found plugin shared_preferences_linux at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences_linux-0.0.2+4\
[ +5 ms] Found plugin shared_preferences_macos at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences_macos-0.0.1+11\
[ +4 ms] Found plugin shared_preferences_web at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences_web-0.1.2+7\
[ +1 ms] Found plugin shared_preferences_windows at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\shared_preferences_windows-0.0.2+3\
[ +4 ms] Found plugin sms_autofill at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\sms_autofill-1.3.1\
[ +4 ms] Found plugin store_redirect at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\store_redirect-1.0.2\
[ +7 ms] Found plugin url_launcher at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher-5.7.10\
[ +2 ms] Found plugin url_launcher_linux at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher_linux-0.0.1+4\
[ +2 ms] Found plugin url_launcher_macos at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher_macos-0.0.1+9\
[ +3 ms] Found plugin url_launcher_web at C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher_web-0.1.5+3\
[ +1 ms] Found plugin url_launcher_windows at
C:\Users\mrabi\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\url_launcher_windows-0.0.1+3\
[ +35 ms] Generating C:\a
projects\develop-v1-pure\waddini\android\app\src\main\java\io\flutter\plugins\GeneratedPluginRegistrant.java
[ +31 ms] ro.hardware = samsungexynos7870
[ +51 ms] Starting incremental build...
[ +3 ms] Initializing file store
[ +14 ms] Skipping target: gen_localizations
[ +6 ms] complete
[ +5 ms] Launching lib\main.dart on SM J600F in debug mode...
[ +8 ms] C:\Users\mrabi\fvm\default\bin\cache\dart-sdk\bin\dart.exe --disable-dart-dev
C:\Users\mrabi\fvm\default\bin\cache\artifacts\engine\windows-x64\frontend_server.dart.snapshot --sdk-root
C:\Users\mrabi\fvm\default\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
C:\Users\mrabi\AppData\Local\Temp\flutter_tools.cb8bd1c6\flutter_tool.2dcffc35\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
[ +21 ms] executing: C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe -s 5200e3d5f0466523 shell -x logcat -v time -t
1
[ +185 ms] Exit code 0 from: C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe -s 5200e3d5f0466523 shell -x logcat -v
time -t 1
[ +1 ms] --------- beginning of main
07-07 16:39:04.349 D/BoundBrokerSvc(13990): onUnbind: Intent { act=com.google.android.gms.measurement.START
pkg=com.google.android.gms }
[ +2 ms] executing: C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe -s 5200e3d5f0466523 shell -x logcat -v time -t
1
[ +188 ms] Exit code 0 from: C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe -s 5200e3d5f0466523 shell -x logcat -v
time -t 1
[ +2 ms] --------- beginning of main
07-07 16:39:05.202 D/bauth_FPBAuthService( 3064): FPBAuthService, 11288
[ +24 ms] <- compile package:waddini/main.dart
[ +27 ms] executing: C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe version
[ +49 ms] Android Debug Bridge version 1.0.41
Version 31.0.2-7242960
Installed as C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe
[ +3 ms] executing: C:\Users\mrabi\AppData\Local\Android\Sdk\platform-tools\adb.exe start-server
[ +48 ms] Building APK
[ +27 ms] Running Gradle task 'assembleDebug'...
[ +4 ms] gradle.properties already sets `android.enableR8`
[ +6 ms] Using gradle from C:\a projects\develop-v1-pure\waddini\android\gradlew.bat.
[ +2 ms] C:\a projects\develop-v1-pure\waddini\android\gradlew.bat mode: 33279 rwxrwxrwx.
[ +21 ms] executing: C:\Program Files\Android\Android Studio\jre\bin\java -version
[ +140 ms] Exit code 0 from: C:\Program Files\Android\Android Studio\jre\bin\java -version
[ ] 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)
[ +4 ms] executing: [C:\a projects\develop-v1-pure\waddini\android/] C:\a projects\develop-v1-pure\waddini\android\gradlew.bat
-Pverbose=true -Ptarget-platform=android-arm -Ptarget=C:\a projects\develop-v1-pure\waddini\lib\main.dart
-Ptrack-widget-creation=true -Pfilesystem-scheme=org-dartlang-root assembleDebug
[+55447 ms] FAILURE: Build failed with an exception.
[ +3 ms] * What went wrong:
[ +1 ms] Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'.
[ +1 ms] > Could not resolve all dependencies for configuration ':app:debugCompileClasspath'.
[ +1 ms] > Problems reading data from Binary store in C:\Users\mrabi\AppData\Local\Temp\gradle12309172077266440599.bin offset
373739 exists? true
[ +1 ms] * Try:
[ ] Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with
--scan to get full insights.
[ +2 ms] * Get more help at https://help.gradle.org
[ +2 ms] BUILD FAILED in 55s
[ +572 ms] Running Gradle task 'assembleDebug'... (completed in 56.2s)
[ +7 ms] Exception: Gradle task assembleDebug failed with exit code 1
[ +3 ms] "flutter run" took 57,921ms.
[ +6 ms]
#0 throwToolExit (package:flutter_tools/src/base/common.dart:14:3)
#1 RunCommand.runCommand (package:flutter_tools/src/commands/run.dart:607:7)
<asynchronous suspension>
#2 FlutterCommand.verifyThenRunCommand (package:flutter_tools/src/runner/flutter_command.dart:977:18)
#3 _rootRunUnary (dart:async/zone.dart:1198:47)
#4 _CustomZone.runUnary (dart:async/zone.dart:1100:19)
#5 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
#6 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
#7 Future._propagateToListeners (dart:async/future_impl.dart:725:32)
#8 Future._completeWithValue (dart:async/future_impl.dart:529:5)
#9 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:40:15)
#10 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:311:13)
#11 RunCommand.usageValues (package:flutter_tools/src/commands/run.dart)
#12 _rootRunUnary (dart:async/zone.dart:1198:47)
#13 _CustomZone.runUnary (dart:async/zone.dart:1100:19)
#14 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
#15 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
#16 Future._propagateToListeners (dart:async/future_impl.dart:725:32)
#17 Future._completeWithValue (dart:async/future_impl.dart:529:5)
#18 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:40:15)
#19 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:311:13)
#20 AndroidDevice.isLocalEmulator (package:flutter_tools/src/android/android_device.dart)
#21 _rootRunUnary (dart:async/zone.dart:1198:47)
#22 _CustomZone.runUnary (dart:async/zone.dart:1100:19)
#23 _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
#24 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
#25 Future._propagateToListeners (dart:async/future_impl.dart:725:32)
#26 Future._completeWithValue (dart:async/future_impl.dart:529:5)
#27 Future._asyncCompleteWithValue.<anonymous closure> (dart:async/future_impl.dart:567:7)
#28 _rootRun (dart:async/zone.dart:1190:13)
#29 _CustomZone.run (dart:async/zone.dart:1093:19)
#30 _CustomZone.runGuarded (dart:async/zone.dart:997:7)
#31 _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1037:23)
#32 _microtaskLoop (dart:async/schedule_microtask.dart:41:21)
#33 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)
#34 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:118:13)
#35 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:169:5)
[ +267 ms] ensureAnalyticsSent: 257ms
[ +2 ms] Running shutdown hooks
[ +1 ms] Shutdown hook priority 4
[ +3 ms] Shutdown hooks complete
[ +3 ms] exiting with code 1```
I have the latest flutter & dart. I create a basic app and then use the getting started code from the moor website: https://moor.simonbinder.eu/docs/getting-started/
When I execute the build runner it runs but exits with no error message in the moor build but no moor_test.g.dart file is created.
Here is the verbose output from build runner:
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
Try the new cross-platform PowerShell https://aka.ms/pscore6
PS C:\src\flutterExamples\moor_test> flutter packages pub run build_runner build --verbose
[ +72 ms] executing: [C:\src\flutter\flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%H
[ +73 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%H
[ ] 40e3489254b2d0ffedf840bd9233e5e6d06d09dd
[ ] executing: [C:\src\flutter\flutter/] git tag --points-at 40e3489254b2d0ffedf840bd9233e5e6d06d09dd
[ +86 ms] Exit code 0 from: git tag --points-at 40e3489254b2d0ffedf840bd9233e5e6d06d09dd
[ +1 ms] executing: [C:\src\flutter\flutter/] git describe --match *.*.* --long --tags 40e3489254b2d0ffedf840bd9233e5e6d06d09dd
[ +140 ms] Exit code 0 from: git describe --match *.*.* --long --tags 40e3489254b2d0ffedf840bd9233e5e6d06d09dd
[ +2 ms] 2.1.0-12.0.pre-86-g40e3489254
[ +42 ms] executing: [C:\src\flutter\flutter/] git rev-parse --abbrev-ref --symbolic #{u}
[ +50 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic #{u}
[ ] origin/master
[ ] executing: [C:\src\flutter\flutter/] git ls-remote --get-url origin
[ +48 ms] Exit code 0 from: git ls-remote --get-url origin
[ ] https://github.com/flutter/flutter.git
[ +77 ms] executing: [C:\src\flutter\flutter/] git rev-parse --abbrev-ref HEAD
[ +61 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[ ] master
[ +81 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required, skipping update.
[ +1 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.
[ +3 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[ +1 ms] 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.
[ +48 ms] Artifact Instance of 'MaterialFonts' is not required, skipping update.
[ ] Artifact Instance of 'GradleWrapper' 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.
[ ] Artifact Instance of 'PubDependencies' is not required, skipping update.
[ +27 ms] Using C:\src\flutter\flutter\.pub-cache for the pub cache.
[ +1 ms] executing: C:\src\flutter\flutter\bin\cache\dart-sdk\bin\pub.bat run build_runner build --verbose
[INFO] Entrypoint:Generating build script...
[INFO] Entrypoint:Generating build script completed, took 321ms
[INFO] Bootstrap:Creating build script snapshot......
[FINE] Bootstrap:stdout: Info: Compiling without sound null safety
[INFO] Bootstrap:Creating build script snapshot... completed, took 11.2s
[INFO] Bootstrap:There was output on stdout while compiling the build script snapshot, run with `--verbose` to see it (you will need to run a `clean` first to re-snapshot).
[FINE] Bootstrap:Core package locations file does not exist
[INFO] BuildDefinition:Initializing inputs
[INFO] BuildDefinition:Building new asset graph...
[INFO] BuildDefinition:Building new asset graph completed, took 962ms
[INFO] BuildDefinition:Checking for unexpected pre-existing outputs....
[INFO] BuildDefinition:Checking for unexpected pre-existing outputs. completed, took 1ms
[INFO] Build:Running build...
[WARNING] moor_generator:moor_generator on lib/data/moor_test.dart:
Your current `analyzer` version may not fully support your current SDK version.
Please try upgrading to the latest `analyzer` by running `flutter packages upgrade`.
Analyzer language version: 2.12.0
SDK language version: 2.13.0
If you are getting this message and have the latest analyzer please file
an issue at https://github.com/dart-lang/sdk/issues/new with the title
"No published analyzer available for language version 2.13.0".
Please search the issue tracker first and thumbs up and/or subscribe to
existing issues if present to avoid duplicates.
[INFO] build_resolvers:Generating SDK summary...
[INFO] Heartbeat:3.1s elapsed, 0/3 actions completed.
[INFO] build_resolvers:Generating SDK summary completed, took 3.0s
[FINE] moor_generator:moor_generator on lib/data/moor_test.dart:Running MoorGenerator - 1 of 2
[FINE] moor_generator:moor_generator on lib/data/moor_test.dart:Running DaoGenerator - 2 of 2
[INFO] Heartbeat:5.1s elapsed, 0/3 actions completed.
[INFO] Heartbeat:10.4s elapsed, 1/3 actions completed.
[FINE] moor_generator:moor_generator on lib/main.dart:Running MoorGenerator - 1 of 2
[FINE] moor_generator:moor_generator on test/widget_test.dart:Running MoorGenerator - 1 of 2
[FINE] moor_generator:moor_generator on lib/main.dart:Running DaoGenerator - 2 of 2
[FINE] moor_generator:moor_generator on test/widget_test.dart:Running DaoGenerator - 2 of 2
[INFO] Build:Running build completed, took 11.3s
[INFO] Build:Caching finalized dependency graph...
[INFO] Build:Caching finalized dependency graph completed, took 30ms
[INFO] Build:Succeeded after 11.3s with 0 outputs (6 actions)
[+36878 ms] "flutter pub" took 36,987ms.
[ +117 ms] ensureAnalyticsSent: 112ms
[ +2 ms] Running shutdown hooks
[ ] Shutdown hooks complete
[ +1 ms] exiting with code 0
Here is my pubspec.yaml file:
name: moor_test
description: A new Flutter project.
publish_to: 'none' # Remove this line if you wish to publish to pub.dev
version: 1.0.0+1
environment:
sdk: ">=2.7.0 <3.0.0"
dependencies:
flutter:
sdk: flutter
moor: # use the latest version
sqlite3_flutter_libs: # Also use the latest version.
path_provider:
path:
cupertino_icons: ^1.0.2
dev_dependencies:
flutter_test:
sdk: flutter
moor_generator: # use the latest version
build_runner:
flutter:
uses-material-design: true
And my moor class:
import 'package:moor/moor.dart';
part 'moor_test.g.dart';
class Todos extends Table {
IntColumn get id => integer().autoIncrement()();
TextColumn get title => text().withLength(min: 6, max: 32)();
TextColumn get content => text().named('body')();
IntColumn get category => integer().nullable()();
}
#DataClassName("Category")
class Categories extends Table {
IntColumn get id => integer().autoIncrement()();
TextColumn get description => text()();
}
#UseMoor(tables: [Todos, Categories])
class MyDatabase {
}
Does anyone know what I am doing wrong or can prompt me where to look to debug this?
My app failed to run after i plugged in shared_preferences: ^0.5.7+3 library,and the same problem with sqflite plugin.
Please see the error log
[+895892 ms] FAILURE: Build failed with an exception.
[ +4 ms] * What went wrong:
[ ] Execution failed for task
':shared_preferences:extractDebugAnnotations'.
[ ] > Could not resolve all files for configuration
':shared_preferences:lintClassPath'.
[ ] > Could not download intellij-core.jar
(com.android.tools.external.com-intellij:intellij-core:26.5.0)
[ ] > Could not get resource
'https://dl.google.com/dl/android/maven2/com/android/tools/external/com-
intellij/intellij-core/26.5.0/intellij-core-26.5.0.jar'.
[ ] > Tag mismatch!
[ ] > Could not download groovy-all.jar
(org.codehaus.groovy:groovy-all:2.4.15)
[ ] > Could not get resource
'https://jcenter.bintray.com/org/codehaus/groovy/groovy-
all/2.4.15/groovy-all-2.4.15.jar'.
[ +5 ms] > Read timed out
[ +1 ms] * Try:
[ +1 ms] Run with --stacktrace option to get the stack trace. Run with
--info or --debug option to get more log output. Run with --scan to get
full insights.
[ ] * Get more help at https://help.gradle.org
[ +3 ms] BUILD FAILED in 14m 54s
[{"event":"app.progress","params":{"appId":"f780a728-3b3b-464c-a369-
5f2bb360c086","id":"0","progressId":null,"finished":true}}]
[+2903 ms] Exception: Gradle task assembleDebug failed with exit code 1
According to this: https://github.com/flutter/flutter/issues/48264
You should try:
flutter pub cache repair
cd <YOUR APP FOLDER>
flutter clean
If this doesn't work try deleting the ~/.gradle content
Also try Invalidate Caches/Restart.... This can be found in the 'File' section on the top left of android studio.
I have cloned the https://github.com/flutter/flutter_web repository and I'm trying to run the hello_world program in the examples directory.
I have done everything instructed in the GitHub page.
Additionally, I installed the dart SDK using apt because i was getting another error, "webdev dart: not found", this was fixed.
Now I'm getting the following error when running "webdev serve",
"The pubspec.yaml file has changed since the pubspec.lock file was generated, please run "pub get" again."
I ran "flutter pub get" and "flutter pub upgrade", this did not fix it.
I expected this to start a web server on port 8080.The output of
flutter pub get -v
is
[ +18 ms] executing: [/home/meth/Documents/development/flutter/] git log -n 1 --pretty=format:%H
[ +21 ms] Exit code 0 from: git log -n 1 --pretty=format:%H
[ ] 7a4c33425ddd78c54aba07d86f3f9a4a0051769b
[ ] executing: [/home/meth/Documents/development/flutter/] git describe --match v*.*.* --first-parent --long --tags
[ +7 ms] Exit code 0 from: git describe --match v*.*.* --first-parent --long --tags
[ ] v1.5.4-hotfix.2-0-g7a4c33425
[ +8 ms] executing: [/home/meth/Documents/development/flutter/] git rev-parse --abbrev-ref --symbolic #{u}
[ +5 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic #{u}
[ ] origin/stable
[ ] executing: [/home/meth/Documents/development/flutter/] git ls-remote --get-url origin
[ +7 ms] Exit code 0 from: git ls-remote --get-url origin
[ ] https://github.com/flutter/flutter.git
[ +36 ms] executing: [/home/meth/Documents/development/flutter/] git rev-parse --abbrev-ref HEAD
[ +8 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[ ] stable
[ +21 ms] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.
[ +3 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 'FuchsiaCacheArtifacts' is not required, skipping update.
[ +16 ms] Running "flutter packages get" in hello_world...
[ +3 ms] Using /home/meth/Documents/development/flutter/.pub-cache for the pub cache.
[ +1 ms] executing: [/home/meth/Documents/work/flutter_web/examples/hello_world/] /home/meth/Documents/development/flutter/bin/cache/dart-sdk/bin/pub --verbosity=warning --verbose get
--no-precompile
[ +440 ms] ! flutter_web 0.0.0 from path ../../packages/flutter_web
[ +1 ms] ! flutter_web_ui 0.0.0 from path ../../packages/flutter_web_ui
[ +49 ms] Running "flutter packages get" in hello_world... (completed in 0.5s)
[ +166 ms] "flutter get" took 717ms.
[ ] "flutter get" took 717ms.
and the output of
webdev serve -v
is
webdev could not run for this project.
The pubspec.yaml file has changed since the pubspec.lock file was generated, please run "pub get" again.
My Current directory
drwxrwxr-x 3 meth meth 4096 Jun 9 07:38 android
drwxrwxr-x 4 meth meth 4096 Jun 9 07:38 ios
drwxrwxr-x 2 meth meth 4096 Jun 9 07:41 lib
-rw-rw-r-- 1 meth meth 10592 Jun 9 12:00 pubspec.lock
-rw-rw-r-- 1 meth meth 400 Jun 9 07:55 pubspec.yaml
drwxrwxr-x 2 meth meth 4096 Jun 9 07:40 web
There is a solution to this. Found it here,
https://github.com/flutter/flutter/issues/32313
use
flutter packages pub global run webdev build
instead of webdev build
and
flutter packages pub global run webdev serve
instead of webdev serve