From 69111355d0293a85d5a7479f514a559180dea1a4 Mon Sep 17 00:00:00 2001 From: Neil Alexander Date: Tue, 14 Dec 2021 12:38:47 +0000 Subject: [PATCH] Logging --- roomserver/internal/input/input_events.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/roomserver/internal/input/input_events.go b/roomserver/internal/input/input_events.go index c38de7368..52b1a7025 100644 --- a/roomserver/internal/input/input_events.go +++ b/roomserver/internal/input/input_events.go @@ -273,6 +273,8 @@ func (r *Inputer) checkForMissingAuthEvents( } if len(unknown) > 0 { + logrus.Printf("XXX: There are %d missing auth events", len(unknown)) + serverReq := &fedapi.QueryJoinedHostServerNamesInRoomRequest{ RoomID: event.RoomID(), } @@ -281,6 +283,8 @@ func (r *Inputer) checkForMissingAuthEvents( return fmt.Errorf("r.FSAPI.QueryJoinedHostServerNamesInRoom: %w", err) } + logrus.Printf("XXX: Asking servers %+v", serverRes.ServerNames) + var res gomatrixserverlib.RespEventAuth var found bool for _, serverName := range serverRes.ServerNames { @@ -289,9 +293,12 @@ func (r *Inputer) checkForMissingAuthEvents( logrus.WithError(err).Warnf("Failed to get event auth from federation for %q: %s", event.EventID(), err) continue } + logrus.Printf("XXX: Server %q provided us with %d auth events", serverName, len(res.AuthEvents)) found = true + break } if !found { + logrus.Printf("XXX: None of the %d servers provided us with auth events", len(serverRes.ServerNames)) return fmt.Errorf("no servers provided event auth") }