Dbgp Howto needed [message #502040] |
Fri, 04 December 2009 16:15  |
Eclipse User |
|
|
|
Dear Dltk users and developers,
I would like to find out how to use the Dbgp classes of Dltk in a minimal project. Unfortunately I am not able to understand the overall interaction of all Dltk classes (no documentation exists, does it?)
I try to do nothing more than starting a simple Dbgp server on port 9000 and then to connect with Activestate's pydbgp client (or any other client, if you have a better suggestion).
The following code continues until dbgp.waitTerminated(), and then waits forever. If I start the pydbgp script, some additional println statements in DbgpServer.workingCycle() show, that the connection is accepted and that DbgpServer.createSession() is called. But pydbgp just hangs and shows no initialization string.
I know, this is a stupid question. But how do I do something very simple, like sending the "feature_get" or "run" command to the pydbgp client???
Please help
John
Here comes my test class:
import org.eclipse.dltk.dbgp.DbgpServer;
import org.eclipse.dltk.dbgp.IDbgpServerListener;
import org.eclipse.dltk.dbgp.IDbgpSession;
import org.eclipse.dltk.dbgp.internal.DbgpDebugingEngine;
import org.eclipse.dltk.dbgp.internal.DbgpSession;
public class Main implements IDbgpServerListener {
public static void main(String[] args) throws InterruptedException {
new Main().runme(args);
}
private void runme(String[] args) throws InterruptedException {
DbgpServer dbgp=new DbgpServer(9000, 600000);
dbgp.setListener(this);
System.err.println("start");
dbgp.start();
System.err.println("started");
dbgp.waitTerminated();
System.err.println("terminated");
}
public void clientConnected(IDbgpSession session) {
System.err.println("client connected");
}
}
|
|
|
|
|
|
Re: Dbgp Howto needed [message #502152 is a reply to message #502150] |
Sun, 06 December 2009 11:31  |
Eclipse User |
|
|
|
Good point. You are right. I tested this with a Java application.
I'll try to change it into an eclipse application within the next days.
Can you recommend any documentation on this topic, how the remote debugging functions are implemented in Dltk, and how they are supposed to be used? The Dltk Wiki is not helpful.
Thanks
John
|
|
|
Powered by
FUDForum. Page generated in 0.05307 seconds