From: Josephine-Marie <75948248+Josephine-Marie@users.noreply.github.com> Date: Mon, 11 Oct 2021 11:05:28 +0000 (+0200) Subject: bpo-45411: Update mimetypes.py (GH-28792) X-Git-Tag: v3.11.0a2~249 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d74da9e140441135a4eddaef9a37f00f32579038;p=thirdparty%2FPython%2Fcpython.git bpo-45411: Update mimetypes.py (GH-28792) .vtt and .srt files are common subtitle files, used by browsers. --- diff --git a/Lib/mimetypes.py b/Lib/mimetypes.py index 3ba91771ed03..e14d0719bed4 100644 --- a/Lib/mimetypes.py +++ b/Lib/mimetypes.py @@ -552,8 +552,10 @@ def _default_mime_types(): '.h' : 'text/plain', '.ksh' : 'text/plain', '.pl' : 'text/plain', + '.srt' : 'text/plain', '.rtx' : 'text/richtext', '.tsv' : 'text/tab-separated-values', + '.vtt' : 'text/vtt', '.py' : 'text/x-python', '.etx' : 'text/x-setext', '.sgm' : 'text/x-sgml', diff --git a/Misc/NEWS.d/next/Library/2021-10-08-11-29-29.bpo-45411.4jR--U.rst b/Misc/NEWS.d/next/Library/2021-10-08-11-29-29.bpo-45411.4jR--U.rst new file mode 100644 index 000000000000..5f774dcda984 --- /dev/null +++ b/Misc/NEWS.d/next/Library/2021-10-08-11-29-29.bpo-45411.4jR--U.rst @@ -0,0 +1 @@ +Add extensions for files containing subtitles - .srt & .vtt - to the mimetypes.py module.