Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After jump to unread, timeline is out of order and showing a thread message in the main timeline #21922

Open
MadLittleMods opened this issue Apr 25, 2022 · 3 comments
Labels
A-Threads A-Timeline O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround T-Defect X-Cannot-Reproduce X-Regression

Comments

@MadLittleMods
Copy link
Contributor

MadLittleMods commented Apr 25, 2022

Steps to reproduce

  1. Go to a room with unreads
  2. Click the "Jump to first unread message." ^ up-arrow
  3. Notice that messages are now in a different order and a message that belongs in a thread is shown in the main timeline

Both screenshots are scrolled all the way to the bottom and I've highlighted the visible root message in blue and the other block of messages that gets re-ordered in red.

In the "After" screenshot, the highlighted yellow $YQLdChKbzTkNs94gEGzLzDmTMqBIvd88mmKriKf40xk event should be in the blue thread (not in the main timeline).

Uncensored screenshots in https://github.com/matrix-org/element-web-rageshakes/issues/12425

Before jump to unreads (expected) After jump to unreads (out of order)

Here is the sanitized /context request after pressing the jump to unread arrow:

GET https://matrix-client.matrix.org/_matrix/client/r0/rooms/!zKcwXhRfcrDOBEYsgu%3Amatrix.org/context/%24ftg-e7nnwEHRIth1Zxby5zufWn5bgj9t0SOg6Zb4i_k?filter=%7B%22lazy_load_members%22%3Atrue%7D

