Skip to content

net/http: http.Client's auto-redirect causes errors in Rack on Ruby by RFC 2046 #52519

Closed
@catatsuy

Description

@catatsuy

According to RFC 2046, the Body of a multipart request must not be empty. However, http.Client's auto-redirect uses the same Content-Type, which violates this rule.

Of course we can avoid the error by using http.ErrUseLastResponse. But this default behavior results in an error with Rack, which is very widely used in Ruby. Rack does not provide a workaround.

What is the correct solution?

refs: rack/rack#1787

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions