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

Problems showing Image #29324

Open
yncyrydybyl opened this issue Feb 20, 2025 · 7 comments
Open

Problems showing Image #29324

yncyrydybyl opened this issue Feb 20, 2025 · 7 comments
Labels
A-Media O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround T-Defect X-Needs-Investigation

Comments

@yncyrydybyl
Copy link
Member

Steps to reproduce

Upload a picture.
Look at the timeline.

Image

Outcome

What did you expect?

I expected to see the picture in the timeline.

What happened instead?

I see "Error downloading image" in the timeline.

For https://element.ems.host/_matrix/media/v3/download/element.io/f9921a8d3df6e4f31f53857644245a8bf54361ae1892570265175457792?allow_redirect=true

i get a:

{
    "errcode": "M_NOT_FOUND",
    "error": "authentication is required to download this media",
    "mr_errcode": "M_NOT_FOUND"
}

And the status code is a 404.

Operating system

Linux

Browser information

Version 132.0.6834.159 (Official Build) (64-bit)

URL for webapp

https://chat.element.io

Application version

Element version: 1.11.92

Homeserver

element.ems.host

Will you send logs?

Yes

@dosubot dosubot bot added A-Media O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround labels Feb 20, 2025
@t3chguy
Copy link
Member

t3chguy commented Feb 20, 2025

Version 132.0.6834.159 (Official Build) (64-bit)

What browser is that?

Will you send logs?
Yes

Not seeing any logs from you

@t3chguy t3chguy added the X-Needs-Info This issue is blocked awaiting information from the reporter label Feb 20, 2025
@yncyrydybyl
Copy link
Member Author

Sorry. Its a chrome.
I dont have access to the server logfiles. But will send a ragshake now.

@t3chguy t3chguy removed the X-Needs-Info This issue is blocked awaiting information from the reporter label Feb 21, 2025
@t3chguy
Copy link
Member

t3chguy commented Feb 21, 2025

Unfortunately your logs do not shed any light on why the service worker isn't working as expected, there's a separate issue which means we don't get logs from the service worker in rageshakes.

@yncyrydybyl
Copy link
Member Author

Maybe it is worth noting that i run at least 3 sessions of element-web in the browser since it was not possible to have multiple tabs.

@pini-gh
Copy link

pini-gh commented Feb 28, 2025

Hi,
Same kind of error on our instance with dockerized element-web v1.11.94 and Firefox 128.5.0esr (Debian 12). We run a small instance (almost 5 years old) for our association and most accounts are local.

The behavior is confusing:

  1. Someone upload an image into a room
  2. I can't see the image but the message "Error downloading image"
  3. If I reload the page with <Ctrl+R> the image appears
  4. If I force reload the page <Ctrl+Shift+R> the error is back
  5. goto 3.

When at step 4, if I scroll back into the room's history I can see the "Error downloading image" message for all images until late November 2024. Previous images are OK.

But this weird behavior is really new. I noticed it today, while I use Element almost every days and update at least once a month.

I tried reverting down to release v1.10.80 with no luck.

I can provide logs on demand.

@pini-gh
Copy link

pini-gh commented Mar 1, 2025

With the "late November 2024" date in mind, I scrolled through synapse's release notes and this one rang a bell:

Synapse 1.120.0 (2024-11-26)
This release enables the enforcement of authenticated media by default, with exemptions for media that is already present in the homeserver's media store.

And per the related documentation:

enable_authenticated_media
When set to true, all subsequent media uploads will be marked as authenticated, and will not be available over legacy unauthenticated media endpoints (/_matrix/media/(r0|v3|v1)/download and /_matrix/media/(r0|v3|v1)/thumbnail) - requests for authenticated media over these endpoints will result in a 404. All media, including authenticated media, will be available over the authenticated media endpoints _matrix/client/v1/media/download and _matrix/client/v1/media/thumbnail. Media uploaded prior to setting this option to true will still be available over the legacy endpoints. Note if the setting is switched to false after enabling, media marked as authenticated will be available over legacy endpoints. Defaults to true (previously false).

And precisely:

  • we didn't revert this new default setting and everything was working well so far, until a few days ago
  • when trying to download an unavailable image there is a 404 error with a path starting with https://matrix.example.org/_matrix/media/v3/download/... (unauthenticated endpoint).

How should we proceed to make element-web use the authenticated endpoints instead?

EDIT: looks like #28370 actually.

@yncyrydybyl
Copy link
Member Author

EDIT: looks like #28370 actually.

But it's not on FireFox it is on Chrome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Media O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround T-Defect X-Needs-Investigation
Projects
None yet
Development

No branches or pull requests

3 participants