高速公路 Python 0.9.3-3 引发与 "subscription_revocation" 相关的异常

Autobahn Python 0.9.3-3 raises exception related to "subscription_revocation"

我是 运行 Autobahn Python 0.9.3-3,我遇到了一个奇怪的错误,我不知道为什么。这似乎只发生在较新的 Autobahn Python 客户身上。有什么想法吗?

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'

我怀疑将 Autobahn 升级到 0.10.x 系列会解决这个问题,但不幸的是,有一些向后不兼容的更改似乎无法快速解决。

这是服务器中的一个错误,它似乎接受任意 "features" 并将它们用作参数。这些新功能可能是在 0.9.3 版本之后的某个时间引入的。

如果有人有同样的问题,我 created a patch 反对 0.9.3-3。

此外,如果您对某个问题投反对票,最好能解释一下您这样做的原因,这样我以后可以改进提问。