MichaelMayorov/amp-example — pull request #13 by MichaelMayorov (2013-07-08 17:36:34+00:00)
Title: Auth slave and features negotiation

[marchael@elision amp]$ python2 run.py
2013-07-08 23:36:07+0600 [-] Log opened.
2013-07-08 23:36:07+0600 [fake_slave] Starting factory
2013-07-08 23:36:07+0600 [fake_slave] fake_slave can now accept request from fake_master
2013-07-08 23:36:07+0600 [fake_master] Factory starting on 1235
2013-07-08 23:36:07+0600 [fake_master] Starting factory
2013-07-08 23:36:07+0600 [fake_master] fake_master can now accept request from fake_slave
2013-07-08 23:36:07+0600 [twisted.internet.protocol.Factory] Master connection established (HOST:IPv4Address(TCP, '127.0.0.1', 1235) PEER:IPv4Address(TCP, '127.0.0.1', 45871))
2013-07-08 23:36:07+0600 [Uninitialized] Bot connection established (HOST:IPv4Address(TCP, '127.0.0.1', 45871) PEER:IPv4Address(TCP, '127.0.0.1', 1235))
2013-07-08 23:36:07+0600 [Uninitialized] Unhandled error in Deferred:
2013-07-08 23:36:07+0600 [Uninitialized] Unhandled Error
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line 1101, in gotResult
_inlineCallbacks(r, g, deferred)
File "/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line 1045, in _inlineCallbacks
result = g.send(result)
File "/home/marchael/amp/fake_slave.py", line 91, in doConnection
master_feautures = yield sendAuthReq(ampProto)
File "/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line 1187, in unwindGenerator
return _inlineCallbacks(None, gen, Deferred())
--- ---
File "/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line 1045, in _inlineCallbacks
result = g.send(result)
File "/home/marchael/amp/fake_slave.py", line 77, in sendAuthReq
master_features = yield ampProto.callRemote(RemoteAuth, user=user, password=password, features=my_features)
File "/usr/lib/python2.7/site-packages/twisted/protocols/amp.py", line 823, in callRemote
return co._doCommand(self)
File "/usr/lib/python2.7/site-packages/twisted/protocols/amp.py", line 1779, in _doCommand
self.makeArguments(self.structured, proto),
File "/usr/lib/python2.7/site-packages/twisted/protocols/amp.py", line 1688, in makeArguments
proto)
File "/usr/lib/python2.7/site-packages/twisted/protocols/amp.py", line 2537, in _objectsToStrings
argparser.toBox(argname, strings, myObjects, proto)
File "/usr/lib/python2.7/site-packages/twisted/protocols/amp.py", line 1239, in toBox
strings[name] = self.toStringProto(obj, proto)
File "/usr/lib/python2.7/site-packages/twisted/protocols/amp.py", line 1476, in toStringProto
).serialize() for objects in inObject])
File "/usr/lib/python2.7/site-packages/twisted/protocols/amp.py", line 2536, in _objectsToStrings
for argname, argparser in arglist:
exceptions.ValueError: too many values to unpack