Repository navigation
Closed
Labels
platform-androidAndroid applications specificallyAndroid applications specificallyt: gradle"flutter build" and "flutter run" on Android"flutter build" and "flutter run" on AndroidtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.
Description
Steps to Reproduce
- use
flutter channel master flutter build appbundle -vorflutter build apk -v
Logs
.
.
.
[ +2 ms] Running Gradle task 'bundleRelease'...
[ +7 ms] executing: [/Users/ezragunn/private-develop/projects/codecumbers/android/]
/Users/ezragunn/private-develop/projects/codecumbers/android/gradlew -Pverbose=true -Ptarget=lib/main.dart
-Ptrack-widget-creation=false -Pproguard=true -Ptarget-platform=android-arm,android-arm64 bundleRelease
[+2302 ms] FAILURE: Build failed with an exception.
[ +3 ms] * Where:
[ ] Script '/Users/ezragunn/private-develop/SDKs/flutter/packages/flutter_tools/gradle/flutter.gradle' line: 163
[ ] * What went wrong:
[ ] A problem occurred evaluating script.
[ ] > Failed to apply plugin [class 'FlutterPlugin']
[ ] > No signature of method: static FlutterPlugin.useProguard() is applicable for argument types: (Boolean) values:
[true]
[ ] * 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 2s
[ +740 ms] Running Gradle task 'bundleRelease'... (completed in 3.1s)
[ +7 ms] "flutter appbundle" took 283,198ms.
Gradle task bundleRelease failed with exit code 1
#0 throwToolExit (package:flutter_tools/src/base/common.dart:28:3)
#1 _buildGradleProjectV2 (package:flutter_tools/src/android/gradle.dart:791:5)
<asynchronous suspension>
#2 buildGradleProject (package:flutter_tools/src/android/gradle.dart:519:14)
<asynchronous suspension>
#3 _AndroidBuilderImpl.buildAab (package:flutter_tools/src/android/android_builder.dart:136:12)
<asynchronous suspension>
#4 BuildAppBundleCommand.runCommand (package:flutter_tools/src/commands/build_appbundle.dart:75:26)
<asynchronous suspension>
#5 FlutterCommand.verifyThenRunCommand (package:flutter_tools/src/runner/flutter_command.dart:490:18)
#6 _asyncThenWrapperHelper.<anonymous closure> (dart:async-patch/async_patch.dart:71:64)
#7 _rootRunUnary (dart:async/zone.dart:1132:38)
#8 _CustomZone.runUnary (dart:async/zone.dart:1029:19)
#9 _FutureListener.handleValue (dart:async/future_impl.dart:137:18)
#10 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:678:45)
#11 Future._propagateToListeners (dart:async/future_impl.dart:707:32)
#12 Future._completeWithValue (dart:async/future_impl.dart:522:5)
#13 Future._asyncComplete.<anonymous closure> (dart:async/future_impl.dart:552:7)
#14 _rootRun (dart:async/zone.dart:1124:13)
#15 _CustomZone.run (dart:async/zone.dart:1021:19)
#16 _CustomZone.runGuarded (dart:async/zone.dart:923:7)
#17 _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:963:23)
#18 _microtaskLoop (dart:async/schedule_microtask.dart:41:21)
#19 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)
#20 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:116:13)
#21 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:173:5)
Ezras-MacBook-Pro:codecumbers ezragunn$ flutter doctor -v
[✓] Flutter (Channel master, v1.10.2-pre.31, on Mac OS X 10.14.6 18G95, locale en-GB)
• Flutter version 1.10.2-pre.31 at /Users/ezragunn/private-develop/SDKs/flutter
• Framework revision 1676b012e8 (2 hours ago), 2019-09-10 19:01:12 -0700
• Engine revision 7ea9884ab0
• Dart version 2.5.0 (build 2.5.0-dev.4.0 be66176534)
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
• Android SDK at /Users/ezragunn/Library/Android/sdk
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-29, build-tools 29.0.2
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 10.3)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 10.3, Build version 10G8
• CocoaPods version 1.7.1
[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 3.5)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin version 39.0.3
• Dart plugin version 191.8423
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
[✓] IntelliJ IDEA Community Edition (version 2019.2.2)
• IntelliJ at /Applications/IntelliJ IDEA CE.app
• Flutter plugin version 39.0.5
• Dart plugin version 192.6603.23
[✓] Connected device (2 available)
• iPhone Xʀ • 14576690-91D8-430C-A80E-A32CC3459002 • ios • com.apple.CoreSimulator.SimRuntime.iOS-12-4
(simulator)
• Chrome • chrome • web-javascript • Google Chrome 76.0.3809.132
Reacted by Rahul Manthena
Metadata
Metadata
Assignees
Labels
platform-androidAndroid applications specificallyAndroid applications specificallyt: gradle"flutter build" and "flutter run" on Android"flutter build" and "flutter run" on AndroidtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.
Activity
ezraaaa commentedon Sep 11, 2019
gradle.properties
android/app/build.gradle
proguard-rules.pro
p30arena commentedon Sep 11, 2019
I'm having the same error after updating the master channel
gunnardag commentedon Sep 11, 2019
I'm also having the same error on master, but stable was updated recently so temporary solution is to switch to stable.
ezraaaa commentedon Sep 11, 2019
dev works
blasten commentedon Sep 11, 2019
Would you mind pasting the content of the file
<app-directory>/android/gradle/wrapper/gradle-wrapper.propertiesand the content of the file<app-directory>/android/build.gradle?GroovinChip commentedon Sep 11, 2019
No branch works for me. I am unable to build releases.
blasten commentedon Sep 11, 2019
@GroovinChip would you mind following these steps #40213 (comment) and then paste the result here?
Also run
flutter build apk --no-proguardorflutter build appbundle --no-proguardGroovinChip commentedon Sep 11, 2019
ezraaaa commentedon Sep 12, 2019
Hey @blasten ,
here are the files you requested
android/gradle/wrapper/gradle-wrapper.properties
android/build.gradle
ezraaaa commentedon Sep 12, 2019
@GroovinChip I constantly remove
.gradlefile whenever there is a change indistributionUrlor switching branch to get a fresh start with this commandsudo rm -r ~/.gradle. Maybe you can try it outGroovinChip commentedon Sep 12, 2019
@blasten I can try those commands now, will update shortly
GroovinChip commentedon Sep 12, 2019
@blasten here's the results of
flutter build apk --no-proguard:and here is the results of
flutter build appbundle --no-proguard:I'll run in verbose mode shortly. In the meantime, here is my
gradle-wrapper.properties:and my app-level
build.gradle:GroovinChip commentedon Sep 12, 2019
OK, here's the error from the end of
flutter build appbundle --no-proguard -v:GroovinChip commentedon Sep 12, 2019
Here's a full log of
flutter build appbundle --no-proguard -vappbundle_noproguard_verbose.txt
blasten commentedon Sep 13, 2019
@GroovinChip I can reproduce this on Gradle: 5.1.1 / Android Gradle plugin: 3.4.1. I would have a patch tomorrow, but for now try using Gradle: 4.10.2 / Android Gradle plugin: 3.2.1.
android/gradle/wrapper/gradle-wrapper.properties:
android/gradle/build.gradle:
github-actions commentedon Aug 28, 2021
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.