-
-
Notifications
You must be signed in to change notification settings - Fork 293
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
Update Gradle tooling to latest version #732
Comments
Thanks for flagging this. I have not experienced any issues with the build process (using Java 17 from Adoptium on macOS). What's the exact error message you are getting? @rupeshkumar22 do you have any suggestions/comments about this issue? |
When I build the PDE for Android and run it on an Emulator/Device, it shows this error message: |
Before this also, I had to import multiple dependencies for building the project, including Apache logger, common jar, Flatlaf, lsp4j, repository-30.3.0, sdklib, slf4j and tooling. It appears that all the project is not downloading all the dependencies when build. Maybe the gradle files need to be updated. |
As for this slf4j logger, even importing the jar file doesn't seem to help. What I found was that tooling was not supported with the gradle version. |
If possible, I would like to work on this issue, please guide me in the right direction. |
Hi @codeanticode , gradle issue is real, for @p4puniya I tried setting up pde and mode for him over the meet but gradle version issue persists there. According to my understanding what happens with gradle is when you have more than one version of gradle in your system, cache corruption due to wrong version of gradle use instead of the required creates the issue many times. And while building for processing-mode with Java 17 , i think we need to upgrade to the gradle version. Apart from gradle issue, dependencies issue is also there, idk why but this happened during my time as well. So exactly what happens you can see the dependencies in the gradle / module folder but when you try to build the code it says some files are missing or class not found error for the some dependencies this varies system to system. To fix this i got the temporary solution - just list all the dependencies creating issue -> download them with correct version in your local from maven , etc -> go to project settings -> add the local downloaded dependencies to the modules where they are being used. This helped me to solve the issue long back. Though this is a temporary solution. What I feel is we need to change the mechanism how dependencies are being managed in our codebase. I am open for discussion. @p4puniya will try to solve your issue over a meet today (most probably). Thanks ! |
@p4puniya @ranaaditya so this error happens not when building the mode using Gradle, but when you try to run a sketch from the PDE, is that correct? |
It happens when building mode with Gradle. But that can be temporarily fixed by importing the dependencies that give the error and thus, we can build our project. But when you run any code in the pde, the dependencies give the error again, just that they can't be externally imported this time. |
If this issue is affects running code from the PDE it should be impacting many users, so far does not seem to be the case. So it must be happening only under certain circumstances, Aditya said something about having several versions of Gradle installed in the system? I have not experienced it myself... My suggestion would be to update all the various gradle versions in use by the Android mode. The thing is that there is no single gradle tool/plugin/dependency, so far I think we have the following:
I do not know if I missing anything but my recommendation would be to upload all of these version so the latest in each category and see what happens. Some things might break and require updating the build scripts or the code of the mode itself :-) |
Hi @codeanticode , yes I also think that upgrading the Gradle version to 7.3+ would solve the issue. Please take a look at Gradle Matrix Compatibility Thanks, |
Hi @p4puniya , i think you can check simply by upgrading the gradle tooling api version. Let me know if you face any issue in this. For referrence similar issue Thanks, |
So far, I don't see any errors in building the mode or running sketches from the PDE or Android Studio related to the current version of the tooling. However, we should update it to latest versions at some point. Updating to Gradle 8 may require some changes in the build files: https://docs.gradle.org/current/userguide/upgrading_version_7.html |
The Gradle dependencies of version: 7.2 (gradle-tooling) are not supported by JAVA-17.
(as given in: https://docs.gradle.org/current/userguide/compatibility.html)
JAVA-17 supports gradle versions 7.3 and higher. Due to this issue, the build is failing. Could you help me in rectifying this issue?
@codeanticode
The text was updated successfully, but these errors were encountered: