jajuk-team / jajuk

Advanded jukebox for users with large or scattered music collections
49 stars 19 forks source link

Saving lyrics for mp3 creates an undesired file #1848

Closed bflorat closed 9 years ago

bflorat commented 9 years ago

Reported by mheja on 23 Aug 2012 18:56 UTC When saving lyrics for mp3 files from Lyrics view ("Visualization" view or perspective), the lyrics are not saved, but a file is created under same folder than the track file, with almost same name as the track file; the difference in the names is the new created file it has a suffix of 18 or 19 digits and the extension ".new" instead of the expected text file with the extension ".txt" that usually is created for lyrics of "wav" extension. An screenshot of the listing of what i got in the folder is attached. The new files does not seems to be text files, but mp3 files.

My configuration:

OS: Windows 7 64 bits sp1 JRE: v7 Jajuk 1.10 Intel Pc.

bflorat commented 9 years ago

Commented by bflorat on 23 Aug 2012 19:47 UTC Thanks for reporting.

'''Could tell me if your mp3 files are write-protected ?'''

I suspect that jaudiotagger (the tagging library we use) begins to copy the mp3 file for change, set the lyrics tag but can't override the source mp3 file again and keep it in the way.

Note that even if this diagnostic is verified, the error reporting was too low, a GUI error message has been added if the tag can't be written.

We wait for your answer to pursue analysis. If your files are not read-only, please provide logs just after problem reproduction (Help-> show debug traces). Thank you.

bflorat commented 9 years ago

Commented by bflorat on 25 Aug 2012 14:27 UTC Update from reporter:

" Version: 1.10 {java.runtime.name=Java(TM) SE Runtime Environment, sun.boot.library.path=C:\Program Files\Java\jre7\bin, java.vm.version=21.0-b17, user.country.format=MX, java.vm.vendor=Oracle Corporation, java.vendor.url=http://java.oracle.com/, path.separator=;, java.vm.name=Java HotSpot(TM) 64-Bit Server VM, file.encoding.pkg=sun.io, user.country=ES, user.script=, sun.java.launcher=SUN_STANDARD, sun.os.patch.level=Service Pack 1, java.vm.specification.name=Java Virtual Machine Specification, user.dir=C:\Program Files\Jajuk\bin, java.runtime.version=1.7.0-b147, java.awt.graphicsenv=sun.awt.Win32GraphicsEnvironment, java.endorsed.dirs=C:\Program Files\Java\jre7\lib\endorsed, os.arch=amd64, java.io.tmpdir=C:\Users\Yo\AppData\Local\Temp\, line.separator= , java.vm.specification.vendor=Oracle Corporation, user.variant=, os.name=Windows 7, sun.jnu.encoding=Cp1252, sun.awt.enableExtraMouseButtons=true, java.specification.name=Java Platform API Specification, java.class.version=51.0, sun.management.compiler=HotSpot 64-Bit Tiered Compilers, os.version=6.1, user.home=C:\Users\Yo, user.timezone=America/Mexico_City, java.awt.printerjob=sun.awt.windows.WPrinterJob, file.encoding=Cp1252, java.specification.version=1.7, java.vm.specification.version=1.7, sun.java.command=C:\Program Files\Jajuk\bin\jajuk.jar -notest, java.home=C:\Program Files\Java\jre7, sun.arch.data.model=64, user.language=es, java.specification.vendor=Oracle Corporation, awt.toolkit=sun.awt.windows.WToolkit, java.vm.info=mixed mode, java.version=1.7.0, java.vendor=Oracle Corporation, file.separator=\, java.vendor.url.bug=http://bugreport.sun.com/bugreport/, sun.io.unicode.encoding=UnicodeLittle, sun.cpu.endian=little, sun.desktop=windows, sun.cpu.isalist=amd64} {jajuk.update.ignored_releases=, jajuk.options.language=es, jajuk.ambience.8/Jazz=36jqin9cj56g4jppbutdyam2z,61206ycbdqaht7wrzw3ffourv,153ki653v8vw4q7qoovenssj2,2q3sxnty5jfi17hxc887nijvw, jajuk.ui.logical_table_columns.name.width=279, jajuk.title_animation=true, jajuk.ui.physical_table_columns.length.width=212, jajuk.ui.queue_columns.AoG_AC.width=75, jajuk.ui.queue_columns.AoR.width=70, jajuk.auto_scroll=true, jajuk.format_elapsed_time=0, jajuk.ui.albums_table_columns.tracks.width=224, jajuk.ui.physical_table_edition=false, jajuk.player.mplayer_args=, jajuk.ui.slimbar.smart_mode=SHUFFLE_GLOBAL, jajuk.options.default_action_drop=false, jajuk.audio_buffer_size=-1, jajuk.ui.queue_columns.PaisI.width=82, jajuk.network.none_internet_access=false, jajuk.ui.cover_catalog.thumbs_size=250x250, jajuk.catalog.sorter=2, jajuk.ui.queue_columns.Orquesta.width=93, jajuk.startup.mode=last_keep_pos, jajuk.ui.playlist_editor_columns.rate.width=322, jajuk.options.p2p.add_remote_properties=false, jajuk.startup.stopped=false, jajuk.ui.playlist_repository_columns=play,name,path, jajuk.ui.queue_columns.year.width=51, jajuk.bit_perfect=true, jajuk.global_novelties.mode=track, jajuk.ui.physical_table_columns.album.width=212, jajuk.ambience.10/Otros=37k1hmfzm7tpensgzkwrug4uo,72ziju1neu4bihut0xzw9cnh9,2jnxyuvsepidp42sgd4v7so74,5v57fawdcn6g95bipya1687t3,56wu0mza6uwx5pac6pon9a04a,9xbnssqoraj1xorfalwga6d7,1hv925sngdbp3b5jy6ne855o2,2m0whzilf8d9lpi0uz54rst4j,3iwy23dss8gk2v2r4asocika1, jajuk.covers.shuffle=false, jajuk.ui.queue_columns.rate.width=59, jajuk.ui.logical_table_columns.album.width=269, jajuk.options.fade_out=true, jajuk.alarm.seconds=00, jajuk.network.audioscrobbler=false, jajuk.ui.webradio_columns=play,name,label,keywords,style,origin, jajuk.ui.albums_table_columns.album.width=223, jajuk.ui.queue_columns.Anio C..width=47, jajuk.explorer_path=, jajuk.ui.logical_table_columns.AoG_AC.width=22, jajuk.network.use_proxy=false, jajuk.refactor_pattern=%album_artist/%year

