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

Sort messages by arrival time #60

Closed
jer194 opened this issue Mar 25, 2017 · 7 comments
Closed

Sort messages by arrival time #60

jer194 opened this issue Mar 25, 2017 · 7 comments

Comments

@jer194
Copy link

jer194 commented Mar 25, 2017

I have the following problem:

The device local time of my chat partner is wrongly set (let's say 2 days in the past).
All messages arriving from him/her are then put into the chat history, however 2 days in the past.

That's really hard to find, and confusing ...

It would be good to have an option to sort messages by arrival time
(or other times like mail server delivery time).

Otherwise, I'm already a fan of Delta Chat :-), thanks for this nice initiative!

@r10s
Copy link
Member

r10s commented Mar 28, 2017

Well, sorting messages by arrival time creates other problems, eg. when several messages send (or forwarded!) do not come in in the correct order.

The easiest solution here may be to let your chat partner adjust the time.

Another idea may be to figure out a "time offset" and correct the incoming time, but, for now, I have no idea how this can be done. Any help on this issue is welcome!

@jer194
Copy link
Author

jer194 commented Mar 28, 2017

Thanks for your reply :-)

Well, sorting messages by arrival time creates other problems, eg. when several messages send
(or forwarded!) do not come in in the correct order.

Possibly (hopefully not likely).

The easiest solution here may be to let your chat partner adjust the time.

That's done meanwhile. Still, the issue could 'annoy' new Delta Chat users.

I see these lines in the mail header:


Received: ...for <DeltaChat@...>; Sat, 25 Mar 2017 10:16:04 +0100 <-- correct time on the mail server
...
Date: Sat, 25 Mar 2017 11:15:11 +0100 <-- wrong time on the device of the chat partner

Proposal:
There could be a choice in Delta Chat 'options' which of those times (on the mail server, or on the remote device) to use for sorting chat entries.

Anyway, it should not matter for most users, I agree ...

@rizzopablo
Copy link

I usually sort emails by reception order in Thunderbird, I don't really care for the datetime of the sender's device. May be Delta could sort this way too.

@r10s
Copy link
Member

r10s commented Mar 29, 2017

Well, I think in a "timelined" chat, the order of the messages is much more important.

I think, the "sending time" is more useful. Image messages as "my bus arrives in 60 minutes" which are worthless if they're timestamped on receiving eg. 30 Minutes too late as there is no internet in between.
Moreover, the "sending time" is used by Delta Chat to keep forwarded messages in order. In fact, I do some effort to realize this, see eg. https://github.com/r10s/messenger-backend/blob/master/src/mrtools.c#L1240

But I also see the problem with bad sending timestamps on the senders site, I think we can solve this issue as follows:

  • by default, use the sending time
  • use the current time as maximum
  • use the time of the last message from another user as the minimum

@jer194
Copy link
Author

jer194 commented Mar 29, 2017

use the time of the last message from another user as the minimum

Much appreciated :-)

'Another user', that includes me (the addressee) as well?
If I am in a chat, I'd expect new messages to arrive AFTER the last entry in that specific chat, no matter
when it was sent.
Chat communication is kind of asynchronous anyway (nobody can be expected to react immediately to chat messages).

Thanks again!

@r10s
Copy link
Member

r10s commented Mar 29, 2017

'Another user', that includes me (the addressee) as well?

Yes.

@r10s
Copy link
Member

r10s commented Mar 29, 2017

Okay, this is implemented and will be available in Delta Chat 0.1.24, see deltachat/deltachat-core@e8a8ee1 for details

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants