I'm attempting to run the Kotlin REPL on my windows 10 machine, from the command line. I am receiving a java.lang.NoClassDefFoundError: org/jline/reader/LineReaderBuilder exception when running the command kotlinc
I have IntelliJ Ultimate 2019.1.3 installed, with the Kotlin plugin. I have the Kotlin standalone compiler also installed and I've added that location to my system path. I've tried to run the command from the standalone directory: "C:/Tools/kotlinc/bin" but no difference.
OS Name: Microsoft Windows 10 Enterprise
Version 10.0.16299 Build 16299
Kotlin version 1.3.40-release-123 (JRE 1.8.0_131-b11)
java version "1.8.0_131"
I expect the REPL to start without an exception. What could be causing the exception?
Thank you all!
It looks like that was a bug and it has been fixed with Kotlin plugin & kotlinc version 1.3.41 (released today).
Related
I try to get the JetBrains IDE Support 2.0.9 running with my IDEA 2017.1.4.
IDEA says that it waits for connection from the Support Extension on IDE port 63342.
The problem I found is that the Chrome Plugin gets an 404 error when it tries to create the WebSocket Connection
Ready to load system latest for IntelliJ IDEA 2017.1.4 (127.0.0.1:63342)
logging.kt:43 System latest loaded for IntelliJ IDEA 2017.1.4 (127.0.0.1:63342)
socket.kt:50 WebSocket connection to 'ws://127.0.0.1:63342/jsonRpc?v=2.0.9&f=Mozilla%2F5.0%20(Windows%20NT%206.1%3B%20Win64%3B%20x64)%20AppleWebKit%2F537.36%20(KHTML%2C%20like%20Gecko)%20Chrome%2F59.0.3071.115%20Safari%2F537.36' failed: Error during WebSocket handshake: Unexpected response code: 404
value # socket.kt:50
value # socket.kt:69
value # platform.kt:32
value # chrome.kt:23
$f9 # console.kt:57
$fb # bootstrap.kt:157
$fc # bootstrap.kt:174
logging.kt:51 onerror [object Event]
value # logging.kt:51
$f4 # socket.kt:92
I try to find some solution via Google but the keyword "jsonRpc" polluted the results with no connections to IDEA that helped.
Further informations:
Network has no access to Internet
Chrome Version 59.0.3071.115 64-Bit
OS: Win 7 64bit
IDEA 2017.1.4
Plugin 2.0.9
Installed IDEA Plugins (External Ones)
Atlassian Connector for IntelliJ IDE (Version 3.0.16,SVN:1504201227)
CodeReview for IntelliJ IDEA (Version 0.5.4)
Grep Console (Version 5.9.141.000)
IDETalk (Version 145.258.11)
Lombok Plugin (Version 0.14.16)
SonarLint (Version 2.3.2)
String Manipulatio (Version 4.2.132.445)
Maven Helper (Version 3.1.138.1503)
I know that some could be very old but we don't have Internet Access at our Workstation to se updates or even update very good
PS: is there some kind of documentation what all the WebInterface URLs in IDEA are/how the Interface is constructed?
After adding the Test Fairy 1.5.0 SDK and using XCODE 7.0.1, getting many warnings like
while processing /Users/jefforthober/Dev/KidMix/KidMixiOS/KidMixCommon/TestFairy/libTestFairy.a(TFImageUtils.o):
warning: Could not resolve external type c:objc(cs)UIView
while processing /Users/jefforthober/Dev/KidMix/KidMixiOS/KidMixCommon/TestFairy/libTestFairy.a(TFGestureRecognizer.o):
warning: /var/folders/my/m6ynh3bn6tq06h7xr3js0z7r0000gn/C/org.llvm.clang.travis/ModuleCache/1Z8KETWXX2FXQ/UIKit-1V5UHAPTOD24G.pcm: No such file or directory
while processing /Users/jefforthober/Dev/KidMix/KidMixiOS/KidMixCommon/TestFairy/libTestFairy.a(TFGestureRecognizer.o):
The problem is solved with TestFairy iOS SDK 1.7.4
Just upgrade to the latest version.
http://docs.testfairy.com/iOS_SDK/Integrating_iOS_SDK.html
I've installed jruby 1.7.4 and every time an program is executed I get the following error:
Java HotSpot(TM) 64-Bit Server VM warning: You have loaded library /opt/jruby/lib/native/arm- Linux/libjffi-1.2.so which might have disabled stack guard. The VM will try to fix the stack guard now.
It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'.
I tried to disable the error message with the "execstack -c /opt/jruby/lib/native/arm- Linux/libjffi-1.2.so" but the error keeps creeping in.
How can disable/fix this error message?
simply install a somehow recent of JRuby 1.7.x ... that is e.g. 1.7.17 at the moment
I used a little Jruby script from http://www.javaworld.com/javaworld/jw-07-2006/jw-0717-ruby.html to test invokedynamic:
class ADuck
def quack()
puts "quack A";
end
end
class BDuck
def quack()
puts "quack B";
end
end
def quack_it(duck)
duck.quack
end
a = ADuck.new
b = BDuck.new
quack_it(a)
quack_it(b)
But when I compile in with JRuby to Java classfiles and then try to execute it I get the following exception:
Java HotSpot(TM) 64-Bit Server VM warning: Use -XX:+UnlockDiagnosticVMOptions be
fore EnableInvokeDynamic flag
Exception in thread "main" java.lang.ClassCastException: java.lang.Object cannot
be cast to java.lang.invoke.SwitchPoint
at org.jruby.runtime.invokedynamic.InvokeDynamicSupport.constantFallback
(InvokeDynamicSupport.java:659)
at duck_typing.__file__(duck_typing.rb:22)
at duck_typing.load(duck_typing.rb)
at duck_typing.main(duck_typing.rb)
My system: JDK 1.7.0_09 64bit on Windows 7 64bit, JRuby 1.7.2
Used commandlines:
jruby -Xcompile.invokedynamic=true -S jrubyc duck_typing.rb
java -XX:+UnlockExperimentalVMOptions -XX:+EnableInvokeDynamic -cp .;jruby-complete-1.7.2.jar duck_typing
A while ago I tested it on linux machine with same results and on Windows jdk8.
With JDK8 it worked, but gave me problems using the classfiles in another project.
Has anyone a idee how to fix it?
How can I use JRuby with indy on Java 7?
Except for the JRuby convenience parameter --server, all JVM runtime
parameters use the -J option, followed by the specific JVM setting.
For example:
Heap space settings: jruby -J-X
JRuby runtime settings: jruby -J-D
All the settings described in the following sections are JVM settings.
https://github.com/jruby/jruby/wiki/PerformanceTuning
try this instead
jruby -J-Xcompile.invokedynamic=true -S jrubyc duck_typing.rb
I deploy a war made with "grails war" to a jetty server.
As far as I can determine, Grails builds with Sun JDK 1.6.0_17-b04 and jetty runs on Sun JDK 1.6.0.16 (both on linux).
2010-08-18 07:33:47.018:WARN::Nested in org.springframework.beans.factory.access.BootstrapException: Error executing bootstraps; nested exception is org.codehaus.groovy.runtime.InvokerInvocationException:
java.lang.IncompatibleClassChangeError: the number of constructors during runtime and compile time for java.lang.ClassLoader do not match. Expected 3 but got 2:
java.lang.IncompatibleClassChangeError: the number of constructors during runtime and compile time for java.lang.ClassLoader do not match. Expected 3 but got 2
at grails.plugin.scopedproxy.AlwaysReloadableSmartClassLoader.<init>(AlwaysReloadableSmartClassLoader.groovy:28)
at grails.plugin.scopedproxy.ScopedProxyUtils.wrapInSmartClassLoader(ScopedProxyUtils.groovy:154)
How can this problem be solved or debugged further?
Run grails clean before you run grails war.
According to another post, Groovy code that uses exceptions that was compiled with a version of Java prior to 7 is not compatible with Java 7.
More information can be found here.
You are probably running into a JAR conflict. Namely your build environment is using one jar, and runtime (Jetty) is using a conflicting jar. This used to often happen with various XML parsing stacks.
Try looking at the Jars used by jetty and compare them to the ones in your project.