Is not possible build Spring Security: java.lang.IllegalStateException: Could not load file 'etc/nohttp/allowlist.lines'
See original GitHub issueDescribe the bug [Problem]
Is not possible Build Spring Security
To Reproduce
In MacOS and Windows I have the following situation
I have STS 4.9.0.RELEASE for a workspace dedicated for Spring Security. And configured for Java 8 according with the Building from Source section.
Therefore for the IDE itself:
NOTE: From above - I removed the JRE 15 included in the IDE to avoid problems
Prior to import Spring Security
I did
- git clone
- added remote repository
- git fetch
- git merge upstream/master
So I am sure I have the latest and stable code of the project
Then Spring Security
is imported and furthermore to be sure, I change for the Spring Security
project its JRE from 15 to 8 as follows:
And furthermore is mandatory fix the following:
Remove JRE 15 (I)
Remove JRE 15 (II)
Add JDK 8 (I)
Add JDK 8 (II)
The importation project was successful and configured fine to work with JDK 8.
Just in case I do the following:
Now according with the Building from Source section is time to execute ./gradlew install
, therefore through the IDE
It works fine as follows:
Therefore all the required dependencies are downloaded and available.
Now according with the Building from Source section is time to execute ./gradlew build
, therefore through the IDE
So the process starts:
But it fails with:
The message is:
Execution failed for task ':checkstyleNohttp'.
> java.lang.IllegalStateException: Could not load file 'etc/nohttp/allowlist.lines'
The same happens in other Machine on Windows 10, with a dedicated and isolated workspace for Spring Security.
Expected behavior It should Build without any problem.
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (3 by maintainers)
What appears to be happening is Eclipse isn’t propagating the working directory through to the underlying
NoHttpCheck
Checkstyle task when runningbuild -> checkstyleNohttp
.You can can configure the
build
Run Configuration in Eclipse to skip thecheckstyleNohttp
task. InProject -> Run Configurations
, find or create a Gradle Task where the task isbuild
. Then, in its Project Settings, add-xcheckstyleNohttp
as a program argument.You can then run
checkstyleNoHttp
separately.Thanks for the report, @manueljordan. I was able to reproduce the error you described, and I will take a look.
In the meantime, it sounds like you have a workaround, which is to build from the terminal.