Deprecated Gradle

Market data, Trading, Technical support, Features requests, etc
lnszmjhe
Posts: 19
Joined: Sat Feb 17, 2024 2:39 am

Deprecated Gradle

Post by lnszmjhe » Wed Feb 28, 2024 4:39 pm

When compiling the .JAR in Intellij IDEA this message appears.
How to resolve this?


Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.3/userguide/c ... e_warnings in the Gradle documentation.
 

Andry API support
Posts: 548
Joined: Mon Jul 09, 2018 11:18 am
Has thanked: 25 times
Been thanked: 85 times

Re: Deprecated Gradle

Post by Andry API support » Wed Feb 28, 2024 5:12 pm

Hi, please follow the steps in this answer. You will need to run gradle outside IDEA to figure what is wrong
https://stackoverflow.com/a/70120647/15539205

lnszmjhe
Posts: 19
Joined: Sat Feb 17, 2024 2:39 am

Re: Deprecated Gradle

Post by lnszmjhe » Thu Feb 29, 2024 9:29 pm

I don't think it's the same case as mine.
But I'm looking for a solution on the Gradle forums.
Thanks

Svyatoslav
Site Admin
Posts: 278
Joined: Mon Jun 11, 2018 11:44 am
Has thanked: 2 times
Been thanked: 31 times

Re: Deprecated Gradle

Post by Svyatoslav » Fri Mar 01, 2024 10:47 am

Hi. It is just saying that there is a feature being used that *will* become deprecated in 9.0. By itself - this is not harmful, it will just prevent project from being upgraded to newer gradle. If gradle wrapper is used - it will just keep using older gradle and be ok until it is manually updated. Preferably the authors of the project should replace soon-to-be-obsolete feature with a new alternative.

I suspect that relates to one of our demo projects?) If yes - could you please send a link?

lnszmjhe
Posts: 19
Joined: Sat Feb 17, 2024 2:39 am

Re: Deprecated Gradle

Post by lnszmjhe » Sat Mar 02, 2024 10:42 am

The problem was in the lines:

sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11

in the build.gradle settings file.

I commented these lines and everything went back to normal

07:57:44: Executing 'build --warning-mode=all'...

> Task :compileJava UP-TO-DATE
> Task :processResources NO-SOURCE
> Task :classes UP-TO-DATE
> Task :jar UP-TO-DATE
> Task :assemble UP-TO-DATE
> Task :compileTestJava NO-SOURCE
> Task :processTestResources NO-SOURCE
> Task :testClasses UP-TO-DATE
> Task :test NO-SOURCE
> Task :check UP-TO-DATE
> Task :build UP-TO-DATE

BUILD SUCCESSFUL in 891ms
2 actionable tasks: 2 up-to-date
07:57:45: Execution finished 'build --warning-mode=all'.

Post Reply