Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Improvement] Fix the gradle warning #4206

Open
jerryshao opened this issue Jul 18, 2024 · 9 comments
Open

[Improvement] Fix the gradle warning #4206

jerryshao opened this issue Jul 18, 2024 · 9 comments
Labels
good first issue Good for newcomers help wanted Extra attention is needed improvement Improvements on everything

Comments

@jerryshao
Copy link
Contributor

What would you like to be improved?

We have many Gradle script build warning, I think we can improve to remove the warnings, for example:

> Configure project :web
Kotlin DSL property assignment is an incubating feature.

> Configure project :catalogs:catalog-lakehouse-iceberg
w: file:///Users/jerryshao/Projects/gravitino/catalogs/catalog-lakehouse-iceberg/build.gradle.kts:98:7: Variable 'runtimeJars' is never used
w: file:///Users/jerryshao/Projects/gravitino/catalogs/catalog-lakehouse-iceberg/build.gradle.kts:158:57: Unchecked cast: Any? to (Test) -> Unit

> Configure project :catalogs:catalog-lakehouse-paimon
w: file:///Users/jerryshao/Projects/gravitino/catalogs/catalog-lakehouse-paimon/build.gradle.kts:89:7: Variable 'runtimeJars' is never used
w: file:///Users/jerryshao/Projects/gravitino/catalogs/catalog-lakehouse-paimon/build.gradle.kts:145:57: Unchecked cast: Any? to (Test) -> Unit

> Configure project :iceberg:iceberg-rest-server
w: file:///Users/jerryshao/Projects/gravitino/iceberg/iceberg-rest-server/build.gradle.kts:83:7: Variable 'runtimeJars' is never used
w: file:///Users/jerryshao/Projects/gravitino/iceberg/iceberg-rest-server/build.gradle.kts:139:57: Unchecked cast: Any? to (Test) -> Unit

> Configure project :spark-connector:spark-3.3
w: file:///Users/jerryshao/Projects/gravitino/spark-connector/v3.3/spark/build.gradle.kts:159:57: Unchecked cast: Any? to (Test) -> Unit

> Configure project :spark-connector:spark-3.4
w: file:///Users/jerryshao/Projects/gravitino/spark-connector/v3.4/spark/build.gradle.kts:159:57: Unchecked cast: Any? to (Test) -> Unit

> Configure project :spark-connector:spark-3.5
w: file:///Users/jerryshao/Projects/gravitino/spark-connector/v3.5/spark/build.gradle.kts:161:57: Unchecked cast: Any? to (Test) -> Unit

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.2/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

Above are several warnings when we run gradle clean, I can fix it.

How should we improve?

No response

@jerryshao jerryshao added good first issue Good for newcomers improvement Improvements on everything need backport Issues that need to backport to another branch labels Jul 18, 2024
@jerryshao jerryshao pinned this issue Jul 18, 2024
@jerryshao jerryshao unpinned this issue Jul 18, 2024
@jerryshao jerryshao added help wanted Extra attention is needed and removed need backport Issues that need to backport to another branch labels Jul 19, 2024
@frankvicky
Copy link
Contributor

I would like to try to solve this issue, please assign it to me.
Many thanks 😺

@yuqi1129
Copy link
Contributor

I would like to try to solve this issue, please assign it to me. Many thanks 😺

Nice, please go ahead, I will assign it to you.

@justinmclean
Copy link
Member

@frankvicky How are you going this this? Are you still able to work on it?

@frankvicky
Copy link
Contributor

Hi @justinmclean
Unfortunately I dont have free cycle now, if this ticket is in a rush, feel free to reassign.

@ChengyanOo
Copy link

justinmclean
Hi @justinmclean, I would love to work on this issue, could anyone assign this to me?

@ChengyanOo
Copy link

Hi @jerryshao, could you share your version of the 'gradle-wrapper.jar' file? I built the project with gradle-wrapper.jar(v8.11.0-M1) and didn't trigger these warnings, I am suspecting whether its because this?

@jerryshao
Copy link
Contributor Author

You can just simply run the ./gradlew build to see the warnings, the script will download the wrapper jar automatically, you don't have to install it manually.

@ChengyanOo
Copy link

Hi @jerryshao, thanks for the explanation, I just re-built the program with "./gradlew build" a couple more times. However, I was only able to trigger the warnings thats in your screenshot for one time, and it seemed like after the dependencies were installed the warnings were also gone. I tried cleaning the cache but the warnings were still gone.

@jerryshao
Copy link
Contributor Author

I think you should add arguments like --rerun-tasks to your grade command so that it will run all the tasks every time. Besides, since it is a long-time issue, some warning may already been fixed, so please fix the warnings as possible as you can.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Extra attention is needed improvement Improvements on everything
Projects
None yet
Development

No branches or pull requests

5 participants