Grouped membership event splitting
With respect to this comment:
https://github.com/alphapapa/ement.el/blob/b8356417ffce3c47cb5b1e2a338d42add17d5f29/ement-room.el#L3023-L3024
I think the answer is that the grouped membership change event needs to get split. I.e.:
- Order by earliest/latest, it doesn't matter.
- After inserting the new event, check if a grouped membership event immediately before/after (when ordering by earliest/latest) "straddles" the event. If so, split it.
I don't understand what you mean. And that labels function just returns an EWOC node's data's timestamp for comparison purposes.
Right now, given a coalesced membership event G spanning timestamps T1-T4, if a new event M is inserted with a timestamp of T2, it will be placed after the coalesced membership event. Instead, G should be split into G1 spanning T1-T2 and G2 spanning T2-T4 with M getting inserted in the middle.
Sorry, I still don't understand:
- AFAIK this already works correctly. (But there may be bugs I'm unaware of, of course.)
- Given a coalesced set of events G (note they're a set of events, not an event), if a new membership event M were received whose timestamp falls in the range spanned by G, why would G be split into two sets, rather than just inserting M into that set and re-rendering it?
I mean if a new message is received, not a new membership event.
For example:
Here, I actually joined after summeremacs posted "worked for me". Specifically:
Message from Korven: 1684858155544
PurplG left: 1684858155939
Message from summeremacs: 1684858158687
Stebalien joined: 1684859990109
Gerogaga joined: 1684863110636
Ah, yes, thank you. Sorry for being dense there. Yes, I think this is a known (to me, anyway) issue, and it should indeed be fixed.