JFrog Plugin Fails If You Run on Windows using Windows Subsystem Linux and Gradle
See original GitHub issueDescribe the bug If you are on any version of Windows and have installed Windows Subsystem for Linux (WSL) in order to install Gradle via SDKMAN, *which is the recommended way in the docs then the JFrog plugin completely fails to run since it doesn’t use WSL. Worth noting calling gradle using WSL is also supported by IntelliJ, which means users are likely to want feature parity.
To Reproduce Setup a Windows machine with Gradle on WSL. Get a gradle project loaded into IntelliJ, watch the plugin fail with null pointer exceptions.
Expected behavior The plugin should use the same command line/tools to execute that IntelliJ uses for Gradle projects.
Screenshots I can provide a stacktrace:
java.lang.Throwable: Could not scan Gradle project dependencies, because Gradle CLI is not in the PATH.
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:161)
at com.jfrog.ide.idea.log.Logger.error(Logger.java:51)
at com.jfrog.ide.common.gradle.GradleTreeBuilder.buildTree(GradleTreeBuilder.java:48)
at com.jfrog.ide.idea.scan.GradleScanManager.buildTree(GradleScanManager.java:63)
at com.jfrog.ide.idea.scan.ScanManager.scanAndUpdate(ScanManager.java:107)
at com.jfrog.ide.idea.scan.ScanManager$1.run(ScanManager.java:145)
at com.intellij.openapi.progress.impl.CoreProgressManager$TaskRunnable.run(CoreProgressManager.java:998)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcessWithProgressAsync$5(CoreProgressManager.java:497)
at com.intellij.openapi.progress.impl.ProgressRunner.lambda$submit$3(ProgressRunner.java:228)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$2(CoreProgressManager.java:178)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:688)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:634)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:64)
at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:165)
at com.intellij.openapi.progress.impl.ProgressRunner.lambda$submit$4(ProgressRunner.java:228)
at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1700)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:668)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:665)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:665)
at java.base/java.lang.Thread.run(Thread.java:834)
Versions
- JFrog IDEA plugin version: 1.9.1
- Operating system: Windows 10
- Xray version: 3.27.3
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
[GAP-296] Apply com.jfrog.artifactory plugin in gradle script ...
[GAP-296] Apply com.jfrog.artifactory plugin in gradle script-plugin fails Created: 19/Nov/18 Updated: 11/Dec/18 Resolved: 11/Dec/18 ; Type: Bug.
Read more >How to fix "plugin was not found in any of the following sources"
On changing the gradle JVM version to the Project's JVM version, this error got resolved. Save this answer.
Read more >Importing a Gradle project fails with an exception in the latest ...
For me this error uccurred, when I imported a gradle submodule again as a gradle module in IntelliJ manually.
Read more >JFrog to Shut down JCenter and Bintray - InfoQ
JFrog has announced that it is shutting down the Bintray asset hosting service, which includes the JCenter Java repository, often used by ...
Read more >How to diagnose unexpected build failures caused by plugin ...
I am now running into a problem where Gradle fails with a very unexpected failure when I include a new custom plugin for...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thank you for reporting this issue @jaybyrrd. This is definitely something we’d like to fix. We’re currently working on multiple improvements to the plugin and we’d like to include this one as well. We’ll update this issue once we implement this improvement.
@jaybyrrd, Thanks for reporting this issue. We released JFrog IDEA plugin 1.10.1. In this version, we use the Gradle executable and Java home as configured in the Gradle settings. This may resolve your issue.
Feel free to upgrade. We’d appreciate your feedback on that.