Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

When someone uses an unroutable room ID ("Failed to join"), suggest using via server derived from the room ID #973

Closed
MadLittleMods opened this issue Feb 9, 2023 · 8 comments
Labels
O-Frequent Affects or can be seen by most users regularly or impacts most users' first experience S-Minor Impairs non-critical functionality or suitable workarounds exist T-Enhancement Z-MadLittleMods

Comments

@MadLittleMods
Copy link

MadLittleMods commented Feb 9, 2023

Problem

When someone uses an unroutable room ID, it currently just presents them with an error modal that looks like following and isn't helpful for knowing what's wrong or how to fix it:

Failed to join

MatrixError: [404] No known servers (https://matrix-client.matrix.org/_matrix/client/r0/join/!abc%3Agitter.im)

Potential solution

We could instead suggest a best-guess via server derived from the room ID. Yes, this does mean parsing an opaque room ID (gasps) to give the guess, but the user still needs to do the correct thing in the end.

This not only helps the user get where they want but also teaches them for next time.

Failed to join

The !JsbthXjlaqosxISjgl:gitter.im room isn't known to your homeserver (matrix.org).

You can try using a "via" server to join through which is supplied as the 2nd parameter in the /join slash command: /join !JsbthXjlaqosxISjgl:gitter.im gitter.im

Or if you're using a matrix.to link, you can try adding a ?via=gitter.im query parameter to the URL: https://matrix.to/#/!JsbthXjlaqosxISjgl:gitter.im?via=gitter.im

Alternatively, if you know a room alias (starts with a #) associated with this room, that will always be routable and allow you to join.

Error details (expand/collapse)

We can even include matrix.org as a fallback as that is probably a great server to use as a shot in the dark for things to work out. We want to delight and teach people, not bury them caveats.

Have you considered any alternatives?

Ideally, this via server assumption could just be automatic but I don't think this would hold up against decision makers with a strong room IDs are opaque strings opinions. And also doesn't teach people for a future where we can't assume.

Additional context

Related issues:


Mockup HTML/CSS
<div class="mx_Dialog_content" id="mx_Dialog_content" style="
   line-height: 2.2rem;
">
<p>The <code>!JsbthXjlaqosxISjgl:gitter.im</code> room isn't known to your homeserver (<code>matrix.org</code>).</p>
<p>You can try using a "via" server to join through which is supplied as the 2nd parameter in the /join slash command: <code>/join !JsbthXjlaqosxISjgl:gitter.im gitter.im</code></p>
<p>Or if you're using a matrix.to link, you can try adding a <code>?via=gitter.im</code> query parameter to the URL: <a href="https://matrix.to/#/!JsbthXjlaqosxISjgl:gitter.im?via=gitter.im">https://matrix.to/#/!JsbthXjlaqosxISjgl:gitter.im?via=gitter.im</a></p>
<p>Alternatively, if you know a room alias (starts with a <code>#</code>) associated with this room, that will always be routable and allow you to join.</p>

<details>
<summary>Error details</summary>
<pre><code>...</code></pre>
</details>

</div>
#mx_Dialog_content code {
    background-color: #f4f6fa;
    border: 1px solid #e3e8f0;
    border-radius: 4px;
    padding: 2px 4px;
    line-height: 2.2rem;
    margin-right: 2px;
}
@MadLittleMods MadLittleMods added T-Enhancement S-Minor Impairs non-critical functionality or suitable workarounds exist O-Frequent Affects or can be seen by most users regularly or impacts most users' first experience labels Feb 9, 2023
@abhijain2003
Copy link

that's a better approach to help end-user. can I work on this?

@JeanPaulLucien
Copy link

JeanPaulLucien commented Feb 10, 2023

Anyone knows what "404" means. This is not client issue. You are going to offer to user spend his time.
The !JsbthXjlaqosxISjgl:gitter.im room isn't known to your homeserver (matrix.org).
Yeah, because homeserver for this room is gitter.im, not matrix.org.

@abhijain2003
Copy link

and I think most client won't be able to understand the routing / and all, so

@JeanPaulLucien
Copy link

JeanPaulLucien commented Feb 10, 2023

I checked server gitter.im. It is really lagged. Ping shows "Time out".
gitter im is lagged

I'm as end-user would not spend my time end computing power for lagged servers.

I found Gitter room address displayed as #...:gitter.im I joined without issue.

@t3chguy
Copy link
Member

t3chguy commented Feb 10, 2023

Anyone knows what "404" means. This is not client issue. You are going to offer to user spend his time.
The !JsbthXjlaqosxISjgl:gitter.im room isn't known to your homeserver (matrix.org).
Yeah, because homeserver for this room is gitter.im, not matrix.org.

Rooms don't have a specific homeserver, they're shared amongst all servers which have users in the room.

@t3chguy
Copy link
Member

t3chguy commented Feb 10, 2023

We could instead suggest a best-guess via server derived from the room ID. Yes, this does mean parsing an opaque room ID (gasps) to give the guess, but the user still needs to do the correct thing in the end.

If this is a heuristic we want then it should be implemented in the spec and server rather than every client where it'll be inconsistent

As for defaulting to matrix.org, leaking room IDs of private federations would be considered a privacy issue.

@JeanPaulLucien
Copy link

Seems room !JsbthXjlaqosxISjgl:gitter.im does not exist.

@t3chguy
Copy link
Member

t3chguy commented Feb 10, 2023

@JeanPaulLucien this isn't a support room for specific rooms.

@t3chguy t3chguy transferred this issue from element-hq/element-web Feb 10, 2023
@element-hq element-hq locked and limited conversation to collaborators Feb 10, 2023
@t3chguy t3chguy converted this issue into discussion #974 Feb 10, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
O-Frequent Affects or can be seen by most users regularly or impacts most users' first experience S-Minor Impairs non-critical functionality or suitable workarounds exist T-Enhancement Z-MadLittleMods
Projects
None yet
Development

No branches or pull requests

4 participants