cluster

Infrastructure files for Nordgedanken and Midnightthoughts.
git clone git://archive.git.mtrnord.blog/MTRNord/cluster.git
Log | Files | Refs | README

commit 58b7ccaff155bb017eff5da26f39186fdc806c91
parent a6a812286a3d621fdf8f59862c522c1e8b83bb2c
Author: MTRNord <MTRNord@users.noreply.github.com>
Date:   Sat,  4 Apr 2026 13:56:55 +0200

more fixes

Signed-off-by: MTRNord <MTRNord@users.noreply.github.com>

Diffstat:
Mapps/talos_cluster/matrix-backup/backup-tool/main.go | 13+++++++++++++
1 file changed, 13 insertions(+), 0 deletions(-)

diff --git a/apps/talos_cluster/matrix-backup/backup-tool/main.go b/apps/talos_cluster/matrix-backup/backup-tool/main.go @@ -1668,6 +1668,19 @@ func backupAccount(ctx context.Context, acc accountCfg) error { } dmRooms := getDMRooms(ctx, client, syncResp) + // Augment dmRooms with rooms marked as "dm" in the stored rooms list. + // This catches rooms classified as DMs by the 2-member heuristic in + // saveRoomList that aren't in m.direct (e.g. created by the other party). + if raw, err := getDecryptedAgeFromS3(ctx, acc.Prefix+"/rooms-latest.json.age"); err == nil && raw != nil { + var storedRooms []roomEntry + if json.Unmarshal(raw, &storedRooms) == nil { + for _, r := range storedRooms { + if r.Type == "dm" { + dmRooms[id.RoomID(r.RoomID)] = true + } + } + } + } for roomID, joinedRoom := range syncResp.Rooms.Join { isDM := dmRooms[roomID] if err := paginateRoom(ctx, client, roomID, acc.Prefix, isDM, joinedRoom.Timeline.PrevBatch, syncResp.NextBatch, sessions); err != nil {