summary refs log tree commit diff
path: root/synapse/federation/federation_server.py
diff options
context:
space:
mode:
authorEric Eastwood <erice@element.io>2022-10-19 15:39:43 -0500
committerGitHub <noreply@github.com>2022-10-19 15:39:43 -0500
commit70b33965065f0e93eaba68e371896149c9405f51 (patch)
tree11c9885100cdaac0a3cf677cb1551359c5a523aa /synapse/federation/federation_server.py
parentBump types-opentracing from 2.4.7 to 2.4.10 (#14133) (diff)
downloadsynapse-70b33965065f0e93eaba68e371896149c9405f51.tar.xz
Explain `SynapseError` and `FederationError` better (#14191)
Explain `SynapseError` and `FederationError` better

Spawning from https://github.com/matrix-org/synapse/pull/13816#discussion_r993262622
Diffstat (limited to 'synapse/federation/federation_server.py')
-rw-r--r--synapse/federation/federation_server.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/synapse/federation/federation_server.py b/synapse/federation/federation_server.py
index 28097664b4..59e351595b 100644
--- a/synapse/federation/federation_server.py
+++ b/synapse/federation/federation_server.py
@@ -481,6 +481,14 @@ class FederationServer(FederationBase):
                     pdu_results[pdu.event_id] = await process_pdu(pdu)
 
         async def process_pdu(pdu: EventBase) -> JsonDict:
+            """
+            Processes a pushed PDU sent to us via a `/send` transaction
+
+            Returns:
+                JsonDict representing a "PDU Processing Result" that will be bundled up
+                with the other processed PDU's in the `/send` transaction and sent back
+                to remote homeserver.
+            """
             event_id = pdu.event_id
             with nested_logging_context(event_id):
                 try: