Message410868
this issue is different than Issue32462
because here, both entries are valid
```
cat /etc/mime.types | grep javascript
application/javascript js
application/x-javascript js
```
but the alphabetical ordering of the file
makes the last entry take precedence
python could be smarter at parsing the /etc/mime.types file
in that it could give lower precedence to the deprecated types
pseudocode:
deprecated_mimetypes = set(...) # values from rfc4329
mimetype_of_ext = dict()
# parser loop
for ...
ext = "..."
mimetype = "..."
if ext in mimetype_of_ext:
old_mimetype = mimetype_of_ext[ext]
if old_mimetype in deprecated_mimetypes:
mimetype_of_ext[ext] = mimetype # replace old with new
# assume that mimetype is not deprecated
mimetype_of_ext[ext] = mimetype |
|
Date |
User |
Action |
Args |
2022-01-18 14:41:53 | milahu | set | recipients:
+ milahu, iritkatriel |
2022-01-18 14:41:53 | milahu | set | messageid: <1642516913.11.0.902419693635.issue46035@roundup.psfhosted.org> |
2022-01-18 14:41:53 | milahu | link | issue46035 messages |
2022-01-18 14:41:53 | milahu | create | |
|