falconry / falconry/python-mimeparse

Convert types and subtypes to lowercase

未关闭
#55 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
Python
星标
20
派生
12
PR 合并指标
30 天内没有已合并 PR

描述

[Section 8.3.1 of RFC 9110](https://httpwg.org/specs/rfc9110.html#media.type) 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](https://httpwg.org/specs/rfc9110.html#parameter) 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.

贡献指南

这个仓库没有索引到贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。