Skip to content

Gun: streaming response body breaks with Tesla.Middleware.Timeout #709

@feld

Description

@feld

The Timeout middleware breaks the ability to read the stream and an error is thrown due to no case clause matching

** (CaseClauseError) no case clause matching: {:error, :recv_chunk_timeout}
    (tesla 1.11.0) lib/tesla/adapter/gun.ex:493: anonymous fn/2 in Tesla.Adapter.Gun.format_response/6
    (elixir 1.16.3) lib/stream.ex:1626: Stream.do_resource/5
    (elixir 1.16.3) lib/enum.ex:1560: Enum.reduce_into_protocol/3
    (elixir 1.16.3) lib/enum.ex:1544: Enum.into_protocol/2
    iex:4: (file)

Observed with Tesla 1.11.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions