Skip to content

Commit 04e8c9a

Browse files
authoredAug 8, 2024··
Nopol supports java 17 (#234)
1 parent 70e9989 commit 04e8c9a

File tree

4 files changed

+12
-5
lines changed

4 files changed

+12
-5
lines changed
 

‎.github/workflows/core.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
- name: Setup JDK
2020
uses: actions/setup-java@v2
2121
with:
22-
java-version: 11
22+
java-version: 17
2323
distribution: 'adopt'
2424

2525
- name: Set up Maven

‎README.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,11 @@ Others papers about Nopol:
2323

2424
Nopol requires Java and an SMT solver installed on the machine (e.g. Z3)
2525

26-
Up to commit 80130c4c, Nopol required Java 8. Now it also works on Java 11, see https://github.com/SpoonLabs/nopol/pull/214
26+
Java version:
27+
28+
* From 2013 to 2021, Nopol required Java 8.
29+
* From Nov 19, 2021, Nopol works on Java 11, see https://github.com/SpoonLabs/nopol/pull/214
30+
* From August 8 2024, Nopol works with Java 18, see https://github.com/SpoonLabs/nopol/pull/234
2731

2832
0) NoPol uses the `com.sun.jdi` that lives in `tools.jar`. Identify where `tools.jar` is and add the depencency in `pom.xml`
2933

‎nopol/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
To run the tests:
33

4-
* install a JDK, and ensure that maven uses it
4+
* install a JDK, see expected version in ../README.md, and ensure that maven uses it
55
* check that `z3` works well on the command line (`$ lib/z3/z3_for_linux``) (see TestUtility.java: private String solverPath = "lib/z3/z3_for_linux";)`
6-
* first run `mvn test -DskipTests` in `../test-projects/`. This creates `../test-projects/target/test-classes` (but doesn(t run the tests since the examples are buggy)
6+
* first run `mvn test -DskipTests` in `../test-projects/`. This creates `../test-projects/target/test-classes` (but doesn't run the tests since the examples are buggy)
77
* then `mvn test`

‎nopol/pom.xml

+4-1
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,10 @@
267267
<artifactId>maven-surefire-plugin</artifactId>
268268
<version>2.14.1</version>
269269
<configuration>
270-
<argLine>-Xms2048m -Xmx2048m -cp ${java.home.openjdk11}/jmods/jdk.jdi.jmod</argLine>
270+
<!-- java.lang.RuntimeException: java.lang.reflect.InaccessibleObjectException: Unable to make abstract boolean com.sun.tools.jdi.ReferenceTypeImpl.isAssignableTo(com.sun.jdi.ReferenceType) accessible: module jdk.jdi does not "opens com.sun.tools.jdi" to unnamed module -->
271+
<!-- java.lang.IllegalAccessError: class fr.inria.lille.repair.expression.value.Value$1 (in unnamed module @0x5577140b) cannot access class sun.reflect.generics.reflectiveObjects.NotImplementedException (in module java.base) because module java.base does not export sun.reflect.generics.reflectiveObjects to unnamed module @0x5577140b -->
272+
273+
<argLine>-Xms2048m -Xmx2048m -cp ${java.home.openjdk11}/jmods/jdk.jdi.jmod --add-opens jdk.jdi/com.sun.tools.jdi=ALL-UNNAMED --add-opens java.base/sun.reflect.generics.reflectiveObjects=ALL-UNNAMED</argLine>
271274
</configuration>
272275
</plugin>
273276
<plugin>

0 commit comments

Comments
 (0)
Please sign in to comment.