Debug Console

For test results, bug reports, announcements of new builds etc.

Moderators: winston, another_commander, Getafix

User avatar
Frame
---- E L I T E ----
---- E L I T E ----
Posts: 1474
Joined: Fri Mar 30, 2007 8:32 am
Location: Witchspace

Post by Frame » Fri Apr 24, 2009 8:52 pm

hmm of course, what I suspected... (wife interfering with my uptime :wink:)

trying that...
Bounty Scanner
Number 935

another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 5397
Joined: Wed Feb 28, 2007 7:54 am

Post by another_commander » Fri Apr 24, 2009 9:40 pm

I wanted to add a detail here that I have failed to mention before: In the tests I run on the work's network, the address format was not of the 192.168.xxx.xxx type. The computers I tested were carrying "normal" IP addresses, of course of the same domain. I don't think it should matter, as I think that 192.168.xxx.xxx should be also perfectly acceptable as IPs, but would like to just mention it for completeness.

User avatar
Frame
---- E L I T E ----
---- E L I T E ----
Posts: 1474
Joined: Fri Mar 30, 2007 8:32 am
Location: Witchspace

Post by Frame » Fri Apr 24, 2009 10:24 pm

I have python 2.5 installed. however I am at a loss on how to run the debug console from python.. and even where to alter the port number or where to find documentation on howto run the python debug console..

However, the exe file provided should have the ability to change ports with a commandline since ports can conflict...

I think we can conclude that the debug console does not work externally when run with Vista is either client or server side...
Bounty Scanner
Number 935

another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 5397
Joined: Wed Feb 28, 2007 7:54 am

Post by another_commander » Fri Apr 24, 2009 10:41 pm

The way I run it is:
- Ensure python binaries are in path.
- Open a command prompt inside the root debug console folder and type "python debugconsole.py".

The default port is determined in the file _protocol.py, found in the subfolder named ooliteConsoleServer.

User avatar
Micha
Commodore
Commodore
Posts: 815
Joined: Tue Sep 02, 2008 2:01 pm
Location: London, UK
Contact:

Post by Micha » Fri Apr 24, 2009 10:47 pm

Changing ports should only be needed in the very unlikely event that either some other app is already on port 8563, or, more likely, that the client and server have a firewall between them which blocks that port and you can't change the firewall.

Based on what's I've seen discussed in this thread, neither of those two cases seem to apply.

I'm fairly certain it's something odd with Vista (I saw some indications of other people having similar problems with python network programs and Vista on the internet). (Un)fortunately I don't have Vista at home and I've been too busy at work lately to look further into this.

I'm hoping to get some time next week to investigate.
The glass is twice as big as it needs to be.

User avatar
Frame
---- E L I T E ----
---- E L I T E ----
Posts: 1474
Joined: Fri Mar 30, 2007 8:32 am
Location: Witchspace

Post by Frame » Sat Apr 25, 2009 12:27 am

It is just very very odd.. I can browse both my vista systems just fine after setting up the various security settings... I can ping and trace route- without any problem. I can even browse on Vista from XP

I can even write a basic winsock program that lets me send text to and fro XP and Vista

But i cannot get debugconsole.py to run, it gives me a bunch of erros.. like this

Code: Select all

D:\Oodebug\OoDebugConsole>debugconsole.py
Traceback (most recent call last):
  File "D:\Oodebug\OoDebugConsole\DebugConsole.py", line 21, in <module>
    from ooliteConsoleServer import *
  File "C:\WorkArea\CPP\oolite-debug-console-1.0\OoDebugConsole\ooliteConsoleServer\__init__.py", line 27, in <module>
    from OoliteDebugConsoleProtocol import OoliteDebugConsoleProtocol
  File "C:\WorkArea\CPP\oolite-debug-console-1.0\OoDebugConsole\ooliteConsoleServer\OoliteDebugConsoleProtocol.py", line 10, in <module>
    from PropertyListPacketProtocol import PropertyListPacketProtocol
  File "C:\WorkArea\CPP\oolite-debug-console-1.0\OoDebugConsole\ooliteConsoleServer\PropertyListPacketProtocol.py", line 10, in <module>
    from twisted.internet.protocol import Protocol
  File "C:\Python25\lib\site-packages\twisted\internet\protocol.py", line 21, in <module>
    from twisted.internet import interfaces, error, defer
  File "C:\Python25\lib\site-packages\twisted\internet\defer.py", line 17, in <module>
    from twisted.python import log, failure, lockfile
  File "C:\Python25\lib\site-packages\twisted\python\lockfile.py", line 28, in <module>
    from win32api import OpenProcess
ImportError: No module named win32api

D:\Oodebug\OoDebugConsole>
I can read the import errors, however, not sure why I cannot locate the modules... And I have no clue what so ever, why this does not work, since i can run the obj2dattex.py tools just fine..
:cry:
Bounty Scanner
Number 935

User avatar
Micha
Commodore
Commodore
Posts: 815
Joined: Tue Sep 02, 2008 2:01 pm
Location: London, UK
Contact:

Post by Micha » Sat Apr 25, 2009 6:27 am

You need to download and install the 'twisted' python module as well before you can run the debug console. From the readme:
- OoDebugConsole_Src.zip - contains the original python code: to run the python code in windows, you need to install python, the win32 python extensions and the twisted-python library.
The glass is twice as big as it needs to be.

User avatar
Micha
Commodore
Commodore
Posts: 815
Joined: Tue Sep 02, 2008 2:01 pm
Location: London, UK
Contact:

