Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use EISOP CF sources #116

Closed
wants to merge 25 commits into from
Closed

Use EISOP CF sources #116

wants to merge 25 commits into from

Conversation

wmdietl
Copy link
Collaborator

@wmdietl wmdietl commented Dec 6, 2023

As discussed, this is an attempt to break down the changes into smaller PRs.

The scripts should try to clone eisop/checker-framework automatically. If you already have a fork of the CF, it will use that, so you'll need to either update that fork or manually clone the CF first.

After this, ./gradlew test should work, so everything should compile and a minimal sanity check passes. Neither the conformance tests nor the samples will work as well as before. The goal is to have more PRs in the future that will break less and less.

initialize-project Outdated Show resolved Hide resolved
@wmdietl
Copy link
Collaborator Author

wmdietl commented Dec 6, 2023

The remaining build failure seems to be caused by this line.

> Task :checker-framework:framework:copyAndMinimizeAnnotatedJdkFiles
Error: Exception in thread "main" java.lang.NoClassDefFoundError: org/checkerframework/javacutil/BugInCF
	at org.checkerframework.framework.stub.JavaStubifier.process(JavaStubifier.java:73)
	at org.checkerframework.framework.stub.JavaStubifier.main(JavaStubifier.java:58)
Caused by: java.lang.ClassNotFoundException: org.checkerframework.javacutil.BugInCF
	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)
	at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:525)
	... 2 more

> Task :checker-framework:framework:copyAndMinimizeAnnotatedJdkFiles FAILED

It seems to not find the CF classes, likely because sourceSets.main.runtimeClasspath refers to the jspecify-reference-checker classpath instead of the CF classpath.

Does somebody know how to refer to the correct project in gradle?

@wmdietl
Copy link
Collaborator Author

wmdietl commented Dec 6, 2023

Does somebody know how to refer to the correct project in gradle?

eisop/checker-framework#654 should fix the issue.

@wmdietl
Copy link
Collaborator Author

wmdietl commented Dec 7, 2023

Does somebody know how to refer to the correct project in gradle?

eisop/checker-framework#654 should fix the issue.

That worked!

@wmdietl
Copy link
Collaborator Author

wmdietl commented Dec 7, 2023

Final status of conformance tests:

tests.ConformanceTest > checkConformance FAILED
    expected:
        # 10 pass; 6 fail; 16 total; 62.5% score
    but was:
        # 4 pass; 12 fail; 16 total; 25.0% score

and a snippet of the samples failures:

tests.NullSpecTest$Lenient > run[/home/runner/work/jspecify-reference-checker/jspecify/samples] FAILED
    java.lang.AssertionError: 1134 out of 1225 expected diagnostics were found.
    25 unexpected diagnostics were found:
....
    91 expected diagnostics were not found:
....
tests.NullSpecTest$Strict > run[/home/runner/work/jspecify-reference-checker/jspecify/samples] FAILED
    java.lang.AssertionError: 1169 out of 1225 expected diagnostics were found.
    350 unexpected diagnostics were found:
....
    56 expected diagnostics were not found:
....

@wmdietl wmdietl closed this Dec 8, 2023
@wmdietl wmdietl mentioned this pull request Dec 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant