JavaScript debugger not working for a Grails application

Hello All!
It appears that the javascript debugger doesn't work for Grails applications.

I set it up for remote debugging because Grails doesn't use HTML pages.  The first time I ran it, it created a fake page called 617.htm (617 was the last part of the URL, the id in grails context) and opened it up in an intellij tab.  I was able to set break points and re-run it and it would show some of my JavaScript objects, step through the code, etc.

Now it doesn't show that page, it opens up a tab in firefox and sometimes loads the page but the 617.htm doesn't come up in intellij and I'm not able to set up breakpoints.

Am I doing something wrong?
Thanks in advance!
-Steve

5 comments

What is happened after you select "Open Source in IDEA" in Firefox? Are there any exceptions in <idea.system.path>/log/idea.log file?

Hello All!
It appears that the javascript debugger doesn't work for Grails applications.

I set it up for remote debugging because Grails doesn't use HTML pages. The first time I ran it, it created a fake page called 617.htm (617 was the last part of the URL, the id in grails context) and opened it up in an intellij tab. I was able to set break points and re-run it and it would show so
me of my JavaScript objects, step through the code, etc.

Now it doesn't show that page, it opens up a tab in firefox and sometimes loads the page but the 617.htm doesn't come up in intellij and I'm not able to set up breakpoints.

Am I doing something wrong?
Thanks in advance!
-Steve

---
Original message URL: http://www.jetbrains.net/devnet/message/5241086#5241086



--
Nikolay Chashnikov
Software Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"

0

Where should I find the 'Open Source in IDEA' option?  I've been looking everywhere and not finding it.

0

I am getting an exception:

2009-07-02 11:16:13,123 [93231319]   INFO - nds.impl.FirefoxConnectionImpl - Address already in use: JVM_Bind
java.net.BindException: Address already in use: JVM_Bind
        at java.net.PlainSocketImpl.socketBind(Native Method)
        at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:359)
        at java.net.ServerSocket.bind(ServerSocket.java:319)
        at java.net.ServerSocket.<init>(ServerSocket.java:185)
        at java.net.ServerSocket.<init>(ServerSocket.java:97)
        at com.intellij.firefoxConnector.commands.impl.FirefoxConnectionImpl.createSocket(FirefoxConnectionImpl.java:64)

        at com.intellij.firefoxConnector.commands.impl.FirefoxConnectionImpl.open(FirefoxConnectionImpl.java:43)
        at com.intellij.firefoxConnector.debugger.FirefoxDebuggerEngine.openConnection(FirefoxDebuggerEngine.java:45)
        at com.intellij.firefoxConnector.debugger.FirefoxDebuggerEngine.openConnection(FirefoxDebuggerEngine.java:35)
        at com.intellij.javascript.debugger.execution.JavascriptDebugRunner.startSession(JavascriptDebugRunner.java:75)
        at com.intellij.javascript.debugger.execution.JavascriptDebugRunner.doExecute(JavascriptDebugRunner.java:50)
        at com.intellij.execution.runners.GenericProgramRunner$1.run(GenericProgramRunner.java:79)
        at com.intellij.execution.impl.ExecutionManagerImpl$1.run(ExecutionManagerImpl.java:12)
        at com.intellij.execution.impl.ExecutionManagerImpl.compileAndRun(ExecutionManagerImpl.java:16)
        at com.intellij.execution.runners.GenericProgramRunner.execute(GenericProgramRunner.java:103)
        at com.intellij.execution.runners.GenericProgramRunner.execute(GenericProgramRunner.java:54)
        at com.intellij.execution.runners.RestartAction.actionPerformed(RestartAction.java:10)
        at com.intellij.openapi.actionSystem.impl.ActionButton.a(ActionButton.java:99)
        at com.intellij.openapi.actionSystem.impl.ActionButton.a(ActionButton.java:33)
        at com.intellij.openapi.actionSystem.impl.ActionButton.processMouseEvent(ActionButton.java:135)
        at java.awt.Component.processEvent(Component.java:5981)
        at java.awt.Container.processEvent(Container.java:2041)
        at java.awt.Component.dispatchEventImpl(Component.java:4583)
        at java.awt.Container.dispatchEventImpl(Container.java:2099)
        at java.awt.Component.dispatchEvent(Component.java:4413)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4556)
        at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4220)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4150)
        at java.awt.Container.dispatchEventImpl(Container.java:2085)
        at java.awt.Window.dispatchEventImpl(Window.java:2475)
        at java.awt.Component.dispatchEvent(Component.java:4413)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
        at com.intellij.ide.IdeEventQueue.c(IdeEventQueue.java:239)
        at com.intellij.ide.IdeEventQueue.b(IdeEventQueue.java:63)
        at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:233)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
2009-07-02 11:16:13,124 [93231320]   INFO - nds.impl.FirefoxConnectionImpl - Address already in use: JVM_Bind
java.net.BindException: Address already in use: JVM_Bind
        at java.net.PlainSocketImpl.socketBind(Native Method)
        at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:359)
        at java.net.ServerSocket.bind(ServerSocket.java:319)
        at java.net.ServerSocket.<init>(ServerSocket.java:185)
        at java.net.ServerSocket.<init>(ServerSocket.java:97)
        at com.intellij.firefoxConnector.commands.impl.FirefoxConnectionImpl.createSocket(FirefoxConnectionImpl.java:64)

        at com.intellij.firefoxConnector.commands.impl.FirefoxConnectionImpl.open(FirefoxConnectionImpl.java:43)
        at com.intellij.firefoxConnector.debugger.FirefoxDebuggerEngine.openConnection(FirefoxDebuggerEngine.java:45)
        at com.intellij.firefoxConnector.debugger.FirefoxDebuggerEngine.openConnection(FirefoxDebuggerEngine.java:35)
        at com.intellij.javascript.debugger.execution.JavascriptDebugRunner.startSession(JavascriptDebugRunner.java:75)
        at com.intellij.javascript.debugger.execution.JavascriptDebugRunner.doExecute(JavascriptDebugRunner.java:50)
        at com.intellij.execution.runners.GenericProgramRunner$1.run(GenericProgramRunner.java:79)
        at com.intellij.execution.impl.ExecutionManagerImpl$1.run(ExecutionManagerImpl.java:12)
        at com.intellij.execution.impl.ExecutionManagerImpl.compileAndRun(ExecutionManagerImpl.java:16)
        at com.intellij.execution.runners.GenericProgramRunner.execute(GenericProgramRunner.java:103)
        at com.intellij.execution.runners.GenericProgramRunner.execute(GenericProgramRunner.java:54)
        at com.intellij.execution.runners.RestartAction.actionPerformed(RestartAction.java:10)
        at com.intellij.openapi.actionSystem.impl.ActionButton.a(ActionButton.java:99)
        at com.intellij.openapi.actionSystem.impl.ActionButton.a(ActionButton.java:33)
        at com.intellij.openapi.actionSystem.impl.ActionButton.processMouseEvent(ActionButton.java:135)
        at java.awt.Component.processEvent(Component.java:5981)
        at java.awt.Container.processEvent(Container.java:2041)
        at java.awt.Component.dispatchEventImpl(Component.java:4583)
        at java.awt.Container.dispatchEventImpl(Container.java:2099)
        at java.awt.Component.dispatchEvent(Component.java:4413)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4556)
        at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4220)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4150)
        at java.awt.Container.dispatchEventImpl(Container.java:2085)
        at java.awt.Window.dispatchEventImpl(Window.java:2475)
        at java.awt.Component.dispatchEvent(Component.java:4413)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
        at com.intellij.ide.IdeEventQueue.c(IdeEventQueue.java:239)
        at com.intellij.ide.IdeEventQueue.b(IdeEventQueue.java:63)
        at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:233)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
2009-07-02 11:17:37,965 [93316161]   INFO - ate.AbstractCommonUpdateAction - Calling refresh files after update for root
s: [FilePath[C:\projects\RIMS]]

0

I found the open source in IDEA option, it appears to only work when you have the Debugger running.  I've noticed that when it appears the file is locked and there are already a number of checkpoints that I can remove but not add.

Still not sure how to really make it work...It's stopping all over the place and not just where I want it.  It's unclear how to add checkpoints, and it's unclear how to make it only stop where I want it.  Also, when it is debugging and I hit the step over button (f8) instead of going to the next line it often exits mysteriously.  But step-into (f7) will start diggin into library files yes?

0

Please sign in to leave a comment.