{"events_before":[{"content":{"m.relates_to":{"event_id":"$yRlWRdtNZYyXB0-c__p3eApIfLYh1UvwK97_9jofp3w","key":"👍️","rel_type":"m.annotation"}},"origin_server_ts":1650645184795,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@madlittlemods:m.org","type":"m.reaction","unsigned":{"age":263353099},"event_id":"$soRyaPXpTK24R9rC52mc6Mj4xxq9QzEz6T-cPjO0i2o","user_id":"@madlittlemods:m.org","age":263353099},{"content":{"algorithm":"m.megolm.v1.aes-sha2","ciphertext":"AwgEEpAComKucYfnG97yzk6DhcVdbGogdXU/IXRJoVSOdWI7WWvIJ9a8xfor0De7KuEWUYSXDirW+TwdLLXkaO0uAmFNJl1OEY9f8ZSABHoSfroUApHFFvDLhJ1RMzjFmh9SLAkjnb9202wASUu16KFYY1YMbJTkKuyF952LeOBZvzvdShwb7yJ7rcUnF41ASj9+RSsyBsL6LLH4TC4+mHQ1QBXMHCsOxocVTlfrv1NtvkLMuP+D0PzIsbRSzzBXXh5olb0C1RGatBWq1vSMjo/YqcOmFRZ/PrEwgEmVLQE0Q1yrgKeh1kRAWUZX2zhKjs4L/kyU2FWQwD27tC5xXd7OA3/Pntzqe3zfzLmQPjrmEoKb+0dn+H/zF6EB0kI5mny4XeFGdZ+A39hGwrcyJdXIhcE+SmL4Ypk6QSBfcSj9ChbBcSasE9oZzkFqbaomSJR+4/SpX5fOwo2z7As","device_id":"MWGOBDJKQN","sender_key":"B0FV15433XCtnynPatIdS3idvcHDuPWDinhrmk7ujhI","session_id":"FFBiVr839QE5qit5/NHMQ070UOESQf5mF9gXPIkGbOs"},"origin_server_ts":1650641433253,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@alice:m.org","type":"m.room.encrypted","unsigned":{},"event_id":"$1ewnJKOcpsT9RPLh0XNowQTiEJ6PnYeUpCetzAtKKwU","user_id":"@alice:m.org"},{"content":{"algorithm":"m.megolm.v1.aes-sha2","ciphertext":"AwgAEuACQnMR8NQlk9vOuXzrK40ReQkAl4YC8esFHSGW29hyeLdJ267yvD0jWN9xSqJVFQCINvTb68ewrtoKu/JsFNbM3hZX+MQJm9GtgoKWARbsJ9wJtRFU7aNNkGXotbBMRPtpseOJ3Qq+XP3Y3taEXvjr5JMYdZ2/eZ9KcXNcoylkBE/iXfySaZXO6fj7nYdWuA6w7qg3QJ+GlmctwWVJa0gDzShV/sxiE6dswQLFTQggWCLl6ojRb0U2dB5JaRJ/m54UnsV682CAqCtE2eHWfgS6K59hW/l0Ka8x66nELB/9q8uUYCcz/lM+VkL1XntlspkUQd78EkPbAhYaeuWOJFJt6nzLNcm5yqbB1S9rBrD++RIoyNyVz9g+Q3eTRS0ZK41ufjUNjH4LwVgsNQKGQ0dOznUy7VRIfR8+rC7WRZqXQ+/WFcHKxihPc1uYrCcCoXE1V7/PB3tY0VLHe1KQQrKEdBAql4Xj5BACOVr/lU+88YZJjE+J/Iram9wi3cld8EbsyXln3ShayKbKZUgwcDZuVJ3kaV4mXGw2s5/ze8y/cvX4BIE5uxjGDA","device_id":"BWFZFKQHPW","sender_key":"MDAiX+fHi5h6Nt4hlXBSRT9nDLurV7uzB+YBzXLALgk","session_id":"l+Ix72KxElA87VdpHdPfxkSnNBrR6X0HAknXJ2uOySs"},"origin_server_ts":1650639814049,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@bob:m.org","type":"m.room.encrypted","unsigned":{},"event_id":"$GXYpnGVKCMVIoVfripN6XIV2U1hlkrfJ1RP_cz9UBcE","user_id":"@bob:m.org"},{"content":{"algorithm":"m.megolm.v1.aes-sha2","ciphertext":"AwgCEsAEmDwbEiIAVe96fZ2qMWn28rF/PpkdZoA4HJegAxJ6lOBvj1pB1JVeNDzgoVrV1jmFy65y3vmARA/lNq3PXQCwcemz6NkoTdTzQZaWAKufsFcr7e6b84rmI2Ci2WD3+jJh4X5wnbqP+HP8JJnuYy7kvybJlE3UofIRnVCU5DTlIAUtBG+rRB2IC0gz9DcTw2UUkDDvmCEvT7jeg/+W9xIVXFZofhVQuQUaB2aop8mjHQIEViaEiMnp4WVCndulAX4wpfG8WQeXRzKAZKjc8/6OJon7escZIxYyuBJKesPWM6MEdJJ+xjY2Kc/oTlwA/tTEo0GFap5KjBbdlyxsBm+9NdVSOMD4kR61uas//VY1gqRZPvev5Ch7XxXimjDik4Uix6V3auvadwqEJ1hHIQQLDir3YdQPDvgaXZWp/GgsSzAQ002rAjMSrE9IazHQybTRyIOkxBu3JYhZCqcGPH604hGi8GG/rjJ5vWi9e3M/KOeJLn0yiuBc7Iq6O9+vClcV4vQ7U8GfLWAkUOC7VHb2VgWJuKU+OcNRWg5TJ542rSwRGUV7VMrBMFjxSacim1sHFqYVrDZMz8cwZv8m7ujYwy9BJTf1MRmcnjQrTyxm8FOXm+4bkH3P2iSqcY8YeTHlrdO1bNEWuZf2y+oCwI4zZxG5fgLasdNdr8r3UG2VaxVdwJmrs76zHrUDCVWRjvicSWBDFRivOakzzQelZQkdtwBMa2WiX/6p2O4QkEPT/Q4VyDigjo0c4u6lwKq35WhBsQZftv2slA5e6mf572RqZ+tTfKD+E9qD47nejPOAK2pnhQnFIeRvuX1jy1RVLILaDHtFsSN/TPYLXekYuu2rFNqVcXqqlN8E","device_id":"RWYRWDCWWZ","sender_key":"EfVHr8RfYpmLIAsCITeBxEhUqdgl7H2rCp4ebtSPlUQ","session_id":"yZ2zr/ljlAfG0Gk2shP8BPFgotg27A4zkHyjh2b+uoo"},"origin_server_ts":1650639229182,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@carlos:m.org","type":"m.room.encrypted","unsigned":{"age":269308712,"m.relations":{"m.annotation":{"chunk":[{"type":"m.reaction","key":"👍️","count":1}]}}},"event_id":"$yRlWRdtNZYyXB0-c__p3eApIfLYh1UvwK97_9jofp3w","user_id":"@carlos:m.org","age":269308712},{"content":{"algorithm":"m.megolm.v1.aes-sha2","ciphertext":"AwgDEtACCea6bwJoAPeUcnDC8xHnXCV1t/edEfnUobQbHEhq9GSEVb/m1LhdNr2js6qglRpcD4SIawvZhggs24YDnWR/AvSPOQEMic+UXevqy1rLasTVkWlZNyto1Cvcp/MDMo7XgbvuR+LYXPUKcV+XmP5WdrNgwAM5ar2nJ5D500CFk+Rfbg244aHYodM0fC2bfZYvyn1e4kwVdIQPkWwwRFZauQbHIpOyDsnz+B0AXnROFvJVlW+VHnbWH0wrprwTVFQFgGchjcYYCUvUM/ZaboXyQq3Jj7Mu6Gfy4bfyxbmCl26cDQrWghgPv9syRqw/ac82jGb1W8RpQjV5b6lSgG1ZV/gJhZDN3eFq95/pp3ow6pj7zQe5NS+SODvoOCFoPN7Hlcmuq2lRZTt2i07cb3IBfS05G72yfuJe5NkQOdE9zRu/2secvV9lej8lXj4sHtQfVqSkZQqovL4kQ0HQxYtqYEFvimGDLl2AG3ksN7vh+lpQoCQzcWkrVzM8MwwGH+4bjLh2372/Bf8eFSba56M/rfRehZBqAo4D","device_id":"MWGOBDJKQN","sender_key":"B0FV15433XCtnynPatIdS3idvcHDuPWDinhrmk7ujhI","session_id":"FFBiVr839QE5qit5/NHMQ070UOESQf5mF9gXPIkGbOs"},"origin_server_ts":1650638689269,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@alice:m.org","type":"m.room.encrypted","unsigned":{},"event_id":"$lWt0IzRrPuwFgOrbMe7J_YP6GcaXlnEcZRxYg_aH2wQ","user_id":"@alice:m.org"}],"event":{"content":{"algorithm":"m.megolm.v1.aes-sha2","ciphertext":"AwgAEqAGnEexenDdVdlVVdutaynBI5G5lbrWcBmGHJE8n53r/bINtNw1WRUAXzmXv6c3VvH/43GZC4UE+uXb93F2/xShmAFpQLTB3luyGXIrtWxPm38MuJv6n9upeLjn5Q0Xk+qMP5qdIaJbrB3kv2hFhyEoG/UsjwB+crj91oLiId/3kMJGBRgA23XEPohMvZ4jXWi2cRTupiW2htSQ45ksRnmyUZLqfBgi+X6/P4S9rChwEUaka3nC/T96w9gQkgQ2woU5bNsGi6RSi4/2Rv1fWlvkXrUoMGIqtlmvZXlC6U+tg1LE8/JY3+Qe97gS8PnDuhN1EOKqWSyHKRmbM7FTINlc7mZC3kBhgbhKu3AT4FldrItqsr3RViY0l6ySv6VmfWo6w0+KmNq7qMzpRqMy9d85uTuS9bPHaH1XTHstzgclRv2tsOwE4LMlm2uD1LKtsTqOXzB+PGEKE5JvgS0PbKfjM3YaYn5vF5G5qN9WJJ65a7eoHaX9rAJeWD7WkbGT+Gi9oO+Fy8LrNjT8+d9dZQ7BPPFvN1WZggVFcCRyxxpiZXlDCm5/nJRz70oOZG1N+aBCXRB4RdmdF5GbhuxweJktlRLa25bmtBuJBagcjgfH8TZEVj2b18tCwBc2+YZ34mUrxMG5MyHvoN+qafmVyjgXvzxLRXszzALAinzaje2HNS3oZ84J97v4h4VUFEGI8HzqLzZyhJ39HqNdHjrCsz3imTouln59eseM3xsc4w60eYUStgwvmk6cAbe8sX2BCW6oF86lCRdurl2APYRCgjUGoqgCAtn/8te639BcnPr7Y7RgMMJLah6uRnHi3FaH8C+GVczhA9VzPsEK/SA7WVPqriejXfLSZu7PdyymKGH7UeI5qaavINF1rFTNrbhVQHH/U9TsUFRwTG2RK+1Es6Nad4J4op7kuTloQCzUQTcgnkI7+5icXR1nRp0BEb8rBc6x52K74fgKmz1mz5mEOrLz6Y4oFk2rowZ4mffYixEEhbx3PJuxf6jewcooDbzYd5+bwOfh7XRPkNYG8Ae1UyuUvowzc4FjTem3aW0MlYsw6TLe9Yrv/DN252QPmcmD36mVq/rtRIuJTLQa9w3s3DcehUKpDdIrLw+ZycYohx6TerLVneNMsEmVvryLV1Eyz7NNt2qIR8lTLw8","device_id":"VVZPPPGBFB","m.relates_to":{"event_id":"$3L8v9DRc7U1akx4VO3T-g4kgIcVJmqZsaetqXz_OiSY","is_falling_back":true,"m.in_reply_to":{"event_id":"$YQLdChKbzTkNs94gEGzLzDmTMqBIvd88mmKriKf40xk"},"rel_type":"m.thread"},"sender_key":"Nhu0+B3JJNHr3abToRm0rYjXne20De67kH1RaNZBEAM","session_id":"pEGjpusjGOMJUFIqhCBjVvJJ91KR7rwHgTIc+2lkghI"},"origin_server_ts":1650662099354,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@matthew:m.org","type":"m.room.encrypted","unsigned":{"age":246438540},"event_id":"$ftg-e7nnwEHRIth1Zxby5zufWn5bgj9t0SOg6Zb4i_k","user_id":"@matthew:m.org","age":246438540},"events_after":[{"content":{"avatar_url":"","displayname":"","membership":"join","display_name":""},"origin_server_ts":1650873286353,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@charlie:m.org","state_key":"@charlie:m.org","type":"m.room.member","unsigned":{"replaces_state":"$cmHLwPSXnvJ0cPtHenj4FEgW0zybDt-Y4Vu9TrQWaWE","prev_content":{"avatar_url":"","displayname":"","membership":"join","display_name":""},"prev_sender":"@charlie:m.org","age":35251541},"event_id":"$M_kbEJFnI73iLq0wxHDoin2yGMXkEtD-d7bjMRcx_vo","user_id":"@charlie:m.org","age":35251541,"replaces_state":"$cmHLwPSXnvJ0cPtHenj4FEgW0zybDt-Y4Vu9TrQWaWE","prev_content":{"avatar_url":"","displayname":"","membership":"join","display_name":""}},{"content":{"avatar_url":"","displayname":"","membership":"join","display_name":""},"origin_server_ts":1650875510654,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@craig:m.org","state_key":"@craig:m.org","type":"m.room.member","unsigned":{"replaces_state":"$HzWaeXiOE5fzTOYCsfvJmnh39wK6Jdy607DLa5o_V0s","prev_content":{"avatar_url":"","displayname":"","membership":"join","display_name":""},"prev_sender":"@craig:m.org"},"event_id":"$wRsZETP7RxEa3VhgK5UrJ0tUBWCEwYzrI96L6qkCoqg","user_id":"@craig:m.org","replaces_state":"$HzWaeXiOE5fzTOYCsfvJmnh39wK6Jdy607DLa5o_V0s","prev_content":{"avatar_url":"","displayname":"","membership":"join","display_name":""}},{"content":{"avatar_url":"","displayname":"","membership":"join","display_name":""},"origin_server_ts":1650891960173,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@ivan:m.org","state_key":"@ivan:m.org","type":"m.room.member","unsigned":{"replaces_state":"$pjYe8msGL9oAeBROPiEnMhN53xKtl2sp0sOpbdtl_Xc","prev_content":{"avatar_url":"","displayname":"","membership":"join","display_name":""},"prev_sender":"@ivan:m.org","age":16577721},"event_id":"$RJtfuENAZC4hpfWNTWVvzzNebugCaFCy5bqTiZxHi-w","user_id":"@ivan:m.org","age":16577721,"replaces_state":"$pjYe8msGL9oAeBROPiEnMhN53xKtl2sp0sOpbdtl_Xc","prev_content":{"avatar_url":"","displayname":"","membership":"join","display_name":""}},{"content":{"algorithm":"m.megolm.v1.aes-sha2","ciphertext":"AwgAEsADIhNStef5IIbEIuGLqMwAJ2Jeq6FG708jqGUEKvsBsJGL3XLRDuZa6LPNO2rV94317K6HKZSD2CdPXbdry0QGnYZ1A05N4YhS5js6X7Fkf6ESrpJKvLSB+K23AtgbQFJNCeayb9It8GE9LLVcL+oNF09dDYCKfWTUoexuhALrt07LzSLBWIu7NuBkwfcSmfIjEC9jz7Zjvo4WOW+8xH1hrr/957vGzn2scG2N2sBDUldu/ev3wZZcnVWO2X1vkbAX61S/ryROnNSU3Dze3BO2wFTBV3CmOO5D/ps2ZuEIU0Eawepi0kUiiXZDyW++VEUE0OoF7zdV3AOxLvYeKiflzf3ggYq4GDd8/mYjXrwxkCpv/FDBAv1dVuf8tYw6vizmgyfpU4KOrlAq6dP3pNK7g3DhNYA4DPpK8z8+F4zyG/9KP/wXo/scJdPG6W1vvxsdD0o+KhHcT8I53bcDN/XOYYQF+b7teh+hcTp+S+ysdyk6fRKZ2B+PYkJXhmZ+Rmru0gOzNyDTKN6eDKGaMPdSvr243g9zBEOyvfMrGvx3Nt2biEZdd4ah6dQY8K5QWfwaePicfieIp/D/ssWIjOq3lILbjWxGD8W1wW/rd7hZaxZnCYNIxUIeh0m4BA2pR6iGdRSVPncO/09UZSBM1wkJfuynQdjjmdYc7LE5zY60cvKZy2xUbqqrAw","device_id":"RWYRWDCWWZ","sender_key":"EfVHr8RfYpmLIAsCITeBxEhUqdgl7H2rCp4ebtSPlUQ","session_id":"I2sgtr7+2N6niqR7FhRX8bzL+qSOyrwzjR8e1QXABlE"},"origin_server_ts":1650907327161,"room_id":"!zKcwXhRfcrDOBEYsgu:matrix.org","sender":"@carlos:m.org","type":"m.room.encrypted","unsigned":{"age":1210733},"event_id":"$3kjT8QrR0u1Lb6Ug_uE_rKy1k1769IGGkqQxnBpzqvc","user_id":"@carlos:m.org","age":1210733}],"state":["..."],"start":"t1830-2878829036_0_0_0_0_0_0_0_0","end":"t1839-2888976191_0_0_0_0_0_0_0_0"}

I do see some already in timeline log messages after jumping to the unread but not the Discarding an event logs that were symptomatic of #21531 and #21432

Event $ftg-e7nnwEHRIth1Zxby5zufWn5bgj9t0SOg6Zb4i_k already in timeline !zKcwXhRfcrDOBEYsgu:matrix.org:2022-04-23T03:33:48.796Z
12:48:14.575 rageshake.ts:72 Event $YQLdChKbzTkNs94gEGzLzDmTMqBIvd88mmKriKf40xk already in timeline !zKcwXhRfcrDOBEYsgu:matrix.org:2022-04-23T03:33:48.796Z
12:48:14.575 rageshake.ts:72 Event $JnVifs8q7z30S158ZQUwqcqG_iPzEYplBzSj52wlB2Q already in timeline !zKcwXhRfcrDOBEYsgu:matrix.org:2022-04-23T03:33:48.796Z
12:48:14.575 rageshake.ts:72 Event $3L8v9DRc7U1akx4VO3T-g4kgIcVJmqZsaetqXz_OiSY already in timeline !zKcwXhRfcrDOBEYsgu:matrix.org:2022-04-23T03:33:48.796Z

Outcome

What did you expect?

Messages appear in the same order regardless of if I jump to unread.

Threaded messages are not shown in the main timeline

Operating system

Windows 10

Browser information

Chrome version 100.0.4896.127

URL for webapp

https://develop.element.io/

Application version

Element version: 2ffb3a1-react-f85e178fc18b-js-ac08e5241079 Olm version: 3.2.8

Homeserver

matrix.org

Will you send logs?

Yes, https://github.com/matrix-org/element-web-rageshakes/issues/12425

@MadLittleMods MadLittleMods added T-Defect S-Major Severely degrades major functionality or product features, with no satisfactory workaround A-Timeline O-Occasional Affects or can be seen by some users regularly or most users rarely A-Threads Z-MadLittleMods labels Apr 25, 2022
@MadLittleMods
Copy link
Contributor Author

MadLittleMods commented Apr 26, 2022

Here is another reproduction except there is more messages this time so not everything is in view. But you can see that the red chunk is above the yellow root thread which should be way back in the scrollback. No thread messages showing this time either.

Before jump to unreads (expected) After jump to unreads (out of order)
Element version: 7c326f49d9f9-react-e718242912e2-js-3649cf46d343
Olm version: 3.2.8

@MadLittleMods
Copy link
Contributor Author

Reproduced the same situation as the comment above again except this time with all of the ScrollPanel and TimelinePanel debug logging in place so the logs should be a lot more insightful around why this is happening 🤞

Logs along with uncensored screenshot and /context request: https://github.com/matrix-org/element-web-rageshakes/issues/12839

@germain-gg
Copy link
Contributor

I believe matrix-org/matrix-spec-proposals#3874 should help us address this issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Threads A-Timeline O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround T-Defect X-Cannot-Reproduce X-Regression
Projects
None yet
Development

No branches or pull requests

3 participants