Skip to content

og:image preview bails out if Content-Length header is missing, many image CDNs use streaming or chunked encoding nowΒ #6645

@jonsherrard

Description

@jonsherrard
  • I have searched open and closed issues for duplicates
  • I am using Signal-Desktop as provided by the Signal team, not a 3rd-party package.

Bug Description

Steps to Reproduce

  1. step one
    Open a chat
  2. step two
    Paste https://vercel.com/docs/functions/edge-functions/og-image-generation
  3. step three
    Notice there is no OG image loaded.

Actual Result:

No image preview is laoded in the chat is because vercel's image servers don't set a content-length, so it bails out:

if (contentLength > MAX_IMAGE_CONTENT_LENGTH) {

Expected Result:

The image preview should load.

Screenshots

Signal:
image

Other chat app:
image

Platform Info

Signal Version:

6.34.1
production (Apple silicon)

Operating System:

14.0 (23A344)

Linked Device Version:

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions