cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Audio/mpeg saves it as mpga instead of mp3

Jeronimo17
Making moves

Recently I have noticed on several websites that I used to save in mp3 and now in mpga when the correct format is mp3. It seems that other browsers save in mp3.

Example:

https://cope-cdnmed.agilecontent.com/resources/mp3/9/9/1657390038099.mp3?download

Edit: Linux Mint 20.3

18 REPLIES 18

jscher2000
Leader

I can't reproduce the problem on Windows 10.

Could you take a look at your handlers.json file to see whether it shows .mpga as the file extension for audio/mpeg content? Here's how:

  • Open the Troubleshooting Information page (Help > More Troubleshooting Information)
  • Find the "Profile Folder" row in the first table, and click the button to Open the folder/directory
  • Resize/position the file browsing window so you can see the Troubleshooting Information page
  • Drag and drop the handlers.json file onto the page; Firefox should briefly show the raw text of the file and then the JSON viewer should show a structured display

You can use Find in page (Ctrl+F) to look for mpeg and see whether you have an entry for that content-type. For example, if I right-click an mp3 download on the Downloads list and select "Always Open Similar Files", Firefox creates this entry for me in handlers.json:

Screenshot 2022-07-26 at 16-37-26 Screenshot.png

If you have an entry with "mpga" that would be unhelpful.

I forgot to put that I'm on Linux Mint.

At the end of the link I put it says:

· Save link as on link https://cope-cdnmed.agilecontent.com/resources/mp3/9/9/1657390038099.mp3?download saves as '1657390038099.mpga' on Ubuntu 20.4, '1657390038099' on Win10 and '1657390038099.mp3' on Mac 10.13.

 

mpga.png

I always save mp3 and have not changed any settings, but in some version they started to be saved as mpga.

jscher2000
Leader

Mine saves with .mp3 on Windows 10. Not sure if the person who reported that has a display issue (Windows suppresses display of certain file extensions by default) or something else.

I hand-edited my handlers.json file to match yours but the file extension didn't switch. There must be some other factor:

Screenshot 2022-07-26 at 17-09-28 Screenshot.png

 

I have tested on Win10 and it doesn't seem to affect it, I haven't thought to test it there I hardly use it.

I have tried in Linux to set handlers.json with only mp3 and it doesn't work either, it still suggests mpga when saving.

Ricardo
Making moves

I have the same issue with Firefox saving mp3 files as mpga files.  I’m on Linux Mint XFCE 21 Vanessa.  My job requires me work with audio files and I can’t use Firefox with this glitch.


@Ricardo wrote:

I have the same issue with Firefox saving mp3 files as mpga files.  I’m on Linux Mint XFCE 21 Vanessa.  My job requires me work with audio files and I can’t use Firefox with this glitch.


As a temporary workaround, you can remove the file which stores file extension/content-type associations and your download actions. I say temporary because whatever added .mpga to the file may do it again. If you want to try it:

  • Open the Troubleshooting Information page (Help > More Troubleshooting Information)
  • Find the "Profile Folder" row in the first table, and click the button to Open the folder/directory
  • Keeping that file browser window open, switch over to Firefox and Quit
  • Rename handlers.json to handlersOLD.json to hide it from Firefox (on Windows, you would right-click > Rename; I don't know about Linux)
  • The next time you start Firefox, it should start a new handlers.json file

 

I doubt that will work, I already tried leaving only .mp3 in that file.


@Jeronimo17 wrote:

I doubt that will work, I already tried leaving only .mp3 in that file.


Hmm, if .mpga isn't coming from the server, and isn't coming from handlers.json, is it possible it's coming from a mimeTypes files at the OS level?

 

It could be that Firefox is looking for

 

~ $ grep mp3 /etc/mime.types
audio/mpeg                    mpga mpega mp2 mp3 m4a

 

Edit: That's the key, I have modified that file and Firefox suggests me mp3


@Jeronimo17 wrote:

It could be that Firefox is looking for

 

~ $ grep mp3 /etc/mime.types
audio/mpeg                    mpga mpega mp2 mp3 m4a

 

Edit: That's the key, I have modified that file and Firefox suggests me mp3


That's a great discovery. The thing that puzzles me is why it was using mpga and then switched to mp3. It's not alphabetical, it's not sequential... I don't get it.

I think it's worth updating your bug with this information. I don't know what the developers want to do, but my thought is: if the server has suggested a file extension which is on that list, do not replace it with anything else even if it's also on that list.

 

This happens when the extension is not well defined in the filename "1657390038099.mp3?download" and is based only on the mimetype

$ curl -I https://cope-cdnmed.agilecontent.com/resources/mp3/9/9/1657390038099.mp3?download
HTTP/2 200
last-modified: Sat, 09 Jul 2022 18:12:19 GMT
etag: "fc65d3c7cf7cb0a5d22c4b733e583e9b"
content-type: audio/mpeg

 

Thanks to everyone who made suggestions.  Editing the mime.types file resolved the problem for me.

Thanks, putting mp3 the first item in the list worked too. I'm on Linux Mint 21 Vanessa

Hi

 

I'm not sure how to put mp3 first in the list? I get a lot of shows sent to me for play out and this is driving me mad!

@KyleRickards, edit the "/etc/mime.types" file, then find the line with "mpga" in it.  It will likely look something like this:

audio/mpeg    mpga mpega mp1 mp2 mp3

Change it to put "mp3" at the front of the extension list:

audio/mpeg     mp3 mpga mpega mp1 mp2

Save the file and you should be in good shape.  Good luck.

Thank you - I am a little unsure where to find the file? I did search and found a few with that name in my OS? I am on Linux Mint 19

The file is in the "etc" directory of your root filesystem, and is named "mime.types".

/etc/mime.types

The easiest way to do this is likely via command line:

1)Open terminal
2)Assuming the nano editor is installed in Linux Mint, run this command:
     sudo nano /etc/mime.types
3)You should be prompted for your root or superuser password.
4)You should now be able to edit the file.  Edit the file as described in the previous post.
5) Save with "ctrl o" and exit with "ctrl x".  Firefox should automatically start downloading the files as mp3 files going forward.