crossbario / crossbario/autobahn-python
Traceback on decorator subscribe.check_types
Open
@om26er is already working on this.
Since Feb 22, 2021.
bug
needs-investigation
PRIO HIGH
- Dominant language
- Python
- Stars
- 2.5k
- Forks
- 768
- PR merge metrics
- No merged PRs in 30d
Description
the type checking for subscribe handlers when running into a type check error
network | 2021-02-22T02:06:22+0000 [Router 112] Now processing blockchain block 31 ..
network | 2021-02-22T02:06:22+0000 [Router 112] _process_Network_MemberRegistered processing block 31 / txn 0x95f8248ede89f7981541d129aef48e3d8d44ac301a4d0c681e56a7823eff2da9 with args AttributeDict({'member': '0x2F070c2f49a59159A0346396f1139203355ACA43', 'registered': 30, 'eula': 'QmUEM5UuSUMeET2Zo8YQtDMK74Fr2SJGEyTokSYzT3uD94', 'profile': 'QmZyJwNjeDe6H7nTgbFEFFYkgefMfdJUJbF47CEiUT33Bd', 'level': 1})
network | 2021-02-22T02:06:22+0000 [Router 112] <XBRNetwork.MemberCreated>: processing event (tx_hash=0x95f8248ede89f7981541d129aef48e3d8d44ac301a4d0c681e56a7823eff2da9, block_hash=0x33451f69bacbb37e59b257ec0828a3493059ddc19874c28265901ce7784601f2) - XBR member created at address 0x2F070c2f49a59159A0346396f1139203355ACA43)
network | 2021-02-22T02:06:22+0000 [Router 112] new <MemberCreated>(member_adr=0x2f070c2f49a59159a0346396f1139203355aca43) record stored database!
network | 2021-02-22T02:06:22+0000 [Router 112] Processed blockchain block 31: processed 1 XBR events.
network | 2021-02-22T02:06:22+0000 [Router 112] Monitor blockchain iteration 2 completed: new block processed (last_processed=31, thread_id=140419837175552, period=300, cnt_xbr_events=1, cnt_blocks_success=1, cnt_blocks_error=0)
network | 2021-02-22T02:06:22+0000 [Container 219] Fatal error in component: While firing <function ApplicationSession.type_check.<locals>._type_check at 0x7f59dccd54c0> subscribed under 5863759592726804. - __name__
network | Traceback (most recent call last):
network | File "/extra/site-packages/autobahn/wamp/protocol.py", line 751, in onMessage
network | future = txaio.as_future(handler.fn, *invoke_args, **invoke_kwargs)
network | File "/usr/local/lib/python3.9/site-packages/txaio/tx.py", line 365, in as_future
network | return ensureDeferred(fun(*args, **kwargs))
network | File "/extra/site-packages/twisted/internet/defer.py", line 911, in ensureDeferred
network | return _cancellableInlineCallbacks(coro)
network | File "/extra/site-packages/twisted/internet/defer.py", line 1529, in _cancellableInlineCallbacks
network | _inlineCallbacks(None, g, status)
network | --- <exception caught here> ---
network | File "/extra/site-packages/twisted/internet/defer.py", line 1418, in _inlineCallbacks
network | result = g.send(result)
network | File "/extra/site-packages/autobahn/wamp/protocol.py", line 515, in _type_check
network | "'{}' expected type={} got={}".format(name, kind.__name__, type(arguments[name]).__name__))
network | File "/usr/local/lib/python3.9/typing.py", line 688, in __getattr__
network | raise AttributeError(attr)
network | builtins.AttributeError: __name__
network |
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.