Could not determine the dependencies of task ':wakelock_plus:generateReleaseLintModel'.
When I try to build release apk i got the following error:
Could not determine the dependencies of task ':wakelock_plus:generateReleaseLintModel'.
> Could not resolve all dependencies for configuration ':wakelock_plus:releaseUnitTestRuntimeClasspath'.
> Could not create task ':wakelock_plus:testDebugUnitTest'.
> this and base files have different roots: D:\Flutter\app\my_app\build\wakelock_plus and C:\Users\user\AppData\Local\Pub\Cache\hosted\pub.dev\wakelock_plus-1.2.5\android.
Are you adding this package to a new project or have you recently updated it to a new version?
For me this is occuring when adding this package to my project
I used flutter_widget_from_html_core: ^0.14.12 package instead of flutter_widget_from_html: ^0.15.0 to fixed this error.
Can you share Flutter version and your pubspec.yaml?
Anyone I have same issue
This issue was resolved for me by copying the project to the C drive and then running the following commands in the command line:
flutter clean
flutter pub get
flutter build apk
https://aarktechub.com/blogs/fix-flutter-dependencies-error-chewie-wakelock-plus
@maotou316 amazing, thanks for sharing. I came across other errors due to same reason: project location. Works fine when it's on C drive and does not if it's on other drives. Not sure if any type of Symlinking would work as workaround. I have not tried but will when get chance
FAILURE: Build failed with an exception.
- What went wrong: Could not determine the dependencies of task ':wakelock_plus:generateReleaseLintModel'.
Could not resolve all dependencies for configuration ':wakelock_plus:releaseUnitTestRuntimeClasspath'. Could not create task ':wakelock_plus:testDebugUnitTest'. > this and base files have different roots: D:\1. Group Project\flutex_admin\build\wakelock_plus and C:\Users\AppData\Local\Pub\Cache\hosted\pub.dev\wakelock_plus-1.2.10\android.
- 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 3s Running Gradle task 'assembleRelease'... 4.5s Gradle task assembleRelease failed with exit code 1
I can't fix it Pls help me