Bug Resolution: Java package xxx does not exist
Bug Description
- IDE: IntelliJ IDEA 2021.3
- Language: Java
- Error: Java package xxx does not exist
I imported a library into a service of a module in a multi-module Spring Boot project. The relevant import statement is written in the code, and the relevant dependency is also introduced in the pom.xml. When building the project, the IDE prompts this error: Java package xxx does not exist.
Solution
The following methods can solve this bug.
![](/images/java-bug-1/1.png)
![](/images/java-bug-1/2.png)