Skip to content
This repository has been archived by the owner on Sep 26, 2022. It is now read-only.

use -source 8 or higher to enable lambda expressions #192

Closed
PIXPOINT opened this issue Nov 1, 2021 · 2 comments
Closed

use -source 8 or higher to enable lambda expressions #192

PIXPOINT opened this issue Nov 1, 2021 · 2 comments

Comments

@PIXPOINT
Copy link

PIXPOINT commented Nov 1, 2021

Since the latest version 1.3.0 I can no longer start my app via Android Studio.
I get the following error message:

\my_project\node_modules\@capacitor-community\http\android\src\main\java\com\getcapacitor\plugin\http\Http.java:144: error: lambda expressions are not supported in -source 1.7
                HttpRequestHandler.ProgressEmitter emitter = (bytes, contentLength) -> {};
                                                                                    ^
  (use -source 8 or higher to enable lambda expressions)

I also get the same error in a newly created project.

The following plugins are installed:

"@capacitor-community/http": "^1.3.0",
"@capacitor/android": "^3.2.5",
"@capacitor/app": "^1.0.5",
"@capacitor/browser": "^1.0.5",
"@capacitor/cli": "^3.2.5",
"@capacitor/core": "^3.2.5",
"@capacitor/device": "^1.0.5",
"@capacitor/filesystem": "^1.0.5",
"@capacitor/ios": "^3.2.5",
"@capacitor/push-notifications": "^1.0.6",
"@capacitor/splash-screen": "^1.1.5",
"@capacitor/storage": "^1.2.2",
"@capacitor/toast": "^1.0.5",
@jkbz64
Copy link
Contributor

jkbz64 commented Nov 1, 2021

#159 used lambda expressions which are supported starting from java8
#174 fixes the issue and is awaiting merge (replaces lambdas with <java8 equivalents)

@thomasvidas
Copy link
Contributor

I merged in #159 and #174. This will be fixed in the next release later tonight

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants