• Register
0 votes
152 views

Problem :

Using IntelliJ IDE unable to compile any projects getting bellow error
error:java: javactask: source release 1.8 requires target release 1.8
6 5 3
6,930 points

Please log in or register to answer this question.

2 Answers

0 votes

Solution :

I fixed the issue just by changing target compile version to 1.8.

Please goto bellow path to change the target compile version to 1.8

File >> Settings >> Build, Execution, Deployment >> Compiler >> Java Compiler

Further Readings:

9 7 4
38,600 points
0 votes

This error depends upon the java syntax and rules, during the coding phase. In the further sections, we will learn why this type of error occurs and how to solve this error.

Reason:

“Error: java: javactask: source release 8 requires target release 1.8” is an error that occurs on the developer's screen when incorrect version information of java compiler is entered in the code.

The problem occurs due to the incorrect version of java source and target release configuration while using the java project development software tool such as Intellij, IDEA, or Apache Maven.

Solution:

In order to fix the java code error on your system, simply make the changes in the required code which is given as;

IntelliJ IDEA, IDE:

If you are using IntelliJ IDEA, IDE follow the solution given below;

  • Go to File -> Settings -> Build, Execution , Deployment -> Compiler -> Java Compiler.
  • Change the “target bytecode version” to 1.8 of the module that you are working for.
  • Save the changes and re-launch the tool to save the effects.

Apache Maven:

While using the Apache Maven tool, editing the java compiler with the correct versions can easily help to solve the problem. Apache Maven is based on the project object model, where you are only required to add the compiler plug-in to pom.xml under the top-level project node.

11 5 2
3,890 points

Related questions

0 votes
2 answers 596 views
596 views
Problem : Using IntelliJ IDE can not compile any projects getting bellow error error:java: javactask: source release 8 requires target release 1.8
asked Nov 1, 2019 peterlaw 6.9k points
0 votes
1 answer 128 views
128 views
Problem : I am getting bellow error when running a JUnit test using IntelliJ IDEA error java javactask source release 1.7 requires target release 1.7
asked Nov 1, 2019 peterlaw 6.9k points
0 votes
1 answer 12 views
12 views
Does anybody have any ideas?
asked Dec 19, 2020 TeamScript 13.5k points
0 votes
1 answer 21 views
21 views
Solve this.
asked Dec 27, 2020 TeamScript 13.5k points
0 votes
1 answer 27 views
27 views
Problem: Hello Kodlogs, I'm trying to run my JSQL parser class, but I'm getting Error: java: invalid source release 1.9. I am all trying to understand and find the problem to fix the error. Could you please help me out to fix the error on my ... the solution. I found the forum helpfull and friendly that makes me posting and seeking help here. I look forward reading your comments. Thanks.
asked Jun 21, 2020 adamSw 11.3k points
0 votes
1 answer 2 views
2 views
Problem: I'm trying to run my JSQL parser class, but I'm getting Error: java: invalid source release 1.9. I tried to many answers changed File> Build,Execution,Deployment> Java Compiler> Project bytecode version: 1.8. However, I can't change the Module language level and Project language level to 1.8 because there's not option for that. I still get the same error
asked 1 day ago Ali 4.3k points
0 votes
1 answer 16 views
16 views
How can I correct this?
asked Dec 28, 2020 TeamScript 13.5k points
0 votes
1 answer 13 views
13 views
Problem: My guess is that it's something related to Java 8 vs Java 7, but I have no idea what specifically.
asked Feb 15 TeamScript 13.5k points
0 votes
1 answer 32 views
32 views
Solve this error.
asked Dec 26, 2020 TeamScript 13.5k points
0 votes
1 answer 63 views
63 views
Problem : I am getting bellow error while I'm trying to setup an Android dev environment on Mac error:buildtools 24.0.2 requires java 1.8 or above. current jdk version is 1.7.
asked Oct 19, 2019 peterlaw 6.9k points