I am getting this error while trying to import a grails 3.3.2 project into intellij. I have searched online solutions and not found anything helpful.
I found a solution to this question on this thread. Solution is just to delete the build folder and rebuild the project
for me just delete the build folder and rebuild the project and it worked
As per below thread, I deleted the "build/.dependencies" file and it worked after resolving the dependencies again.
export GRAILS_OPTS="-XX:-UseSplitVerifier -Xverify:none"
One potential cause is a mismatch of your defined profiles:
build.groovy:
profile "org.grails.profiles:angular"
application.yml: grails.profile: web
Make sure these agree with each other.
Deleting build
directory may work in most cases, but using the Gradle clean
task is the recommended and best practice approach for cleaning the build in a Grails application. It ensures consistency, safety, and compatibility with the Gradle build system.
You can call it either from command line:
gradlew clean
or from your IDE:
Here are some arguments why it's a better approach:
Standardization: Using the
gradle clean
command ensures a standardized and consistent way of cleaning the build. It's a well-defined task that is widely used in the Gradle ecosystem.Dependency Management: The
gradle clean
command is aware of project dependencies, and it can clean the build artifacts and caches accordingly. Manually deleting thebuild
directory might leave behind some cached files, leading to potential issues or outdated build results.Task Safety: Gradle's
clean
task is designed to be safe and reliable. It only deletes files related to the build process, preserving other essential project files and directories.Automation: By using
gradle clean
, users can integrate it into their build automation process, making it part of the regular development workflow. This ensures that the project starts from a clean state before every build.Ease of Use: The
gradle clean
command is simple and easy to remember. It eliminates the risk of accidentally deleting important files from the project.Team Collaboration: Using the standard
gradle clean
command makes it easier for other team members to understand and contribute to the project. It reduces confusion and prevents potential issues caused by manual build deletions.Future Compatibility: Gradle may evolve, and new features or improvements might be introduced in the
clean
task. By using the official Gradle command, users can benefit from these updates without any extra effort.
© 2022 - 2024 — McMap. All rights reserved.