Почему не собирается под Android?

При сборке падает со следующей ошибкой:
FAILURE: Build completed with 2 failures.

1: Task failed with an exception.
-----------
* Where:
Build file '/Users/justjew/.pub-cache/hosted/pub.dev/sqflite-2.2.8/android/build.gradle' line: 33

* What went wrong:
A problem occurred evaluating project ':sqflite'.
> Could not find method namespace() for arguments [com.tekartik.sqfite] on 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.
-----------
* Where:
Script '/Users/justjew/flutter/packages/flutter_tools/gradle/flutter.gradle' line: 463

* What went wrong:
A problem occurred configuring project ':sqflite'.
> Failed to notify project evaluation listener.
   > Cannot invoke method substring() on null object
   > 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 918ms
Running Gradle task 'bundleRelease'...                           1 588ms
Gradle task bundleRelease failed with exit code 1


пакет sqflite тянется какой-то из зависимостей, напрямую в pubspec я его не добавлял

flutter clean, очистка кешей и прочее не помогает.
увеличение версии gradle тоже не помогло.
compile/target/minSdkVersion тоже никак не влияет.
обновление andoid studio тоже не помогло.

flutter doctor:
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.7.12, on macOS 13.2.1 22D68 darwin-arm64, locale ru-RU)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 14.3)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2022.2)
[✓] VS Code (version 1.75.1)
[✓] Connected device (3 available)
[✓] HTTP Host Availability

• No issues found!
  • Вопрос задан
  • 187 просмотров
Пригласить эксперта
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Войти через центр авторизации
Похожие вопросы