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

Problem with COLT in PyCharm in Linux #3

Open
kottenator opened this issue Apr 18, 2014 · 9 comments
Open

Problem with COLT in PyCharm in Linux #3

kottenator opened this issue Apr 18, 2014 · 9 comments

Comments

@kottenator
Copy link

I work in PyCharm in Ubuntu (latest versions of both).

I have tried COLT (2.0 Beta 8) + PyCharm plugin and it doesn't work.

I get next error traceback:

Starting Live Session
Established a connection with COLT running project project
Can't start Live Session with COLT: StringIndexOutOfBoundsException: String index out of range: -1: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
    at java.lang.String.substring(String.java:1875)
    at java_lang_String$substring$5.call(Unknown Source)
    at codeOrchestra.util.FileUtils.getRelativePath(FileUtils.groovy:533)
    at codeOrchestra.util.FileUtils$getRelativePath$2.call(Unknown Source)
    at codeOrchestra.colt.js.run.JsLiveLauncher.getHttpTarget(JsLiveLauncher.groovy:182)
    at codeOrchestra.colt.js.run.JsLiveLauncher$getHttpTarget$0.callStatic(Unknown Source)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallStatic(CallSiteArray.java:53)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callStatic(AbstractCallSite.java:157)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callStatic(AbstractCallSite.java:165)
    at codeOrchestra.colt.js.run.JsLiveLauncher.launch(JsLiveLauncher.groovy:144)
    at codeOrchestra.colt.js.run.JsLiveLauncher$launch.call(Unknown Source)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:124)
    at codeOrchestra.colt.js.controller.StartLiveTaskConsole.launch(StartLiveTaskConsole.groovy:192)
    at codeOrchestra.colt.js.controller.StartLiveTaskConsole.start(StartLiveTaskConsole.groovy:168)
    at codeOrchestra.colt.js.controller.ColtJsController.startLive(ColtJsController.java:140)
    at codeOrchestra.colt.js.controller.ColtJsController$startLive.call(Unknown Source)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120)
    at codeOrchestra.colt.js.rpc.impl.ColtJsRemoteServiceImpl$1.execute(ColtJsRemoteServiceImpl.groovy:56)
    at codeOrchestra.colt.core.rpc.AbstractColtRemoteService.executeAsync(AbstractColtRemoteService.java:182)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:272)
    at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:52)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:49)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:133)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:145)
    at codeOrchestra.colt.js.rpc.impl.ColtJsRemoteServiceImpl.startLive(ColtJsRemoteServiceImpl.groovy:47)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at com.googlecode.jsonrpc4j.JsonRpcServer.invoke(JsonRpcServer.java:513)
    at com.googlecode.jsonrpc4j.JsonRpcServer.handleObject(JsonRpcServer.java:384)
    at com.googlecode.jsonrpc4j.JsonRpcServer.handleNode(JsonRpcServer.java:293)
    at com.googlecode.jsonrpc4j.JsonRpcServer.handle(JsonRpcServer.java:230)
    at com.googlecode.jsonrpc4j.JsonRpcServer.handle(JsonRpcServer.java:207)
    at codeOrchestra.colt.core.rpc.ColtRemoteServiceServlet.doPost(ColtRemoteServiceServlet.java:54)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:717)
    at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:552)
    at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1112)
    at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:479)
    at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1046)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
    at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:52)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
    at org.eclipse.jetty.server.Server.handle(Server.java:459)
    at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:281)
    at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:232)
    at org.eclipse.jetty.io.AbstractConnection$1.run(AbstractConnection.java:505)
    at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:607)
    at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:536)
    at java.lang.Thread.run(Thread.java:745)
@makc
Copy link
Contributor

makc commented Apr 18, 2014

Could you paste your xxx.colt file somewhere and also absolute path to it on your system?

@kottenator
Copy link
Author

Yes, sure: http://pastie.org/9090084

Path to this file: /home/kott/Work/Projects/undisclosed/project.colt

@dolph1n
Copy link
Member

dolph1n commented Apr 18, 2014

Download new version of COLT. This bug was fixed.
Thanks for your report!

@kottenator
Copy link
Author

I have tried again with COLT 2.0 Beta 9. Is still doesn't work, but traceback has changed :)

