]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-40626: Support HDF5 in mimetypes (GH-20042)
authorMARK SCHWAB <32745414+schwabm@users.noreply.github.com>
Thu, 11 Jun 2020 19:04:13 +0000 (13:04 -0600)
committerGitHub <noreply@github.com>
Thu, 11 Jun 2020 19:04:13 +0000 (15:04 -0400)
Add hdf5 with .h5 file extension

See 'Recommendations' section for mime types from the HDF group:  https://www.hdfgroup.org/2018/06/citations-for-hdf-data-and-software/

Patch by Mark Schwab.

Lib/mimetypes.py
Misc/NEWS.d/next/Library/2020-05-18-17-29-30.bpo-40626.NeZufF.rst [new file with mode: 0644]

index e972ca2e291a0bda29cc21da7df3751424ec39f8..61bfff1635911f6ee17909df712cbd4b017907c8 100644 (file)
@@ -448,6 +448,7 @@ def _default_mime_types():
         '.dvi'    : 'application/x-dvi',
         '.gtar'   : 'application/x-gtar',
         '.hdf'    : 'application/x-hdf',
+        '.h5'     : 'application/x-hdf5',
         '.latex'  : 'application/x-latex',
         '.mif'    : 'application/x-mif',
         '.cdf'    : 'application/x-netcdf',
diff --git a/Misc/NEWS.d/next/Library/2020-05-18-17-29-30.bpo-40626.NeZufF.rst b/Misc/NEWS.d/next/Library/2020-05-18-17-29-30.bpo-40626.NeZufF.rst
new file mode 100644 (file)
index 0000000..fe652cd
--- /dev/null
@@ -0,0 +1 @@
+Add h5 file extension as MIME Type application/x-hdf5, as per HDF Group recommendation for HDF5 formatted data files. Patch contributed by Mark Schwab.