close

[Solved] Could not get unknown property ‘runtime’ for configuration container of type org.gradle.api.internal.artifacts.configurations

Hello Guys, How are you all? Hope You all Are Fine. Today I am facing the following error Could not get unknown property ‘runtime’ for configuration container of type org.gradle.api.internal.artifacts.configurations in Java. So Here I am Explain to you all the possible solutions here.

Without wasting your time, Let’s start This Article to Solve This Error.

How Could not get unknown property ‘runtime’ for configuration container of type org.gradle.api.internal.artifacts.configurations Error Occurs?

Today I am facing the following error Could not get unknown property ‘runtime’ for configuration container of type org.gradle.api.internal.artifacts.configurations in Java.

How To Solve Could not get unknown property ‘runtime’ for configuration container of type org.gradle.api.internal.artifacts.configurations Error ?

  1. How To Solve Could not get unknown property 'runtime' for configuration container of type org.gradle.api.internal.artifacts.configurations Error ?

    To Solve Could not get unknown property 'runtime' for configuration container of type org.gradle.api.internal.artifacts.configurations Error This is because of the differences between your gradle version and gradle7. From Gradle 6.x, the use of the parameter configurations.runtime to get configurations of program execution is disabled.

  2. Could not get unknown property 'runtime' for configuration container of type org.gradle.api.internal.artifacts.configurations

    To Solve Could not get unknown property 'runtime' for configuration container of type org.gradle.api.internal.artifacts.configurations Error This is because of the differences between your gradle version and gradle7. From Gradle 6.x, the use of the parameter configurations.runtime to get configurations of program execution is disabled.

Solution 1

This is because of the differences between your gradle version and gradle7. From Gradle 6.x, the use of the parameter configurations.runtime to get configurations of program execution is disabled. Instead, you can use configurations.runtimeClasspath to achieve the same ability. Gradle7 docs After that, I succeeded in compilitation and get the true constructure of project.

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.1/userguide/command_line_interface.html#sec:command_line_warnings

Summery

It’s all About this issue. Hope all solution helped you a lot. Comment below Your thoughts and your queries. Also, Comment below which solution worked for you? Thank You.

Also, Read