admin管理员组文章数量:1401849
I got this issue suddenly as i didn't update or change any code or package
FAILURE: Build completed with 2 failures.
1: Task failed with an exception.
-----------
* Where:
Build file '/Users/amitbahadur/.pub-cache/hosted/pub.dev/geolocator_android-4.6.2/android/build.gradle' line: 29
* What went wrong:
A problem occurred evaluating project ':geolocator_android'.
> Could not get unknown property 'flutter' for extension 'android' of type com.android.build.gradle.LibraryExtension.
* 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: Task failed with an exception.
-----------
* What went wrong:
A problem occurred configuring project ':geolocator_android'.
> Failed to notify project evaluation listener.
> Cannot invoke method substring() on null object
> com.android.builder.errors.EvalIssueException: compileSdkVersion is not specified. Please add it to build.gradle
* 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
BUILD FAILED in 1s
Error: Gradle task assembleDebug failed with exit code 1
i tried downgrading and upgrading the geolocator package and also update the flutter but still not working
I got this issue suddenly as i didn't update or change any code or package
FAILURE: Build completed with 2 failures.
1: Task failed with an exception.
-----------
* Where:
Build file '/Users/amitbahadur/.pub-cache/hosted/pub.dev/geolocator_android-4.6.2/android/build.gradle' line: 29
* What went wrong:
A problem occurred evaluating project ':geolocator_android'.
> Could not get unknown property 'flutter' for extension 'android' of type com.android.build.gradle.LibraryExtension.
* 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: Task failed with an exception.
-----------
* What went wrong:
A problem occurred configuring project ':geolocator_android'.
> Failed to notify project evaluation listener.
> Cannot invoke method substring() on null object
> com.android.builder.errors.EvalIssueException: compileSdkVersion is not specified. Please add it to build.gradle
* 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.
BUILD FAILED in 1s
Error: Gradle task assembleDebug failed with exit code 1
i tried downgrading and upgrading the geolocator package and also update the flutter but still not working
Share Improve this question asked Mar 23 at 2:41 Amit BahadurAmit Bahadur 2893 silver badges9 bronze badges2 Answers
Reset to default 1If you are using Flutter 3.24.4 or familiar, let downgrade to 4.6.1 or override it.
dependency_overrides:
geolocator_android: 4.6.1
Change Flutter versions, try to downgrade.eg from 3.24 >> 3.22 it worked for me.
本文标签: Could not get unknown property 39flutter39 for extension 39android39Stack Overflow
版权声明:本文标题:Could not get unknown property 'flutter' for extension 'android' - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744298710a2599472.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论