You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
MimeTypes.add_type() is missing from the docs #121658
Hello! Thanks for the report.
As @tomasr8 said, type checking error is coming from the fact that Mimetypes.add_type isn't defined in the typeshed stubs. Actually, yes, we need to update our docs to add this method. Would you like to send a pull request?
Activity
tomasr8 commentedon Jul 13, 2024
Seems like the
add_typemethod is missing from typeshed:https://github.com/python/typeshed/blob/6a9b53e719a139c2d6b41cf265ed0990cf438192/stdlib/mimetypes.pyi#L42
Eclips4 commentedon Jul 13, 2024
Hello! Thanks for the report.
As @tomasr8 said, type checking error is coming from the fact that
Mimetypes.add_typeisn't defined in the typeshed stubs. Actually, yes, we need to update our docs to add this method. Would you like to send a pull request?Eclips4 commentedon Jul 13, 2024
FYI, here's the PR for typeshed: python/typeshed#12329
[-]MimeTypes.add_type() missing from types and docs[/-][+]MimeTypes.add_type() is missing from the docs[/+]stinovlas commentedon Jul 13, 2024
I'm working on this during EuroPython 2024 sprint.
pythongh-121658: Add MimeTypes.add_type docs
stinovlas commentedon Jul 13, 2024
Fixed in #121665.
pythongh-121658: Add MimeTypes.add_type docs
pythongh-121658: Add MimeTypes.add_type docs
RafaelJohn9 commentedon Aug 14, 2024
@Eclips4 has this issue been fixed? if not I would like to be assignedd
Eclips4 commentedon Aug 14, 2024
There's an existing PR which solves the issue: #121665. We're just waiting for someone with ability to merge it.
RafaelJohn9 commentedon Aug 14, 2024
Aah nice 👍🙂
pythongh-121658: Add versionadded note
hugovk commentedon Nov 6, 2024
Was added in #122301, thanks!