gdelataillade / alarm

A Flutter plugin to easily manage alarms on iOS and Android
https://pub.dev/packages/alarm
MIT License
132 stars 86 forks source link

Please solve for latest AGM and namespace #86

Closed gadgetsteach closed 11 months ago

gadgetsteach commented 1 year ago

Alarm plugin version ex: 0.2.9 (please update to the latest version before submitting the issue)

Describe the bug ...

To Reproduce Steps to reproduce the behavior:

  1. ...

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Device info Provide device info (Manufacturer, OS version, ...) Ex: iPhone 13 Pro, iOS 16.2, ...

Additional context Add any other context about the problem here.

Launching lib\main.dart on HRY AL00Ta in debug mode... main.dart:1

FAILURE: Build completed with 2 failures.

1: Task failed with an exception.

Failed to query the value of property 'buildFlowServiceProperty'.

Could not isolate value org.jetbrains.kotlin.gradle.plugin.statistics.BuildFlowService$Parameters_Decorated@633ddc4c of type BuildFlowService.Parameters A problem occurred configuring project ':alarm'. Could not create an instance of type com.android.build.api.variant.impl.LibraryVariantBuilderImpl. Namespace not specified. Specify a namespace in the module's build file. See https://d.android.com/r/tools/upgrade-assistant/set-namespace for information about setting the namespace.

       If you've specified the package attribute in the source AndroidManifest.xml, you can use the AGP Upgrade Assistant to migrate to the namespace value in the build file. Refer to https://d.android.com/r/tools/upgrade-assistant/agp-upgrade-assistant for general information about using the AGP Upgrade Assistant.

BUILD FAILED in 1s Exception: Gradle task assembleDebug failed with exit code 1

My flutter setup:

[√] Flutter (Channel stable, 3.13.2, on Microsoft Windows [Version 10.0.22631.2265], locale en-IN) • Flutter version 3.13.2 on channel stable at D:\flutter • Upstream repository https://github.com/flutter/flutter.git • Framework revision ff5b5b5fa6 (2 weeks ago), 2023-08-24 08:12:28 -0500 • Engine revision b20183e040 • Dart version 3.1.0 • DevTools version 2.25.0

[√] Windows Version (Installed version of Windows is version 10 or higher)

[√] Android toolchain - develop for Android devices (Android SDK version 34.0.0) • Android SDK at C:\Users\zerobg i121\AppData\Local\Android\sdk • Platform android-UpsideDownCakePrivacySandbox, build-tools 34.0.0 • Java binary at: D:\android\jbr\bin\java • Java version OpenJDK Runtime Environment (build 17.0.6+0-b2043.56-10027231) • All Android licenses accepted.

[√] Chrome - develop for the web • Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe

[X] Visual Studio - develop Windows apps X Visual Studio not installed; this is necessary to develop Windows apps. Download at https://visualstudio.microsoft.com/downloads/. Please install the "Desktop development with C++" workload, including all of its default components

[√] Android Studio (version 2022.3) • Android Studio at D:\android • Flutter plugin can be installed from: https://plugins.jetbrains.com/plugin/9212-flutter • Dart plugin can be installed from: https://plugins.jetbrains.com/plugin/6351-dart • Java version OpenJDK Runtime Environment (build 17.0.6+0-b2043.56-10027231)

[√] Connected device (4 available) • HRY AL00Ta (mobile) • 192.168.1.17:6666 • android-arm64 • Android 10 (API 29) • Windows (desktop) • windows • windows-x64 • Microsoft Windows [Version 10.0.22631.2265] • Chrome (web) • chrome • web-javascript • Google Chrome 116.0.5845.180 • Edge (web) • edge • web-javascript • Microsoft Edge 116.0.1938.69

[√] Network resources • All expected network resources are available.

! Doctor found issues in 1 category.

gdelataillade commented 1 year ago

Hi @gadgetsteach

Sorry I couldn't find the time to answer earlier. I'm sorry about your issue. I couldn't replicate it. Did you manage to resolve it ?

MayurDevmurari commented 1 year ago

Hello, I also faced the same issue,

steps I follow, just add the latest version of the alarm in pubspec.yaml file and pub get and faced issues while running the app.

MayurDevmurari commented 1 year ago

It says a namespace in the app-level build.gradle file is missing

gdelataillade commented 1 year ago

Hi @MayurDevmurari

Thanks for your feedback.

Does it fix the issue if you add:

android {
    [...]
    namespace 'com.gdelataillade.alarm'
    [...]
}

directly in the android/build.gradle file of the alarm package ?

I'm sorry I can't test it for you cause I'm not able to reproduce your issue... If it works, I'll add it to the next release of the plugin.

gdelataillade commented 1 year ago

Also try to run:

flutter clean
flutter pub get