question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Task 'uploadCrashlyticsSymbolFileRelease' not found in root/app project

See original GitHub issue

Environment

  • Android Studio version: 3.6.1
  • Firebase Gradle Plugin: 2.0.0-beta02
  • Firebase Component: Firebase Crashlytics NDK
  • Component version: 17.0.0-beta01

Problem

Tasks to upload debug symbols to Crashlytics are not generated.

I have created a template project that Android Studio provides by default and set up Firebase Crashlytics NDK as described here https://firebase.google.com/docs/crashlytics/ndk-reports-new-sdk#enable-symbol-uploading. Project successfully compiled (release build type) and appeared in Firebase Console but when I try to call gradlew uploadCrashlyticsSymbolFileRelease there is an error:

Task 'uploadCrashlyticsSymbolFileRelease' not found in root project 'Template'.

or

Task 'uploadCrashlyticsSymbolFileRelease' not found in project 'app'.

Also, I do not forget to add this code to build type release:

buildTypes {
    getByName("release") {
            .....
            firebaseCrashlytics {
                nativeSymbolUploadEnabled = true
            }
            .....
    }
}

Steps to reproduce:

  1. Make template project in android studio
  2. Set up Firebase Crashlytics SDK (https://firebase.google.com/docs/crashlytics/get-started-new-sdk?platform=android)
  3. Set up Firebase Crashlytics NDK (https://firebase.google.com/docs/crashlytics/ndk-reports-new-sdk#enable-symbol-uploading)

Expexted results

After assembleRelease command can call gradlew :app:uploadCrashlyticsSymbolFileRelease

Real results

Tasks uploadCrashlyticsSymbolFile<BuildVariant> are not even generated

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:15 (4 by maintainers)

github_iconTop GitHub Comments

3reactions
NUmeroAndDevcommented, May 27, 2020

I used withGroovyBuilder to work around.

withGroovyBuilder {
    "firebaseCrashlytics" {
        "nativeSymbolUploadEnabled"(true)
    }
}
1reaction
vkryachkocommented, Jun 5, 2020

tldr: you need to case buildType to ExtensionAware for correct behavior, using the following should fix your issues.

buildTypes {
    getByName("release") {
            .....
            (this as ExtensionAware).configure<CrashlyticsExtension> {
                nativeSymbolUploadEnabled = true
            }
            .....
    }
}

The problem is that the way kotlin dsl works is by adding an extension method configure() to all ExtensionAware classes. While BuildType is ExtensionAware at runtime, it is not declared in its definition, as a result kotlin does not call configure() on the buildType, but on the project itself, this results in incorrect behavior.

Please reopen the issue if the above does not solve the problem

Read more comments on GitHub >

github_iconTop Results From Across the Web

uploadCrashlyticsSymbolFile task not being generated with ...
Is this a bug on crashlytics gradle plugin or am I missing something? ... Task 'uploadCrashlyticsSymbolFileRelease' not found in root ...
Read more >
Get Android NDK crash reports | Firebase Crashlytics - Google
The Crashlytics Gradle plugin includes the uploadCrashlyticsSymbolFile BUILD_VARIANT task to automate this process. Note: Crashlytics supports alternative ...
Read more >
Task 'Assembledevkerneldebug' Not Found In Project ':App'
What went wrong: Task 'installDebug' not found in project ':app'. Try: Run gradlew tasks to get a list of available tasks. Run with...
Read more >
How to fix Task 'wrapper' not found in project ' - YouTube
#AndroidStudio #error. How to fix Task 'wrapper' not found in project ':app'. error in Android Studio simple method 2021.
Read more >
Build failure not easily linked with dependency which needs to ...
A project with these dependencies ... Some problems were found with the configuration of task ... There is really not much we can...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found