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

"Homeserver URL does not appear to be a valid Matrix homeserver" error is unclear on which homeserver is invalid #9835

Closed
bwindels opened this issue May 24, 2019 · 15 comments · Fixed by #9892
Assignees
Labels

Comments

@bwindels
Copy link
Contributor

bwindels commented May 24, 2019

image

leaves the user with no option apart from clearing their storage in the devtools. Would be helpful to have a logout option to start a new session.

Might also be helpful to mention the actual homeserver url ...

@bwindels
Copy link
Contributor Author

(ftr I hit this on a local synapse that wasn't running)

@bwindels
Copy link
Contributor Author

This is also shown if riot is configured with a default hsurl that is invalid (not running in this case), but I'm guessing this is somewhat on purpose.

@turt2live
Copy link
Member

It's not complaining about your account's homeserver, it's complaining about the configuration. I thought it had words to say that, but apparently not. I wonder if that's what is causing so much confusion around this error...

The app doesn't know if you are logged in at this point, so a logout button would not be possible (or help). I think we just need to clarify the error message to complain about config being invalid.

@turt2live
Copy link
Member

(I'm hijacking this issue to clarify that error - if I've missed the point, feel free to take it back)

@turt2live turt2live changed the title Offer logout option on "Homeserver URL does not appear to be a valid Matrix homeserver" error "Homeserver URL does not appear to be a valid Matrix homeserver" error is unclear on which homeserver is invalid May 24, 2019
@turt2live turt2live self-assigned this May 24, 2019
@bwindels
Copy link
Contributor Author

Indeed, nothing to do with the session. Would be good to clarify this and perhaps also mention the configured (invalid) server in the error message.

@bwindels
Copy link
Contributor Author

bwindels commented May 28, 2019

@rxl881 encountered the same screen on /develop as well, with a couple refresh fixing it 🤔
image

Rick: Multiple refreshes followed, which resulted in a blank page and then after a while the same message. Eventually I refreshed and it worked (no login or other action required).

Account was on vector.modular.im which doesn't seem to have well-known set up.

@jryans
Copy link
Collaborator

jryans commented May 29, 2019

@lampholder and I have both seen this on develop, including an extra line about Invalid /versions response. I think it would help debugging to add a lot more logging including server URL, etc. in the discovery code.

@anoadragon453
Copy link
Member

Myself and other users of my self-hosted Riot (which is pulled from BuildKite develop every hour) are also seeing this error message from time to time, across a variety of browsers.

Here is the config.json:

{
    "default_hs_url": "https://amorgan.xyz",
    "default_is_url": "https://vector.im",
    "disable_custom_urls": true,
    "disable_guests": true,
    "disable_login_language_selector": false,
    "disable_3pid_login": true,
    "brand": "Riot",
    "integrations_ui_url": "https://scalar.vector.im/",
    "integrations_rest_url": "https://scalar.vector.im/api",
    "integrations_jitsi_widget_url": "https://scalar.vector.im/api/widgets/jitsi.html",
    "bug_report_endpoint_url": "https://riot.im/bugreports/submit",
    "features": {
        "feature_groups": "labs",
        "feature_pinning": "labs",
        "feature_tabbed_settings": "labs",
        "feature_state_counters": "labs",
        "feature_room_breadcrumbs": "labs",
        "feature_custom_tags": "labs",
     	"feature_state_counters": "labs",
	"feature_tag_panel": "enable",
 	"feature_presence_management": "labs",
        "feature_reactions": "labs",
        "feature_message_editing": "labs"
    },
    "default_federate": true,
    "default_theme": "light",
    "roomDirectory": {
        "servers": [
            "matrix.org"
        ]
    },
    "welcomeUserId": "@riot-bot:matrix.org",
    "piwik": {
        "url": "https://piwik.riot.im/",
        "whitelistedHSUrls": ["https://matrix.org"],
        "whitelistedISUrls": ["https://vector.im", "https://matrix.org"],
        "siteId": 1
    },
    "enable_presence_by_hs_url": {
        "https://matrix.org": false
    }
}

@non-Jedi
Copy link

non-Jedi commented May 29, 2019

When refreshing, I sometimes get the error mentioned here, sometimes it works, and sometimes I get an error about an "invalid identity server discovery response" on riot.im/develop. My identity server is https://vector.im and homeserver is https://matrix.thebeckmeyers.xyz.

riot-id-server-error

@turt2live
Copy link
Member

I think it would help debugging to add a lot more logging including server URL, etc. in the discovery code.

We know what the issue is, just need to improve the messaging. The bug of it showing up in the first place still needs a @lampholder to give me a plan.

turt2live added a commit that referenced this issue May 29, 2019
Only applies if the user appears to be logged in. If the user is not logged in, we scream loudly.

This is a temporary measure for #9828

Fixes #9835
@non-Jedi
Copy link

non-Jedi commented Jun 4, 2019

I just saw this error again this morning on riot.im/develop

@jryans
Copy link
Collaborator

jryans commented Jun 4, 2019

Sorry to hear that. 😭 I think it's likely best to open a new issue and include your config.json so we can analyse your specific case in detail.

@non-Jedi
Copy link

non-Jedi commented Jun 4, 2019

I'm using the hosted Riot on riot.im/develop. I thought the config.json was setup server-side for Riot? If it's client-side config, I can dump it to open an issue if you let me know how.

@jryans
Copy link
Collaborator

jryans commented Jun 4, 2019

Ah right, sorry, I was reading a bit too fast... No need to worry about the config.json since we have that already, but still I think a fresh issue and console logs would be best, so that we can track your case separately.

@non-Jedi
Copy link

non-Jedi commented Jun 4, 2019

I'll see if I can trigger again when I get a minute later.

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

Successfully merging a pull request may close this issue.

5 participants