Skip to content
Merged
Prev Previous commit
Next Next commit
Remove inline comments from docs examples
  • Loading branch information
htjworld committed May 11, 2026
commit 77e5b2a473473a9d49f251107cdae66710c1536e
6 changes: 3 additions & 3 deletions Doc/library/mimetypes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -381,22 +381,22 @@ interface:
$ python -m mimetypes --extension text/javascript
.js

$ # get a file extension by a rare MIME type (error goes to stderr)
$ # get a file extension by a rare MIME type
$ python -m mimetypes --extension text/xul
error: unknown type text/xul

$ # now look in the extended database again
$ python -m mimetypes --extension --lenient text/xul
.xul

$ # try to feed an unknown file extension (error goes to stderr)
$ # try to feed an unknown file extension
$ python -m mimetypes filename.sh filename.nc filename.zzz filename.txt
type: application/x-sh encoding: None
type: application/x-netcdf encoding: None
error: media type unknown for filename.zzz
type: text/plain encoding: None

$ # try to feed an unknown MIME type (error goes to stderr)
$ # try to feed an unknown MIME type
$ python -m mimetypes --extension audio/aac audio/opus audio/future audio/x-wav
.aac
.opus
Expand Down
Loading