Skip to content

Getting unexpected error while build an app in android #1892

@rxvivek

Description

@rxvivek

Flutter 3.24.0

Launching lib/ecat_prod.dart on Pixel 4a in debug mode...
Running Gradle task 'assembleProdDebug'...

FAILURE: Build completed with 3 failures.

1: Task failed with an exception.

  • Where:
    Build file '/Users/vivek.mavani/.pub-cache/hosted/pub.dev/file_picker-10.3.3/android/build.gradle' line: 30

  • What went wrong:
    A problem occurred evaluating project ':file_picker'.

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.
Get more help at https://help.gradle.org.
==============================================================================

2: Task failed with an exception.

  • What went wrong:
    A problem occurred configuring project ':file_picker'.

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.org.
==============================================================================

3: Task failed with an exception.

  • What went wrong:
    Failed to query the value of property 'buildFlowServiceProperty'.

Could not isolate value org.jetbrains.kotlin.gradle.plugin.statistics.BuildFlowService$Parameters_Decorated@749f85d8 of type BuildFlowService.Parameters
A problem occurred configuring project ':file_picker'.
> 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.org.
==============================================================================

BUILD FAILED in 1s
Error: Gradle task assembleProdDebug failed with exit code 1

Metadata

Metadata

Assignees

No one assigned

    Labels

    new issueAn issue that hasn't yet been seen from the maintainer

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions