Skip to content
Advertisement

Autobahn Python 0.9.3-3 raises exception related to “subscription_revocation”

I’m running Autobahn Python 0.9.3-3 and am getting a strange error and I can’t work out why. This only seems to be happening with newer Autobahn Python clients. Any ideas?

2015-03-30 04:37:52+0000 [-] Starting factory <__main__.SocketServerFactory instance at 0x7fc830586b90>
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1] Traceback (most recent call last):
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1]   File "/opt/AutobahnPython/autobahn/autobahn/wamp/websocket.py", line 88, in onMessage
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1]     for msg in self._serializer.unserialize(payload, isBinary):
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1]   File "/opt/AutobahnPython/autobahn/autobahn/wamp/serializer.py", line 129, in unserialize
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1]     msg = Klass.parse(raw_msg)
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1]   File "/opt/AutobahnPython/autobahn/autobahn/wamp/message.py", line 285, in parse
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1]     role_features = role_cls(**details_role[u'features'])
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1]   File "/opt/AutobahnPython/autobahn/autobahn/wamp/role.py", line 104, in __init__
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1]     RoleCommonPubSubFeatures.__init__(self, **kwargs)
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1] TypeError: __init__() got an unexpected keyword argument 'subscription_revocation'
2015-03-30 04:37:56+0000 [WampWebSocketServerProtocol,0,172.17.42.1] Failing WAMP-over-WebSocket transport: code = 1011, reason = 'WAMP Internal Error (__init__() got an unexpected keyword argument 'subscription_revocation')'
2015-03-30 04:37:56+0000 [-] WAMP-over-WebSocket transport lost: wasClean = True, code = 1000, reason = 'None'

I suspect upgrading Autobahn to the 0.10.x series will fix this, but unfortunately there are some backwards incompatible changes that don’t appear quick to resolve.

Advertisement

Answer

This was a bug in the server where it appeared to accept arbitrary “features” and used them as arguments. These new features were probably introduced some time after version 0.9.3.

I’ve created a patch against 0.9.3-3 if anyone has the same issue.

3 People found this is helpful
Advertisement