Reputation: 466
Running this I found off the web
#manhole
from twisted.internet import reactor
from twisted.manhole import telnet
def createShellServer( ):
print 'Creating shell server instance'
factory = telnet.ShellFactory()
port = reactor.listenTCP( 2000, factory)
factory.namespace['x'] = application
factory.namespace['s'] = s
factory.username = 'me'
factory.password = 'me'
print 'Listening on port 2000'
return port
This worked, I was able to manhole into my twisted application. But I can't up-arrow to get the previous commands, nor does it have any tab completion. I think just being able to go through the history would be a big help.
This is very new stuff to me. So I think I could be using an old method to manhole in. Any help is appreciated.
Upvotes: 2
Views: 1367
Reputation: 48335
You're using the old, deprecated, essentially unmaintained implementation of manhole.
Instead, you should be using the one included in Twisted Conch. You can find examples of its use along with the other Twisted Conch examples.
Upvotes: 1