Skip to content

Convert types and subtypes to lowercase #55

@Jayman2000

Description

@Jayman2000

Section 8.3.1 of RFC 9110 defines media types in the context of HTTP. It says:

The type and subtype tokens are case-insensitive.

Section 5.6.6 of RFC 9110 defines parameters for media types. It says:

Parameter names are case-insensitive. Parameter values might or might not be case-sensitive, depending on the semantics of the parameter name.

At the moment, python-mimeparse converts all parameter names to lowercase, but it does not change the capitalization of types and subtypes. It would be more consistent if python-mimeparse also converted types and subtypes to all lowercase. Doing so would also help programs that use python-mimeparse comply with the “The type and subtype tokens are case-insensitive” rule.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions