Skip to content

ProjectCompilerVersionChecker.validateProjectComplianceLevel fails in spite of correct Java versions #2569

@PaulCormier

Description

@PaulCormier

I have installed "Hibernate Tools - 5.4.23.v20240515-1831" in my instance of Eclipse 2024-12, running on "JustJ JRE for IDE Packages 21.0.0.v20241024-0603", and I'm trying to use a Hibernate configuration in a project with compiler level 1.8 (I also tried 11 and 21). The result is that I get an error message that the project "has a higher compiler option than running Eclipse...".
Looking at the source code for where this message originates, ProjectCompilerVersionChecker, it appears that the JavaCore.COMPILER_CODEGEN_TARGET_PLATFORM is returning a string that is parsed into a higher int value than the parsing of the string returned by System.getProperty("java.specification.version"). I could see decodeJdkVersion returning 0 if the "java.specification.version" property weren't set, but I have no way of verifying what the code sees.

With this check failing, I am unable to use this plugin.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions