!GsmxjHfeAYLsTEQmjS:nixos.org

NixOS Matrix Discussion

292 Members
Discuss your proposals for the Matrix space here, before suggesting them in #matrix-suggestions:nixos.org98 Servers

Load older messages


SenderMessageTime
7 Jul 2024
@emilazy:matrix.orgemilyI don't think I understand why a room even needs a canonical space pointer.11:08:11
@emma:rory.gayEmma [it/its]allows discovery of the space just from the room11:09:05
@hexa:lossy.networkhexa
In reply to @emma:rory.gay

what happened in the nixos room, and presumably also the case here, is that the room -> space relation (m.space.parent state event with space id) was never updated, so the room was still pointing to the old space

to fix it, you need to set "canonical" to false in the old event, and send a new event with "canonical" set to true

manual state fuckery
16:03:36
@hexa:lossy.networkhexabecause /upgraderoom on the old space doesn't care16:03:48
@hexa:lossy.networkhexaI fault element for the broken workflow16:04:04
@hexa:lossy.networkhexamanaging a large matrix space just isn't fun16:04:22
@emma:rory.gayEmma [it/its]element isnt involved in /upgraderoom btw16:19:17
@emma:rory.gayEmma [it/its]its actually synapse that's to blame here...16:20:27
@emma:rory.gayEmma [it/its]
 POST /_matrix/client/v3/rooms/{roomId}/upgrade 
{
  "new_version": "2"
}
16:21:05
@emma:rory.gayEmma [it/its]
In reply to @hexa:lossy.network
manual state fuckery
do you want me to create a quick and dirty tool to automate the state fuckery?
16:21:44
@hexa:lossy.networkhexaFeel free16:22:12
@emma:rory.gayEmma [it/its]alright, one moment please16:22:28
@pyrox:pyrox.devPyrox [Fox/It/She] joined the room.16:56:44
@emma:conduit.rory.gayEmma [it/its] ⚡️ joined the room.17:47:14
@emma:rory.gayEmma [it/its] hey hexa, which room id is the new space? 17:57:30
@emma:rory.gayEmma [it/its]im getting very conflicting information from my server17:57:51
@emma:rory.gayEmma [it/its]!MKvhXlSTLGJUXpYuWF:nixos.org vs !brXHJeAtqliwNGqHQx:lossy.network (both of them showing up as NixOS with the blue logo on my end)17:59:42
@dgrig:erethon.comdgrigI get !brXHJeAtqliwNGqHQx:lossy.network from my HS for the new one17:59:53
@emma:rory.gayEmma [it/its]ah so the n.o one is the old one, got it18:00:09
@emma:rory.gayEmma [it/its]i dont exactly have a space to test on but i can check thhe basic logic18:01:41
@emma:rory.gayEmma [it/its]hm, kinda screwed by low moderating server count in the new space...18:07:40
@emma:rory.gayEmma [it/its]clipboard.png
Download clipboard.png
18:07:48
@emma:rory.gayEmma [it/its]alright, just taking top 10 servers in the space by member count, everything looks okay, time to build, publish and push to git :)18:14:02
@emma:rory.gayEmma [it/its]

its kinda slow because i kept the code simple, but should get the job done
shoved as much as i could into the check phase, as i cant test the execution phase
execution phase workflow:

 - iterate over children
   - skip if no permission to send m.space.parent in room
   - set canonical to false for all spaces that are set to canonical = true, if any
   - send new m.space.parent with canonical = true
18:16:41
@emma:rory.gayEmma [it/its]alright, its done18:29:28
@emma:rory.gayEmma [it/its]

deployment: https://mru.rory.gay/Tools/Room/FixCanonicalParentSpace?OldSpaceId=!MKvhXlSTLGJUXpYuWF:nixos.org&NewSpaceId=!brXHJeAtqliwNGqHQx:lossy.network

Source: https://cgit.rory.gay/matrix/tools/MatrixUtils.git/tree/MatrixUtils.Web/Pages/Tools/Room/FixCanonicalParentSpace.razor?h=main-pre-media-refactor

18:30:43
@emma:rory.gayEmma [it/its] (hexa - keep in mind this requires being in all the direct children of the new space, whether spaces or rooms, also requires having a powerlevel that can send m.space.parent, though itll skip over rooms where either of these isnt the case) 18:33:27
@emma:rory.gayEmma [it/its] https://github.com/matrix-org/matrix-spec-proposals/pull/4168
also give an upvote to this MSC, it adds this functionality at the spec level
19:03:06
@emma:rory.gayEmma [it/its]oh and just something i noticed: it seems that the nixos ws and nixos gaming rooms arent in the new space?19:04:39
@emma:rory.gayEmma [it/its](theyre in the root space on the old one)19:05:02

Show newer messages


Back to Room ListRoom Version: 6