Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installing cloud_firestore plugin -> Unable to merge dex #21005

Closed
ryzizub opened this issue Aug 24, 2018 · 1 comment

Comments

@ryzizub
Copy link

@ryzizub ryzizub commented Aug 24, 2018

I added cloud_firestore plugin into my pubspec.yaml file and when i make flutter run it keeps saying errors.

Pubspec.yaml

name: my_admin
description: My Admin Test App

dependencies:
  flutter:
    sdk: flutter
  cupertino_icons: ^0.1.2
  firebase_auth: ^0.5.19
  cloud_firestore: ^0.7.4

dev_dependencies:
  flutter_test:
    sdk: flutter
flutter:
  uses-material-design: true

  # To add assets to your application, add an assets section, like this:
  # assets:
  #  - images/a_dot_burr.jpeg
  #  - images/a_dot_ham.jpeg

Logs

flutter run
Launching lib/main.dart on Redmi Note 4 in debug mode...
Initializing gradle...                                       0,9s
Resolving dependencies...                                    1,9s
Running 'gradlew assembleDebug'...
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedFolders(FileCollection)

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug'.
> java.lang.RuntimeException: java.lang.RuntimeException: com.android.builder.dexing.DexArchiveMergerException: Unable to merge dex

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 2s
Gradle build failed: 1
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel beta, v0.5.1, on Microsoft Windows [Version 10.0.17134.48], locale cs-CZ)
[√] Android toolchain - develop for Android devices (Android SDK 28.0.2)
[√] Android Studio (version 3.1)
[!] VS Code, 64-bit edition (version 1.26.1)
[√] Connected devices (1 available)

! Doctor found issues in 1 category.
@ryzizub

This comment has been minimized.

Copy link
Author

@ryzizub ryzizub commented Aug 25, 2018

Found solution.... i added multiDexEnabled true into defaultConfig in app/build.gradle

@ryzizub ryzizub closed this Aug 25, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.