3:06:20 PM: Executing ':MyApp.main()'...
> Task :compileJava UP-TO-DATE
> Task :processResources UP-TO-DATE
> Task :classes UP-TO-DATE
> Task :MyApp.main()
Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.
You can use '--warning-mode all' to show the individual deprecation warnings
and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/7.2/userguide/command_line_interface.html#sec:command_line_warnings
BUILD SUCCESSFUL in 190ms
3 actionable tasks: 1 executed, 2 up-to-date
3:06:20 PM: Execution finished ':MyApp.main()'.
Solution 1: Suppress the warning
In order to hide this warning, just add the below lines in your projects build.gradle files.
allprojects {
tasks.withType(JavaCompile) {
options.deprecation = true
}
}
Solution 2: Identify the incompatible features and replace them
Run the below command in Terminal to know the list of all incompatible features used,
./gradlew build --warning-mode all
Solution 3: Downgrade Gradle
If you want to use the older features of Gradle, just downgrade from version, or simply ignore the warnings!
Facing issues? Have Questions? Post them here! I am happy to answer!
Author Info:
Rakesh (He/Him) has over 14+ years of experience in Web and Application development. He is the author of insightful How-To articles for Code2care.
Follow him on: X
You can also reach out to him via e-mail: rakesh@code2care.org
More Posts related to Gradle,
- Run only a Single Unit Test using Gradle
- Run IntelliJ Java main method without Gradle build
- How to force re-download Gradle Dependencies
- How to Run Gradle Build Without Unit Test Cases
- Find installed Gradle version command
- Fix: Invalid Gradle JDK configuration found. Could not find the required JavaSDK
- Generate Project Dependency tree using Gradle Command
- Installing Gradle on macOS - Gradle Tutorial
- Gradle FAILURE: Build failed with an exception - Task not found in root project
- [Fix] ./gradlew: Permission denied
- Force Gradle to use specific Java JDK Version
- [fix] Deprecated gradle features were used in this build, making it incompatible with Gradle X.0
- Create a Gradle Java Project in VS Code
- Install Gradle VS Code for Java Projects
- Fix: Unsupported Java. Your build is currently configured to use Java 17.0.5 and Gradle 7.1.
- How to create Gradle Multi-Project in IntelliJ
- Fix: Spring Boot + IntelliJ + Gradle : Unsupported class file major version 64 Error
- Fix: Error: Could not find or load main class org.gradle.wrapper. GradleWrapperMain
- [fix] bash: gradlew: command not found
- [fix] Execution failed for task :core:compileJava - Could not find tools.jar
- Run Gradle Build without test cases
- How to add maven central repository in build.gradle
- Upgrade Gradle in Android Studio
- Task is ambiguous in root project gradle-examples. Candidates are: myTask1, myTask2
- Fix: Deprecated Gradle features were used in this build, making it incompatible with Gradle
More Posts:
- How to Split a String based on Delimiter in Bash Scripting - Bash
- [Fix] Java Exception with Lambda - Cannot invoke because object is null - Java
- Tool: Convert Cron Expression To Plain English Text (Supports Quartz) - Tools
- Fix: Uncaught ReferenceError: exit is not defined - Node.js REPL - JavaScript
- How to check if variable is a number in JavaScript (NaN, typeof, regex) - JavaScript
- 3 Commands to stop Nginx Server - Linux
- Change String Date Format from One Form to Another in Java - Java
- Jupyter Notebook Markup Cell Table Example - Python