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.

An error occurred during Android build since last update

See original GitHub issue

Environment

How do you use Sentry? Sentry SaaS

Which SDK and version? react-native 3.0.2

Steps to Reproduce

  1. Build the Android application (Debug or release mode)

Expected Result

Build successfully

Actual Result

An error is occurred. Same error when I try to build the Android app with AppCenter. Everything worked fine 3 hours ago. Maybe caused by @marandaneto last commit?

project1/node_modules/@sentry/react-native/android/src/main/java/io/sentry/react/RNSentryModule.java:86: error: lambda expressions are not supported in -source 7
        SentryAndroid.init(this.getReactApplicationContext(), options -> {
                                                                      ^
  (use -source 8 or higher to enable lambda expressions)
1 error

FAILURE: Build failed with an exception.

Thanks for your help

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:8 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
numandev1commented, Sep 7, 2021

same issue

0reactions
numandev1commented, Sep 7, 2021

@marandaneto most of the users are not using AGP >=4.2. there are two options for the user to fix this

  1. update AGP version to 4.2
  2. patch package by adding default java version 8

I think, forcefully update the AGP version from the user is not a good approach

Read more comments on GitHub >

github_iconTop Results From Across the Web

Known issues with Android Studio and Android Gradle Plugin
This section describes known issues that exist in the latest stable version of Android Studio. Error when rendering Compose Preview. Starting with Android...
Read more >
Fix an installed Android app that isn't working
Try the following steps if an app installed on your phone has any of these problems: Crashing. Won't open. Won't respond. Isn't working...
Read more >
Build errors after android studio update
After update android studio when I create a project I get an error: Error:Execution failed for task ':app:preDebugAndroidTestBuild'.
Read more >
Android Studio — How to fix it
Update #4 ... Issue: I encountered below issue when try to build the app. android studio Run Configuration Error: Broken configuration due to...
Read more >
Updates
In debug builds, the default behavior is to always load the latest JavaScript from a development server. It is possible to build a...
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