bflorat commented 9 years ago

Commented by bflorat on 25 Aug 2012 14:42 UTC Thanks for the logs. They confirm that the problem comes from file renaming in jaudiotagger internals. In any case, the '.new' files should be removed, even in case of tag writing failure and a jaudiotagger bug is filled [we'll probably upgrade to last jaudiotagger release to get a fix for the .new presence.

However, you didn't mention if failure itself is normal or not. If your files or directory are read-only, it is an expected behavior. '''Could you please report if your MP3 files are read-only, for instance by setting tags using another program or a text editor ?'''

1 https://java.net/jira/browse/JAUDIOTAGGER-373

bflorat commented 9 years ago

Commented by bflorat on 25 Aug 2012 15:00 UTC Please check as well that the jaudiotagger prevents avoid the phantom .new files creation by trying the maintenance build #1353 [If your files are read only, you should get an error dialog but no more the '.new' files.

PS for developers: the '.new' file creation problem doesn't occur under Linux, may be a Windows-only issue.

1 http://integration.jajuk.info/jenkins/job/maintenance/1353/

bflorat commented 9 years ago

Commented by bflorat on 25 Aug 2012 19:30 UTC Update from reporter : "I was able to set tags vID3v2 on same mp3 files that failed to write lyrics in Jajuk. The program I regularly use to tag or re-tag is "The Godfather". No issues at all to re-tag. After re-tag I tried to get lyrics using Jajuk, and got the same resul: creation of ".new" file.

After that, also I tried to re-tag same mp3 file with another tagger: Mp3tag d2.52 (from www.mp3tag.de), wich is new to me (never used before); I re-tagged the mp3 file without any problem. Then I tried to get lyrics by using Jajuk, and got the same problem: "new" file was created.

Just want to let you know that granting windows permissions ("full control") over file and folder didn't work either.

After that, I tried the maintenance patch #1353, as you suggested. (By the way, I got an windows warning stating the application Jajuk did not installed correctly, but I continued and was able to work with Jajuk despite windows warning).

Now (with path 1353), I receive an error message suggesting to review permissions, BUT ACTUALLY LYRICS ARE WRITTEN DOWN TO A "txt" file, not to the mp3 tag. Most important: I do not get "new" file. This works for me!; the most important thing is to not get hard disk full by so many "new" files, and to have the lyrics, no matter they are not in the tag. Only I would like to get rid of the error message, as I do actually got the lyrics on txt file.

Thanks!."

bflorat commented 9 years ago

Commented by bflorat on 25 Aug 2012 19:51 UTC

bflorat commented 9 years ago

Commented by bflorat on 28 Aug 2012 20:55 UTC update from reporter : " Thanks for considering my opinion. I am glad you removed the error message; I think there is no point for it, since the lyrics are saved as txt file with patch #1353. By the way, it turns this is the best way to do, because with patch #1353 as it is (displaying error message when not able to save lyrics on mp3 tag), the very same error message does appears when you tries to get lyrics for wav files; the lyrics for wav files are saved, but the message is annoying.

I have no problemas by tagging other fields for the file that failed to save lyrics, and for others too, by using "properties". I was able to save comments and album artist. I confirmed the tag was updated for these files by viewing the tag on another program tagger, the MP3tag I mentioned in my previous email; this other program displayed the information updated within Jajuk (comments and album artist). Before I installed patch #1353, I could not get lyrics for mp3; I tried several times with different files and always got a "new" file.

WIth patch #1353 I am able to get lyrics for other files, both mp3 and wav; the only issue is it always appear the error message stating Jajuk could not save lyrics on mp3 tag, the one that suggests to review permissions; this message is appearing under patch #1353, no matter the files are mp3 or wav.

Regarding the installation of patch #1353, I attach some files to this email, showing screenshots taken from the installation:

jajuk-install-1.jpg shows the installer window showing "installation complete" but previous to push the "next" button. jajuk-install-2.jpg shows the installer window after pushing once the "next" button. This window stays forever, doing nothing (at least nothing that is apparent); if you try pushing again the "next" button the installer halts; you have to end the installer (close the window) by pushing "exit" button or "X" button. jajuk-install-3.jpg shows the message I got after I ended the installation of patch #1353 (on Windowes 7 64 bits); I think is a windows message, not the installer.

I hope this helps. "

bflorat commented 9 years ago

Commented by bflorat on 28 Aug 2012 21:24 UTC

WIth patch #1353 I am able to get lyrics for other files, both mp3 and wav; the only issue is it always appear the error message stating Jajuk could not save lyrics on mp3 tag, the one that suggests to review permissions; this message is appearing under patch #1353, no matter the files are mp3 or wav.

Note that Build #1354 should drop this annoying message.

Regarding the installation of patch #1353, I attach some files to this email, showing screenshots taken from the installation:

Thanks. '''Could you please tell me if this issue also occurred at first jajuk 1.10 installation or only when overriding it (or randomly) ?'''

For packagers : I suspect with may be a launch4j issue [under Seven when using a 64bits JVM : launch4j may switch entirely to 64 bits but izpack installer may use 32 bits libs for its JNI shortcuts work.

1 http://sourceforge.net/tracker/?func=detail&aid=3392784&group_id=95944&atid=613100

jajuk-install-1.jpg shows the installer window showing "installation complete" but previous to push the "next" button. jajuk-install-2.jpg shows the installer window after pushing once the "next" button. This window stays forever, doing nothing (at least nothing that is apparent); if you try pushing again the "next" button the installer halts; you have to end the installer (close the window) by pushing "exit" button or "X" button. jajuk-install-3.jpg shows the message I got after I ended the installation of patch #1353 (on Windowes 7 64 bits); I think is a windows message, not the installer.

I hope this helps. "

bflorat commented 9 years ago

Commented by bflorat on 10 Sep 2012 20:10 UTC Fixed