eisop / checker-framework

Pluggable type-checking for Java
https://eisop.github.io/
Other
18 stars 18 forks source link

Run JSpecify conformance tests with the Nullness Checker #709

Closed rohan-shettyy closed 6 months ago

rohan-shettyy commented 7 months ago
rohan-shettyy commented 7 months ago

Added a new commit addressing this feedback.

Is it working for you locally? I don't immediately see which of your changes causes this.

Yes, this works locally. I am also not sure what causes the failure.

rohan-shettyy commented 7 months ago

Removing the tasks dependency and the runJSpecifyConformanceTests task individually does not remove the error. Attempting to remove the unzip task gives an error:

Execution failed for task ':checker:compileTestJava'.
> Could not resolve all files for configuration ':checker:testCompileClasspath'.
   > Could not resolve org.jspecify.conformance:conformance-test-framework:0.0.0-SNAPSHOT.
     Required by:
         project :checker
      > No matching variant of org.jspecify.conformance:conformance-test-framework:0.0.0-SNAPSHOT:20240207.191836-12 was found. The consumer was configured to find a library for use during compile-time, compatible with Java 8, preferably in the form of class files, preferably optimized for standard JVMs, and its dependencies declared externally but:
          - Variant 'apiElements' capability org.jspecify.conformance:conformance-test-framework:0.0.0-SNAPSHOT declares a library for use during compile-time, packaged as a jar, and its dependencies declared externally:
              - Incompatible because this component declares a component, compatible with Java 9 and the consumer needed a component, compatible with Java 8
              - Other compatible attribute:
                  - Doesn't say anything about its target Java environment (preferred optimized for standard JVMs)
          - Variant 'runtimeElements' capability org.jspecify.conformance:conformance-test-framework:0.0.0-SNAPSHOT declares a library for use during runtime, packaged as a jar, and its dependencies declared externally:
              - Incompatible because this component declares a component, compatible with Java 9 and the consumer needed a component, compatible with Java 8
              - Other compatible attribute:
                  - Doesn't say anything about its target Java environment (preferred optimized for standard JVMs)

Could this be an issue with the conformance-test-framework artifact?

wmdietl commented 7 months ago

Could this be an issue with the conformance-test-framework artifact?

As just discussed, let's try adding a version check. We don't have a 9+ variable here yet, so add that there.