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

Prefer Chat-Group-Id header over In-Reply-To or References #5549

Closed
link2xt opened this issue May 10, 2024 · 0 comments · Fixed by #5551
Closed

Prefer Chat-Group-Id header over In-Reply-To or References #5549

link2xt opened this issue May 10, 2024 · 0 comments · Fixed by #5551
Assignees
Labels
bug Something is not working

Comments

@link2xt
Copy link
Collaborator

link2xt commented May 10, 2024

Currently Delta Chat tries to assign messages based on In-Reply-To and References before even looking at Chat-Group-Id header:

if chat_id.is_none() {
// try to assign to a chat based on In-Reply-To/References:
if let Some((new_chat_id, new_chat_id_blocked)) =
lookup_chat_by_reply(context, mime_parser, &parent, to_ids, from_id).await?
{
chat_id = Some(new_chat_id);
chat_id_blocked = new_chat_id_blocked;
}
}

If group message is incorrectly assigned to 1:1 chat, for example because it was not fully downloaded and did not reference known message from the group chat, then next replies to this message also get assigned to 1:1 chat. Workaround is to delete these messages from 1:1 chat so they cannot be looked up.

We should prefer Chat-Group-Id when it is available instead of relying on In-Reply-To to recover from this problem automatically so only a limited number of messages gets assigned to 1:1 chat.

I had this problem due to receiving a message from Delta Chat 1.44 that was not fully downloaded, had no In-Reply-To , and had References pointing to itself. After that, next replies also got assigned to 1:1 chat.

@link2xt link2xt added the bug Something is not working label May 10, 2024
@link2xt link2xt self-assigned this May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is not working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant