-
Notifications
You must be signed in to change notification settings - Fork 434
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
Contract tests not generated in producer failing with compile error #2101
Comments
If it may help: It works if downgrading to gradle-6.8-all |
@shanman190 any ideas what can cause this? Gradle + windows ? |
@marcingrzejszczak, I don't think that it's a Windows + Gradle sort of problem. Here's the steps that I'd go through:
|
Hello!
The issue
I use spring cloud contract tests for a while now and they were working as expected. I've recently had to change my laptop (old one - Windows, this one Windows as well) and now the spring cloud contract tests are not generated anymore. We use Gradle as build tool.
What we've tried so far
generating them from the IDE as well as from PowerShell -> same error.
.\gradlew.bat :contract-tests:generateContractTests --debug --rerun-tasks
manually compiling contract providing the full classpath and JDK -> the compilation is successful.
javac -cp "C:\Users\diadeliu\.gradle\.tmp\gradle-javaexec-classpath3162018629030617727.jar;C:\Program Files\Java\jdk-11\lib\jrt-fs.jar" C:\Users\diadeliu\IdeaProjects\repo\contract-tests\build\stubs\META-INF\com.company\contract-tests\0.0.0\contracts\producer_name\consumer_name\SampleContract.java
providing gradle_home via environment variable or the folder path directly, in gradlew.bat and gradlew.sh files -> same error
"-Dgradle.user.home=C:\Gradle"
or"-Dgradle.user.home=gradle_home"
where gradle_home islocally installing gradle version 8.6 and make IDE use it -> same error
I've had this issue before and it was because I have had a space in the path of my folder structure "Name Surname", but now that's not the case anymore, as per the provided path above.
Please keep in mind that the provided configuration works for almost all of my peers and it's been working for me as well for the last couple of years.
We use:
The actual error
We've run out of ideas, so any help is much appreciated. Thanks in advance!
The text was updated successfully, but these errors were encountered: