Bug 25636 - ability to represent partial (draft) messages sent as you type, a la iChat
Summary: ability to represent partial (draft) messages sent as you type, a la iChat
Status: RESOLVED MOVED
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-spec (show other bugs)
Version: unspecified
Hardware: Other All
: low enhancement
Assignee: Telepathy bugs list
QA Contact: Telepathy bugs list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-12-14 05:31 UTC by Mikhail Zabaluev
Modified: 2019-12-03 20:20 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Mikhail Zabaluev 2009-12-14 05:31:53 UTC
Some protocols, such as Skype or XMPP with XEP-0058, provide in-place editing for messages. Some header convention, or maybe a dedicated message type, could be specified to allow replacing messages already received with new content.

See Maemo bug:
https://bugs.maemo.org/show_bug.cgi?id=6821
Comment 1 Simon McVittie 2010-03-02 04:25:37 UTC
"WARNING: Consideration of this document has been Deferred by the XMPP Standards Foundation. Implementation of the protocol described herein is not recommended."... so I don't intend to consider XEP-0058. It doesn't seem to be the same thing requested for Skype anyway.

How does Skype actually represent these edits? The easiest thing I can think of would be to have a key in every message header indicating the message ID (message-token or the planned protocol-token), and a key in the replacement message's header 'supersedes' (or something) indicating which message to replace.

The idea of discarding the original message worries me, though: it seems as though this basically provides a way to make message history untrustworthy. We should probably specify that UIs should provide access to the old versions until/unless explicitly deleted.
Comment 2 Mikhail Zabaluev 2010-03-02 05:55:59 UTC
(In reply to comment #1)
> "WARNING: Consideration of this document has been Deferred by the XMPP
> Standards Foundation. Implementation of the protocol described herein is not
> recommended."... so I don't intend to consider XEP-0058. It doesn't seem to be
> the same thing requested for Skype anyway.
> 
> How does Skype actually represent these edits?

IIRC, it changes properties for a message object.

> The idea of discarding the original message worries me, though: it seems as
> though this basically provides a way to make message history untrustworthy. We
> should probably specify that UIs should provide access to the old versions
> until/unless explicitly deleted.

I did not demand that old message versions be deleted, it should be the client's policy. The scheme with a 'supersedes' header looks good to me. (NB: surely there must be an e-mail RFC where we can lift the header name from).
Comment 3 Will Thompson 2010-05-11 03:59:57 UTC
(In reply to comment #2)
> I did not demand that old message versions be deleted, it should be the
> client's policy. The scheme with a 'supersedes' header looks good to me. (NB:
> surely there must be an e-mail RFC where we can lift the header name from).

http://tools.ietf.org/html/draft-ietf-mailext-new-fields-06 calls it Supersedes (and one MUST NOT spell it "Supercedes" ☺). It agrees with the above discussion about leaving what to with the superseded message up to UI policy. Also, it touches upon ethics:

> In general, it is
> not illegal or unethical to change your mind, rather, it shows your
> openness to new ideas and willingness to listen to the arguments of
> other people.
Comment 4 Will Thompson 2010-05-14 09:59:57 UTC
Sjoerd has noted in real life that, in iChat's dialect of link-local XMPP, typing notifications are sent along with the partially-composed text. We could represent these by repeatedly superseding previous versions of a message!
Comment 5 Will Thompson 2010-06-24 06:58:32 UTC
So here's a spec branch which just defines a 'supersedes' header. From the spec:

  supersedes (s – Protocol_Message_Token)

    If present, this message supersedes a previous message, identified
    by its protocol-token or message-token header. The user interface
    MAY, for example, choose to replace the superseded message with this
    message, or grey out the : superseded message.

    | Skype, for example, allows the user to amend messages they have
    | already sent (to correct typos, etc.).

I think this is fine for incoming messages; for outgoing messages we need to solve bug 28740 or have special cases in the UI.
Comment 6 Simon McVittie 2010-06-29 02:35:21 UTC
review+ from me for the branch wjt/supersedes in its current state.

(In reply to comment #4)
> Sjoerd has noted in real life that, in iChat's dialect of link-local XMPP,
> typing notifications are sent along with the partially-composed text. We could
> represent these by repeatedly superseding previous versions of a message!

I wonder whether we could have some convention like:

* if a message part has 'truncated':True, and the message is superseded by one where the corresponding part is a superset, UIs SHOULD replace the earlier message silently

* if a message header has 'draft':True, UIs SHOULD indicate it as a partial message, and expect it to be superseded; if that message is superseded, UIs SHOULD replace the earlier message silently
Comment 7 Will Thompson 2010-06-29 08:27:26 UTC
(In reply to comment #6)
> review+ from me for the branch wjt/supersedes in its current state.
> 
> (In reply to comment #4)
> > Sjoerd has noted in real life that, in iChat's dialect of link-local XMPP,
> > typing notifications are sent along with the partially-composed text. We could
> > represent these by repeatedly superseding previous versions of a message!
> 
> I wonder whether we could have some convention like:
> 
> * if a message part has 'truncated':True, and the message is superseded by one
> where the corresponding part is a superset, UIs SHOULD replace the earlier
> message silently
> 
> * if a message header has 'draft':True, UIs SHOULD indicate it as a partial
> message, and expect it to be superseded; if that message is superseded, UIs
> SHOULD replace the earlier message silently

(Do we want to be able to *send* partially-composed text in typing notifications? If so, this comes back to the UI needing to know whether or not the CM supports particular headers.)
Comment 8 Will Thompson 2010-06-29 08:28:17 UTC
(In reply to comment #6)
> * if a message part has 'truncated':True, and the message is superseded by one
> where the corresponding part is a superset, UIs SHOULD replace the earlier
> message silently

So I don't know which protocol this would be for.

> * if a message header has 'draft':True, UIs SHOULD indicate it as a partial
> message, and expect it to be superseded; if that message is superseded, UIs
> SHOULD replace the earlier message silently

This makes sense for representing iChat's drafts.
Comment 9 Will Thompson 2010-06-29 09:34:05 UTC
(In reply to comment #8)
> (In reply to comment #6)
> > * if a message header has 'draft':True, UIs SHOULD indicate it as a partial
> > message, and expect it to be superseded; if that message is superseded, UIs
> > SHOULD replace the earlier message silently
> 
> This makes sense for representing iChat's drafts.

(Though we also need some way to represent the other party never actually sending the message. I guess that's just the CM emitting an empty message with supersedes set.)

((I should wait longer before hitting Submit.))
Comment 10 Will Thompson 2010-07-19 09:38:54 UTC
(In reply to comment #6)
> review+ from me for the branch wjt/supersedes in its current state.

Merged it. The remaining supersedes branch is just WIP for:

> * if a message part has 'truncated':True, and the message is superseded by one
> where the corresponding part is a superset, UIs SHOULD replace the earlier
> message silently
> 
> * if a message header has 'draft':True, UIs SHOULD indicate it as a partial
> message, and expect it to be superseded; if that message is superseded, UIs
> SHOULD replace the earlier message silently
Comment 11 Simon McVittie 2010-11-08 08:38:48 UTC
No branch here, retitling.

Blocked by bug #28740 for sending, but not for receiving.
Comment 12 GitLab Migration User 2019-12-03 20:20:45 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/telepathy/telepathy-spec/issues/57.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.