Describe GraalVM and your environment :
java -Xinternalversion:OpenJDK 64-Bit Server VM (11.0.6+9-jvmci-20.0-b02) for bsd-amd64 JRE (11.0.6+9-jvmci-20.0-b02), built on Jan 20 2020 14:32:51 by "graal1" with gcc 4.2.1 Compatible Apple LLVM 9.1.0 (clang-902.0.39.2)
See: https://github.com/eslint/eslint/commit/5018378131fd5190bbccca902c0cf4276ee1581a
A February 21, 2019 eslint update causes problems on GraalJS. It's idiosyncratic that it's a particular regex:
Code snippet or code repository that reproduces the issue
js -e '/^(?:[^\\]|\\[^0-7]|\\0(?![0-9]))*\\(?:[1-7]|0[0-9])/u'
Steps to reproduce the issue
js -e '/^(?:[^\\]|\\[^0-7]|\\0(?![0-9]))*\\(?:[1-7]|0[0-9])/u' in your terminal on any platform with the latest Graal.Expected behavior
Support a workaround that does not require forking all of the node ecosystem. My suggestion is an environment variable (e.g. JS_IGNORE_JONI_UNICODE_FLAG_ERROR) with a corresponding --js.ignore-joni-unicode-flag-error).
@djoooooe can you please have a look into this.
Joni does indeed support the Unicode flag:
https://github.com/jruby/joni/commit/4e3b5cc632f256304e0c143a101d8558dd7068bf
Seems like you have a recent enough version:
Maybe this is just out of date?
I tried just checking out graal and building a fix myself, but I got stuck bootstrapping Graal with Graal 11 here:
RuntimeError: Error starting javac-daemon: returncode=255
Exception during JVMCI compiler initialization:
Exception in thread "main": jdk.vm.ci.common.JVMCIError
jdk.vm.ci.common.JVMCIError: java.lang.ClassNotFoundException: org.graalvm.word.WordBase
at jdk.vm.ci.hotspot.HotSpotJVMCIRuntime.createClass(HotSpotJVMCIRuntime.java:503)
A fix for this issue is about to be merged, I will post here as soon as the fix is available.
@djoooooe Fixed? Can this be closed?
The issue has been resolved in the TRegex engine itself. Graal.js has not updated this engine yet (still using an older version). This should be resolved by the end of the week. Ultimately, the fix will land in GraalVM 20.1.0.
That's great, I'd be happy to keep testing my node work with nightlies, but I am having trouble finding them or a compilation guide for macOS.
Most helpful comment
The issue has been resolved in the TRegex engine itself. Graal.js has not updated this engine yet (still using an older version). This should be resolved by the end of the week. Ultimately, the fix will land in GraalVM 20.1.0.