Established a connection with COLT running project project
Starting Live Session
Can't start Live Session with COLT: NullPointerException: Cannot invoke method command() on null object: java.lang.NullPointerException: Cannot invoke method command() on null object
    at org.codehaus.groovy.runtime.NullObject.invokeMethod(NullObject.java:77)
    at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:45)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45)
    at org.codehaus.groovy.runtime.callsite.NullCallSite.call(NullCallSite.java:32)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:112)
    at codeOrchestra.colt.js.run.JsLiveLauncher.getCommand(JsLiveLauncher.groovy:203)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:601)
    at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
    at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite$StaticMetaMethodSiteNoUnwrapNoCoerce.invoke(StaticMetaMethodSite.java:148)
    at org.codehaus.groovy.runtime.callsite.StaticMetaMethodSite.callStatic(StaticMetaMethodSite.java:99)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallStatic(CallSiteArray.java:53)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callStatic(AbstractCallSite.java:157)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callStatic(AbstractCallSite.java:165)
    at codeOrchestra.colt.js.run.JsLiveLauncher.launch(JsLiveLauncher.groovy:148)
    at codeOrchestra.colt.js.run.JsLiveLauncher$launch.call(Unknown Source)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:124)
    at codeOrchestra.colt.js.controller.StartLiveTaskConsole.launch(StartLiveTaskConsole.groovy:192)
    at codeOrchestra.colt.js.controller.StartLiveTaskConsole.start(StartLiveTaskConsole.groovy:168)
    at codeOrchestra.colt.js.controller.ColtJsController.startLive(ColtJsController.java:140)
    at codeOrchestra.colt.js.controller.ColtJsController$startLive.call(Unknown Source)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120)
    at codeOrchestra.colt.js.rpc.impl.ColtJsRemoteServiceImpl$1.execute(ColtJsRemoteServiceImpl.groovy:56)
    at codeOrchestra.colt.core.rpc.AbstractColtRemoteService.executeAsync(AbstractColtRemoteService.java:182)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:601)
    at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:272)
    at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:52)
    at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:49)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:133)
    at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:145)
    at codeOrchestra.colt.js.rpc.impl.ColtJsRemoteServiceImpl.startLive(ColtJsRemoteServiceImpl.groovy:47)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:601)
    at com.googlecode.jsonrpc4j.JsonRpcServer.invoke(JsonRpcServer.java:513)
    at com.googlecode.jsonrpc4j.JsonRpcServer.handleObject(JsonRpcServer.java:384)
    at com.googlecode.jsonrpc4j.JsonRpcServer.handleNode(JsonRpcServer.java:293)
    at com.googlecode.jsonrpc4j.JsonRpcServer.handle(JsonRpcServer.java:230)
    at com.googlecode.jsonrpc4j.JsonRpcServer.handle(JsonRpcServer.java:207)
    at codeOrchestra.colt.core.rpc.ColtRemoteServiceServlet.doPost(ColtRemoteServiceServlet.java:54)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:717)
    at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:552)
    at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1112)
    at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:479)
    at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1046)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
    at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:52)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
    at org.eclipse.jetty.server.Server.handle(Server.java:459)
    at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:281)
    at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:232)
    at org.eclipse.jetty.io.AbstractConnection$1.run(AbstractConnection.java:505)
    at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:607)
    at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:536)
    at java.lang.Thread.run(Thread.java:722)

@makc
Copy link
Contributor

makc commented Apr 21, 2014

You should be able to work around this by giving COLT explicit path to browser in "Launcher" settings section, while we investigate.

@kottenator
Copy link
Author

Thanks, explicit path helps a bit.
Now I got an error in browser (traceback: http://pastebin.com/YajaEzd5)

@makc
Copy link
Contributor

makc commented Apr 21, 2014

This exception says it could not send HEAD request for your main document URL. We send this to check URL MIME type. Does your server support this request?

@kottenator
Copy link
Author

Yes, you are right - I have login redirect on the homepage, that causes the problem

@makc
Copy link
Contributor

makc commented Apr 21, 2014

Well, we can probably fall back to GET request if HEAD fails, any way.

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

No branches or pull requests

3 participants