Post by Micha » Sat Apr 25, 2009 8:20 am

Ok, I found the problem.

Basically when opening a remote connection it's possible for the code to run too fast and try to send a packet before the streams are properly initialised - which then causes the whole thing to shut down.

I've added some code into OODebugTCPConsoleClient to ensure it waits until the streams are fully open before attempting to send the 'hello' packet.
The glass is twice as big as it needs to be.

User avatar
Frame
---- E L I T E ----
---- E L I T E ----
Posts: 1474
Joined: Fri Mar 30, 2007 8:32 am
Location: Witchspace

Post by Frame » Sat Apr 25, 2009 12:42 pm

Micha wrote:Ok, I found the problem.

Basically when opening a remote connection it's possible for the code to run too fast and try to send a packet before the streams are properly initialised - which then causes the whole thing to shut down.

I've added some code into OODebugTCPConsoleClient to ensure it waits until the streams are fully open before attempting to send the 'hello' packet.
I have installed twisted, and still it does not work, you will note, i'm not getting the twisted specific errors... ;-)..

however I'm sure people here would like to see the solution.. so that it can be incorperated in the next update of the debug console
Bounty Scanner
Number 935

User avatar
Micha
Commodore
Commodore
Posts: 815
Joined: Tue Sep 02, 2008 2:01 pm
Location: London, UK
Contact:

Post by Micha » Sat Apr 25, 2009 12:44 pm

The problem is with the client code in Oolite - not with the python code in the debug console. If you can build from source, the latest trunk has a stab at the fix in it for you to try out.
The glass is twice as big as it needs to be.

zevans
---- E L I T E ----
---- E L I T E ----
Posts: 322
Joined: Mon Jul 06, 2009 11:12 pm
Location: Uncharted backwaters of the unfashionable end of the western spiral arm

Post by zevans » Fri Aug 07, 2009 5:42 pm

Did this work in the end?

I am trying to get it to work on Linux. I can run the python console successfully. (I checked it out from SVN trunk directly.) Once it is running I can telnet to the port and get a connection, and sure enough if I /quit it will close the telnet connection gracefully. So that's all working.

However I don't seem to be able to get oolite to pick up the Debug.OXP, so I don't think it is even trying to connect. I've put it in the Addons folder and all the other OXPs in there are still working... but it just doesn't seem to want to pick up Debug.OXP. I have removed "requires.plist" since that was set to 1.72.99. Or is there another version of Debug.OXP I should be using on trunk?

User avatar
Kaks
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 3009
Joined: Mon Jan 21, 2008 11:41 pm
Location: The Big Smoke

Post by Kaks » Fri Aug 07, 2009 6:05 pm

Hmm, it should work.
The console needs to be started before oolite, otherwise no connection between oolite & console is established.

In case your problems are due to debug wanting to read requires.plist: I don't seem to have any problems with the latest debug oxp from the wiki.

All I did was to change what's inside the original requires.plist to

Code: Select all

{ version = "1.73"; max_version = "1.73.99"; }
Hey, free OXPs: farsun v1.05 & tty v0.5! :0)

zevans
---- E L I T E ----
---- E L I T E ----
Posts: 322
Joined: Mon Jul 06, 2009 11:12 pm
Location: Uncharted backwaters of the unfashionable end of the western spiral arm

Post by zevans » Fri Aug 07, 2009 7:49 pm

Kaks wrote:The console needs to be started before oolite, otherwise no connection between oolite & console is established.
Yep, figured that out.

Code: Select all

{ version = "1.73"; max_version = "1.73.99"; }
Done that, it's still not picking it up. What's strange is that it's not even showing up in the OXP search paths.

I've just realised I might have compiled it with the wrong flags, I'll try that (and check out latest whilst I'm at it.)

User avatar
mandoman
---- E L I T E ----
---- E L I T E ----
Posts: 1368
Joined: Thu Apr 28, 2011 3:17 pm

Re:

Post by mandoman » Fri Sep 30, 2011 12:27 am

zevans wrote:
Kaks wrote:The console needs to be started before oolite, otherwise no connection between oolite & console is established.
Yep, figured that out.

Code: Select all

{ version = "1.73"; max_version = "1.73.99"; }
Done that, it's still not picking it up. What's strange is that it's not even showing up in the OXP search paths.

I've just realised I might have compiled it with the wrong flags, I'll try that (and check out latest whilst I'm at it.)
What happened next??? I can't get system to run the console. I get onto the Python console, but it won't find the DeBugConsole. The main message I get is that it can't find the Oolite Console Server. If anyone is still reading this, I could sure use some help.
Mandotech Industries Wiki Page.

http://wiki.alioth.net/index.php/User:Mandoman

User avatar
Kaks
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 3009
Joined: Mon Jan 21, 2008 11:41 pm
Location: The Big Smoke

Re: Debug Console

Post by Kaks » Fri Sep 30, 2011 1:27 am

inside

http://wiki.alioth.net/index.php/Oolite ... P_protocol

you can find a link to

http://svn.berlios.de/viewcvs/oolite-li ... ugConsole/

which contains all the files and directories that make up the consoles, correctly placed in relation to each other. From there you should be able to see that ooliteConsoleServer is the name of a directory containing files essential for running the console itself. It sounds like your system cannot find the ooliteConsoleServer directory.

You might not have all the files and directories required, or they might not be in the right place, relative to each other.

Hope this helps.
Hey, free OXPs: farsun v1.05 & tty v0.5! :0)

Post Reply