Mod Error: Your workspace contains mod elements that dont compile properly

Status
Works as designed
Issue description
I created a new mod, added the first elements and got the following error message when exporting: (see screenshot) then I deleted the mod and made everything again the same error message

Issue comments

You set custom JAVA_HOME in preferences for some unknown reason. Clear that parameter in preferences