Correctly handle all the places that can throw exceptions

This commit is contained in:
Erik Johnston 2015-02-12 18:17:11 +00:00
parent 92d850fc87
commit 963256638d
4 changed files with 36 additions and 14 deletions

View file

@ -411,9 +411,12 @@ class FederationServer(FederationBase):
"_handle_new_pdu getting state for %s",
pdu.room_id
)
state, auth_chain = yield self.get_state_for_room(
origin, pdu.room_id, pdu.event_id,
)
try:
state, auth_chain = yield self.get_state_for_room(
origin, pdu.room_id, pdu.event_id,
)
except:
logger.warn("Failed to get state for event: %s", pdu.event_id)
ret = yield self.handler.on_receive_pdu(
origin,