-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Can't join #rust:matrix.org, violating constraint event_reference_hashes_event_id_algorithm_key #8323
Comments
Now getting spammed regularly in my logs with the same error, but for this event: Updated to 1.20.0rc4 since then. |
related: #6561 |
possibly related: #8340 |
At first I thought this might be due to malformed events given recent happenings, but it looks like this has been a problem with v1 rooms in the past (see linked issues), which #rust:matrix.org is. @richvdh notes that this is likely due to an entry in For a temporary fix, you could just remove any references to |
the question is, what could cause that? |
Well, the referenced event is in my DB (after joining and leaving
I also had no troubles rejoining I suppose looking around where synapse/synapse/storage/databases/main/events.py Lines 958 to 961 in 04cc249
It would be worthwhile to check whether the
events and event_json .
And tbh all of this happens in one transaction, so it's more likely that the data is getting removed from I wonder whether the server is somehow deleting events from OK, well this looks plausible. The synapse/synapse/storage/databases/main/purge_events.py Lines 314 to 335 in 58f61f1
Edit: nevermind, I can't read. That query is asking for Additionally, I tried leaving #rust:matrix.org on my homeserver, purging it and then rejoining. No problems. |
@MatMaul could you run the following queries for us please? select * from events where event_id = '$TBYij1X86poI2AreS6vd78aEHBvx7_Buu4Dk4ivjWrg';
select * from event_json where event_id = '$TBYij1X86poI2AreS6vd78aEHBvx7_Buu4Dk4ivjWrg'; |
@anoadragon453 no luck, not there anymore. |
AFAIK we have never had a bug in the purge code around failing to remove entries in @MatMaul do you happen still to have logs from when the failure happened? |
You mean the potential purge or the failed join ? The purge for sure not, I don't even remember doing it. The failed join that's easy to reproduce but I think I got you all the interesting logs already. |
the (first) failed join. |
It's out of reach unfortunately :/ |
yeah; I don't think we're going to get to the bottom of this one. Suggest you remove the offending rows from |
Done, closing then, thx both for having a look. |
a note for the record: one thing that can cause this is running A sql command to clean up the mess is: DELETE FROM event_reference_hashes AS refs WHERE NOT EXISTS (SELECT 1 FROM events AS es WHERE es.event_id = refs.event_id); (The above should be safe to run, though as ever when doing this sort of operation, having a backup is recommended) |
Description
I can't join #rust:matrix.org .
I am pretty certain I already joined it before and left it later on.
Steps to reproduce
Internal server error
Version information
Version:
1.20.0rc2
Install method:
Docker
Platform:
CentOS 8
The text was updated successfully, but these errors were encountered: