This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: Support LMMS project files in mimetypes.guess_type
Type: enhancement Stage: needs patch
Components: Library (Lib) Versions: Python 3.6
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: Andreas Nilsson, Nan Wu, corona10
Priority: normal Keywords:

Created on 2015-06-20 10:18 by Andreas Nilsson, last changed 2022-04-11 14:58 by admin.

File name Uploaded Description Edit
seaman.mmp Andreas Nilsson, 2015-06-22 03:47 Example decompressed LMMS project file
issue24479_support_mmp_and_mmpz_suffix_in_guess_type Nan Wu, 2015-07-23 05:22 added .mmp/.mmps type and tested it. review
Messages (5)
msg245556 - (view) Author: Andreas Nilsson (Andreas Nilsson) * Date: 2015-06-20 10:18
There is no support for recognizing LMMS project files (.mmpz / .mmp). Could this be added for strict=False?
msg245617 - (view) Author: Andreas Nilsson (Andreas Nilsson) * Date: 2015-06-22 03:47
Here is a decompressed example (use lmms -d <file> to decompress). Shouldn't this be parsed as XML? Here's a log of my experiment with it:

Python 2.7.9 (default, Apr  2 2015, 15:33:21) 
[GCC 4.9.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import mimetypes
>>> mimetypes.init()
>>> mimetypes.guess_type("seaman.mmp")
(None, None)
>>> mimetypes.guess_type("seaman.mmp", False)
(None, None)

By default LMMS saves as .mmpz which is the compressed type, I do not know the encryption method they use though but I can ask them if you want so!
msg247168 - (view) Author: Nan Wu (Nan Wu) * Date: 2015-07-23 05:22
Added a small patch. Pls let me know if anything missed.
msg348632 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2019-07-29 11:45
This issue is 4 years old and has patches: it is no newcomer friendly, I remove the "easy" keyword.
msg350462 - (view) Author: Dong-hee Na (corona10) * (Python committer) Date: 2019-08-25 15:01

I'd like to work on this issue.
My plan is adding mime-types as 'mmp' to 'application/x-lmms-project'  and 'mmpz' to 'application/x-lmms-project' 
What do you think?
Date User Action Args
2022-04-11 14:58:18adminsetgithub: 68667
2019-08-26 21:32:02vstinnersetkeywords: - easy
2019-08-26 21:31:51vstinnersetnosy: - vstinner
2019-08-25 15:01:38corona10setnosy: + corona10
messages: + msg350462
2019-07-29 11:45:47vstinnersetnosy: + vstinner
messages: + msg348632
2015-07-23 05:22:57Nan Wusetfiles: + issue24479_support_mmp_and_mmpz_suffix_in_guess_type
nosy: + Nan Wu
messages: + msg247168

2015-06-22 03:47:56Andreas Nilssonsetfiles: + seaman.mmp

messages: + msg245617
2015-06-20 22:53:41ned.deilysetkeywords: + easy
stage: needs patch
versions: + Python 3.6, - Python 3.3
2015-06-20 10:18:22Andreas Nilssoncreate