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

Only create DM room when first message is sent #14736

Closed
turt2live opened this issue Jul 23, 2020 · 19 comments · Fixed by matrix-org/matrix-react-sdk#8612
Closed

Only create DM room when first message is sent #14736

turt2live opened this issue Jul 23, 2020 · 19 comments · Fixed by matrix-org/matrix-react-sdk#8612
Assignees
Labels
A-DMs O-Frequent Affects or can be seen by most users regularly or impacts most users' first experience S-Tolerable Low/no impact on users Sponsored T-Enhancement Z-FTUE

Comments

@turt2live
Copy link
Member

turt2live commented Jul 23, 2020

Instead of eagerly creating a room, only create the room when a message is sent. This could also help us use the room list search as a way to start DMs if we wanted

@t3chguy
Copy link
Member

t3chguy commented Jul 23, 2020

I am certain this is a dup but cannot find it :'(

@jakewb-b
Copy link

Since my issue was closed as a duplicate, copying the specific requirement here, and changing title to be a little more descriptive.

  • As a user sending a DM to someone I do not have an active DM conversation with
  • I want the room to be created only when I first send a message (text, image or voice)
  • So that the recipient receives the invite only when there is a message in the room

@jakewb-b jakewb-b changed the title We can improve the DM experience to be more lazy Only create DM room when first message is sent Sep 16, 2021
@gaelledel
Copy link

gaelledel commented Jan 4, 2022

@turt2live @t3chguy @giomfo
I am updating the behaviour for Starting a DM. What changes is the mentioned above: We're only sending the invitation when user A (sender) sends a message to user B (receiver).
I would also be keen to allow message previews for user B when receiving an invitation see below.
Screenshot 2022-01-04 at 11 16 22

Is this possible? For encrypted rooms, we could have the first few words with the rest encrypted.
This would help minimise spam requests and make user B more confident in starting the DM.

Thanks

@gaelledel
Copy link

@MurzNN
Copy link
Contributor

MurzNN commented Jan 4, 2022

@gaelledel maybe also add a "Mutual rooms with this user" block, which will show list of rooms (and spaces?) where both of users (current user and invite owner) are members?

This should be very useful to understand from which source this person founds you. Because very often I receive invites from strange persons, and before accepting - need to manually research in which rooms/spaces I see them before.

@turt2live
Copy link
Member Author

The message preview is difficult, but we do have a concept of "invite reason" we could display.

I'd be worried that the first message preview isn't all that helpful (and easy to bypass for spamming), so would encourage us to look into peeking support on invited rooms instead - a much harder technical feat.

@gaelledel
Copy link

@MurzNN Yes, that's a good point thank you. Unsure if we'd be able to pull this info at the stage of the invite though. @turt2live might know actually.

Regarding:

The message preview is difficult, but we do have a concept of "invite reason" we could display.

I'd be worried that the first message preview isn't all that helpful (and easy to bypass for spamming), so would encourage us to look into peeking support on invited rooms instead - a much harder technical feat.

Thanks for the feedback. Could you expand on the "invite reason" concept?

@t3chguy
Copy link
Member

t3chguy commented Jan 4, 2022

The mutual rooms suggestion is already WIP matrix-org/matrix-react-sdk#4897

@gaelledel
Copy link

Good to know indeed thanks @t3chguy

@kittykat
Copy link
Contributor

@gaelledel would it make sense to change the behaviour already to create room on first message while we wait for mutual rooms and figure out how to do the message preview/peeking?

@gaelledel
Copy link

Yes this is the plan. The designs have changed since to accommodate for this. We will be showing common rooms and spaces instead.

@giomfo
Copy link
Member

giomfo commented Mar 18, 2022

The same request change has been described in android-element and ios-element.
We will use this issue to track the change in Element-web

When the user wants to select someone to DM, the current UI is:
image

  • When the user presses 'Go', after selecting Corey:
    • if there is already a DM with Corey : open the DM
    • if there isn't DM with Corey, instead of the room being created (and Corey being invited to an empty room), The user sees the following interface with the composer (the room has not been created).

Screenshot 2022-03-18 at 15 49 32

  • If the user doesn’t send a message ( = navigate to another room) no room is created. The user has to start again.
  • If the user does send a message, then the DM room is created by inviting Corey and the message is sent. The room exists and is displayed in the people section

Screenshot 2022-03-18 at 15 51 10

Additional Requests

  • If several contacts have been selected in the picker before clicking on the Go option. The interface is adapte. I provide here the mobile design for this use case:

image

  • If the user selects at least one email address in the selected contact list, the resulting DM will be unencrypted. We have to hide the following tile in the interface

image

@erkinalp
Copy link
Contributor

Multiple rooms with same members are possible in the protocol level, hence Element should not make this impossible.

@turt2live
Copy link
Member Author

@erkinalp that's a different issue.

@ShadowJonathan
Copy link
Contributor

(matrix-org/matrix-react-sdk#8612 seems to be relevant to this effort.)

@giomfo
Copy link
Member

giomfo commented Jun 17, 2022

@weeman1337 FYI we have to apply the same process (create DM only on first message) when the end user decides to start a DM from the room member details screen (by clicking on "Message" option), whereas the DM is not existing yet.
image

@weeman1337
Copy link
Contributor

weeman1337 commented Jul 7, 2022

Plan for community testing session:

Setup:

  • You should have at least two Matrix accounts available and logged in at the same time.
  • Leave the DM room(s) with all accounts after each test.
  • To perform the e-mail test cases some spare e-mail addresses or a „+“ alias capable account is required.
    If you don't have those you can skip the e-mail tests.
Title Description
Note The following tests should target one DM partner. The expected result is that the partner got the invite, sees the message after he joined and that the room is end-to-end encrypted.
Start DM with text message Start a DM by typing a simple text message
Start DM with one attachment Start a DM by sending a file using the attachment button in message composer
Start DM with multiple attachments Start a DM by sending multiple files using the attachment button in message composer
Start DM with attachment from clipboard Start a DM by sending a file pasted from the clipboard
Start DM with one attachment from drag & drop Start a DM by sending one file pasted to the room
Start DM with multiple attachments from drag & drop Start a DM by sending multiple files dragged to the room
Start DM with poll Start a DM by sending a poll
Start DM with sticker Start a DM by sending a sticker
Start DM with location share Start a DM by sharing your location
Start DM with live location share Start a DM by sharing your live location
Start DM with voice message Start a DM by sending a voice message
Note The following tests can be done by sending text message
Start DM from „People +“ Start a DM using the „+“ from the sidebar people section
Start DM from room member list Start a DM using the „Message“ button in a room member list
Start DM from spotlight search Start a DM by searching a user in the spotlight search (Ctrl + K or click into the top left search field)
Start DM with two MXID users Start a DM by inviting two users having a matrix account
Start DM with e-mail user Start a DM by inviting an e-mail address. After the other side joined the room should not be encrypted.
Start DM with one MXID user and one e-mail user Start a DM by inviting two users: one with MXID and another by e-mail. After all have joined the room should not be encrypted.
Perform a verification without having a DM room Let two users, which don't have a DM yet, verify each other. This can be triggered from a member list of a room that both have joined.

@Half-Shot
Copy link
Member

Half-Shot commented Jul 25, 2022

There is a slight issue here that it's not safe to assume that just because you can start a DM with someone, the DM will be permitted by the remote side. E.g.

  • Lots of puppeted bridges will leave a DM if the Matrix user isn't connected to the bridged service (i.e. you're not logged into Slack, you cannot DM slack users)
  • Some users will have their own mechanisms for automatically blocking DMs for users they do not already know.

This means that with this features, users could end up possibly typing a fairly lengthy message only to be told they cannot talk to the remote user. There is also a slightly more problematic side in that it's very likely some services will have race conditions between a invite and a message being handled concurrently (though, I am not sure how the proposed implementation works -> maybe messages are only sent upon join?)

This doesn't mean the feature isn't a good one, but it will degrade the experience for some users.

@giomfo
Copy link
Member

giomfo commented Jul 26, 2022

@Half-Shot the potential race conditions problematic between the invite and the message has been taken into account by the implementation

About your first point, the contact picker should be improved to prevent you from selecting people you could not talk to. Can you provide some criteria/conditions to filter the contacts list?

su-ex added a commit to SchildiChat/element-desktop that referenced this issue Aug 22, 2022
* Improve auth aria attributes and semantics ([\#22948](element-hq/element-web#22948)).
* Device manager - New device tile info design ([\#9122](matrix-org/matrix-react-sdk#9122)). Contributed by @kerryarchibald.
* Device manager generic settings subsection component ([\#9147](matrix-org/matrix-react-sdk#9147)). Contributed by @kerryarchibald.
* Migrate the hidden read receipts flag to new "send read receipts" option ([\#9141](matrix-org/matrix-react-sdk#9141)).
* Live location sharing - share location at most every 5 seconds ([\#9148](matrix-org/matrix-react-sdk#9148)). Contributed by @kerryarchibald.
* Increase max length of voice messages to 15m ([\#9133](matrix-org/matrix-react-sdk#9133)). Fixes element-hq/element-web#18620.
* Move pin drop out of labs ([\#9135](matrix-org/matrix-react-sdk#9135)).
* Start DM on first message ([\#8612](matrix-org/matrix-react-sdk#8612)). Fixes element-hq/element-web#14736.
* Remove "Add Space" button from RoomListHeader when user cannot create spaces ([\#9129](matrix-org/matrix-react-sdk#9129)).
* The Welcome Home Screen: Dedicated Download Apps Dialog ([\#9120](matrix-org/matrix-react-sdk#9120)). Fixes element-hq/element-web#22921. Contributed by @justjanne.
* The Welcome Home Screen: "Submit Feedback" pane ([\#9090](matrix-org/matrix-react-sdk#9090)). Fixes element-hq/element-web#22918. Contributed by @justjanne.
* New User Onboarding Task List ([\#9083](matrix-org/matrix-react-sdk#9083)). Fixes element-hq/element-web#22919. Contributed by @justjanne.
* Add support for disabling spell checking ([\#8604](matrix-org/matrix-react-sdk#8604)). Fixes element-hq/element-web#21901.
* Live location share - leave maximised map open when beacons expire ([\#9098](matrix-org/matrix-react-sdk#9098)). Contributed by @kerryarchibald.
* Some slash-commands (`/myroomnick`) have temporarily been disabled before the first message in a DM is sent. ([\#9193](matrix-org/matrix-react-sdk#9193)).
* Use stable reference for active tab in tabbedView ([\#9145](matrix-org/matrix-react-sdk#9145)). Contributed by @kerryarchibald.
* Fix pillification sometimes doubling up ([\#9152](matrix-org/matrix-react-sdk#9152)). Fixes element-hq/element-web#23036.
* Fix composer padding ([\#9137](matrix-org/matrix-react-sdk#9137)). Fixes element-hq/element-web#22992.
* Fix highlights not being applied to plaintext messages ([\#9126](matrix-org/matrix-react-sdk#9126)). Fixes element-hq/element-web#22787.
* Fix dismissing edit composer when change was undone ([\#9109](matrix-org/matrix-react-sdk#9109)). Fixes element-hq/element-web#22932.
* 1-to-1 DM rooms with bots now act like DM rooms instead of multi-user-rooms before ([\#9124](matrix-org/matrix-react-sdk#9124)). Fixes element-hq/element-web#22894.
* Apply inline start padding to selected lines on modern layout only ([\#9006](matrix-org/matrix-react-sdk#9006)). Fixes element-hq/element-web#22768. Contributed by @luixxiul.
* Peek into world-readable rooms from spotlight ([\#9115](matrix-org/matrix-react-sdk#9115)). Fixes element-hq/element-web#22862.
* Use default styling on nested numbered lists due to MD being sensitive ([\#9110](matrix-org/matrix-react-sdk#9110)). Fixes element-hq/element-web#22935.
* Fix replying using chat effect commands ([\#9101](matrix-org/matrix-react-sdk#9101)). Fixes element-hq/element-web#22824.
su-ex added a commit to SchildiChat/element-web that referenced this issue Aug 22, 2022
* Improve auth aria attributes and semantics ([\element-hq#22948](element-hq#22948)).
* Device manager - New device tile info design ([\element-hq#9122](matrix-org/matrix-react-sdk#9122)). Contributed by @kerryarchibald.
* Device manager generic settings subsection component ([\element-hq#9147](matrix-org/matrix-react-sdk#9147)). Contributed by @kerryarchibald.
* Migrate the hidden read receipts flag to new "send read receipts" option ([\element-hq#9141](matrix-org/matrix-react-sdk#9141)).
* Live location sharing - share location at most every 5 seconds ([\element-hq#9148](matrix-org/matrix-react-sdk#9148)). Contributed by @kerryarchibald.
* Increase max length of voice messages to 15m ([\element-hq#9133](matrix-org/matrix-react-sdk#9133)). Fixes element-hq#18620.
* Move pin drop out of labs ([\element-hq#9135](matrix-org/matrix-react-sdk#9135)).
* Start DM on first message ([\element-hq#8612](matrix-org/matrix-react-sdk#8612)). Fixes element-hq#14736.
* Remove "Add Space" button from RoomListHeader when user cannot create spaces ([\element-hq#9129](matrix-org/matrix-react-sdk#9129)).
* The Welcome Home Screen: Dedicated Download Apps Dialog ([\element-hq#9120](matrix-org/matrix-react-sdk#9120)). Fixes element-hq#22921. Contributed by @justjanne.
* The Welcome Home Screen: "Submit Feedback" pane ([\element-hq#9090](matrix-org/matrix-react-sdk#9090)). Fixes element-hq#22918. Contributed by @justjanne.
* New User Onboarding Task List ([\element-hq#9083](matrix-org/matrix-react-sdk#9083)). Fixes element-hq#22919. Contributed by @justjanne.
* Add support for disabling spell checking ([\element-hq#8604](matrix-org/matrix-react-sdk#8604)). Fixes element-hq#21901.
* Live location share - leave maximised map open when beacons expire ([\element-hq#9098](matrix-org/matrix-react-sdk#9098)). Contributed by @kerryarchibald.
* Some slash-commands (`/myroomnick`) have temporarily been disabled before the first message in a DM is sent. ([\element-hq#9193](matrix-org/matrix-react-sdk#9193)).
* Use stable reference for active tab in tabbedView ([\#9145](matrix-org/matrix-react-sdk#9145)). Contributed by @kerryarchibald.
* Fix pillification sometimes doubling up ([\element-hq#9152](matrix-org/matrix-react-sdk#9152)). Fixes element-hq#23036.
* Fix highlights not being applied to plaintext messages ([\element-hq#9126](matrix-org/matrix-react-sdk#9126)). Fixes element-hq#22787.
* Fix dismissing edit composer when change was undone ([\element-hq#9109](matrix-org/matrix-react-sdk#9109)). Fixes element-hq#22932.
* 1-to-1 DM rooms with bots now act like DM rooms instead of multi-user-rooms before ([\element-hq#9124](matrix-org/matrix-react-sdk#9124)). Fixes element-hq#22894.
* Apply inline start padding to selected lines on modern layout only ([\element-hq#9006](matrix-org/matrix-react-sdk#9006)). Fixes element-hq#22768. Contributed by @luixxiul.
* Peek into world-readable rooms from spotlight ([\element-hq#9115](matrix-org/matrix-react-sdk#9115)). Fixes element-hq#22862.
* Use default styling on nested numbered lists due to MD being sensitive ([\element-hq#9110](matrix-org/matrix-react-sdk#9110)). Fixes element-hq#22935.
* Fix replying using chat effect commands ([\element-hq#9101](matrix-org/matrix-react-sdk#9101)). Fixes element-hq#22824.
su-ex added a commit to SchildiChat/matrix-react-sdk that referenced this issue Aug 22, 2022
* Device manager - New device tile info design ([\matrix-org#9122](matrix-org#9122)). Contributed by @kerryarchibald.
* Device manager generic settings subsection component ([\matrix-org#9147](matrix-org#9147)). Contributed by @kerryarchibald.
* Migrate the hidden read receipts flag to new "send read receipts" option ([\matrix-org#9141](matrix-org#9141)).
* Live location sharing - share location at most every 5 seconds ([\matrix-org#9148](matrix-org#9148)). Contributed by @kerryarchibald.
* Increase max length of voice messages to 15m ([\matrix-org#9133](matrix-org#9133)). Fixes element-hq/element-web#18620.
* Move pin drop out of labs ([\matrix-org#9135](matrix-org#9135)).
* Start DM on first message ([\matrix-org#8612](matrix-org#8612)). Fixes element-hq/element-web#14736.
* Remove "Add Space" button from RoomListHeader when user cannot create spaces ([\matrix-org#9129](matrix-org#9129)).
* The Welcome Home Screen: Dedicated Download Apps Dialog ([\matrix-org#9120](matrix-org#9120)). Fixes element-hq/element-web#22921. Contributed by @justjanne.
* The Welcome Home Screen: "Submit Feedback" pane ([\matrix-org#9090](matrix-org#9090)). Fixes element-hq/element-web#22918. Contributed by @justjanne.
* New User Onboarding Task List ([\matrix-org#9083](matrix-org#9083)). Fixes element-hq/element-web#22919. Contributed by @justjanne.
* Add support for disabling spell checking ([\matrix-org#8604](matrix-org#8604)). Fixes element-hq/element-web#21901.
* Live location share - leave maximised map open when beacons expire ([\matrix-org#9098](matrix-org#9098)). Contributed by @kerryarchibald.
* Some slash-commands (`/myroomnick`) have temporarily been disabled before the first message in a DM is sent. ([\matrix-org#9193](matrix-org#9193)).
* Use stable reference for active tab in tabbedView ([\matrix-org#9145](matrix-org#9145)). Contributed by @kerryarchibald.
* Fix pillification sometimes doubling up ([\matrix-org#9152](matrix-org#9152)). Fixes element-hq/element-web#23036.
* Fix composer padding ([\matrix-org#9137](matrix-org#9137)). Fixes element-hq/element-web#22992.
* Fix highlights not being applied to plaintext messages ([\matrix-org#9126](matrix-org#9126)). Fixes element-hq/element-web#22787.
* Fix dismissing edit composer when change was undone ([\matrix-org#9109](matrix-org#9109)). Fixes element-hq/element-web#22932.
* 1-to-1 DM rooms with bots now act like DM rooms instead of multi-user-rooms before ([\matrix-org#9124](matrix-org#9124)). Fixes element-hq/element-web#22894.
* Apply inline start padding to selected lines on modern layout only ([\matrix-org#9006](matrix-org#9006)). Fixes element-hq/element-web#22768. Contributed by @luixxiul.
* Peek into world-readable rooms from spotlight ([\matrix-org#9115](matrix-org#9115)). Fixes element-hq/element-web#22862.
* Use default styling on nested numbered lists due to MD being sensitive ([\matrix-org#9110](matrix-org#9110)). Fixes element-hq/element-web#22935.
* Fix replying using chat effect commands ([\matrix-org#9101](matrix-org#9101)). Fixes element-hq/element-web#22824.
* The first message in a DM can no longer be a sticker. This has been changed to avoid issues with the integration manager. ([\matrix-org#9180](matrix-org#9180)).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-DMs O-Frequent Affects or can be seen by most users regularly or impacts most users' first experience S-Tolerable Low/no impact on users Sponsored T-Enhancement Z-FTUE
Projects
None yet
Development

Successfully merging a pull request may close this issue.