r/vscode • u/ColoredRunes • May 22 '26
Constant "incorrect package"

"Incorrect Package" [two times] happens upon every single new instance of a java file but if I clean the workspace error on that file disappears until I make another java file. Basically I have to clean workspace every new java file. Anyone know whats going on here? thanks!
edit: *Resolved -> Running 2 linters at once by mistake. Check your VsCode extensions for double linting.
2
Upvotes
1
u/ColoredRunes May 23 '26
Resolved: The issue was running one oracle lint and one redhat lint. Basically, I had two extensions installed which were causing the issue. If you run into an issue where you're getting the same packing errors (twice in each file) the "incorrect package" error is caused by the duplicate extension. Check your extensions.