element-hq / element-hq/synapse

Exceptions while parsing EDUs mask the problem area of the source

Open
#3,297 0 comments 0 reactions 0 assignees View on GitHub
O-Occasional S-Tolerable T-Enhancement
Dominant language
Python
Stars
4.6k
Forks
600
Avg merge
5d 6h
Merged PRs (30d)
46

Description

This issue has been migrated from [#3297](https://github.com/matrix-org/synapse/issues/3297).

---

### Description

Received this error on dev.t2bot.io:
```
2018-05-27 20:20:21,991 - synapse.federation.transport.server - 148 - INFO - PUT-4244- Request from zemos.net
2018-05-27 20:20:21,991 - synapse.federation.transport.server - 266 - INFO - PUT-4244- Received txn DxKPPsdBfaB6LZyKgAJ6TvpMpj8Lzfp6Qs8RkmHSpp6ot from zemos.net. (PDUs: 0, EDUs: 1, failures: 0)
2018-05-27 20:20:21,996 - synapse.federation.federation_server - 643 - ERROR - PUT-4244- Failed to handle edu 'm.typing'
Traceback (most recent call last):
File "/home/travis/.synapse/local/lib/python2.7/site-packages/synapse/federation/federation_server.py", line 639, in on_edu
yield handler(origin, content)
KeyError: 'room_id'
```

Turns out the error originated from https://github.com/matrix-org/synapse/blob/3c099219e0506f81fc333ff9d27cc3af5c365a2c/synapse/handlers/typing.py#L237

Would be nice to see that in the stack trace at the least, to avoid having to reverse engineer the code.

### Version information

- **Homeserver**: dev.t2bot.io
- **Version**: 0.30.0
- **Install method**: pip
- **Platform**: Ubuntu 16.04 VM on ESXi 6.5

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.