Hi, These are probably 2 different issues.
To play audio on Linux, you need to have mplayer installed and make sure you have it in your path. With respect to Unicode filenames, could you check for me if on your system adding an image to a card (both with Unicode and non-Unicode filenames) works? Thanks! Peter From: [email protected] [mailto:[email protected]] On Behalf Of David Bailey Sent: 08 October 2015 09:12 To: mnemosyne-proj-users <[email protected]> Subject: Re: [mnemosyne-proj-users] Bug report Sorry for the late response, I thought I had email notifications turned on but apparently not. Anyway, with version 2.3.4 this problem is fixed (thanks!). However, now I've encountered a new, unrelated bug with the desktop client only -- audio won't play. When the name of the audio file is ascii-only (e.g. hola.mp3), the audio just fails to play but with no error shown. However, with utf-8 file names an error is shown: Traceback (innermost last): File "/usr/lib/python2.7/site-packages/mnemosyne/pyqt_ui/add_cards_dlg.py", line 155, in preview dlg = PreviewCardsDlg(self.component_manager, cards, tag_text, self) File "/usr/lib/python2.7/site-packages/mnemosyne/pyqt_ui/preview_cards_dlg.py", line 44, in __init__ self.update_dialog() File "/usr/lib/python2.7/site-packages/mnemosyne/pyqt_ui/preview_cards_dlg.py", line 74, in update_dialog self.set_answer(card.answer()) File "/usr/lib/python2.7/site-packages/mnemosyne/libmnemosyne/card.py", line 96, in answer (self, render_chain, **render_args) File "/usr/lib/python2.7/site-packages/mnemosyne/libmnemosyne/card_type.py", line 75, in render_answer render_answer(card, **render_args) File "/usr/lib/python2.7/site-packages/mnemosyne/libmnemosyne/render_chain.py", line 142, in render_answer return self._render(card, fact_keys, decorators, **render_args) File "/usr/lib/python2.7/site-packages/mnemosyne/libmnemosyne/render_chain.py", line 153, in _render card, fact_key, **render_args) File "/usr/lib/python2.7/site-packages/mnemosyne/pyqt_ui/mplayer_audio.py", line 48, in run copy(sound_file.replace("file:///<file:///\\>", ""), new_name) File "/usr/lib/python2.7/site-packages/mnemosyne/libmnemosyne/utils.py", line 85, in copy copyfile(src, dst) File "/usr/lib/python2.7/site-packages/mnemosyne/libmnemosyne/utils.py", line 61, in copyfile fsrc = open(src, 'rb') IOError: [Errno 2] No such file or directory: u'home/david/.local/share/mnemosyne/default.db_media/\u8003\u3048\u308b.mp3' Don't know why the error dialog only appears when the filename contains utf-8 characters. Anyway I think the problem is simply a missing slash -- i.e. u'home/david/.local/share/mnemosyne/default.db_media/\u8003\u3048\u308b.mp3' should be u'/home/david/.local/share/mnemosyne/default.db_media/\u8003\u3048\u308b.mp3'. I tested this calling open() in a python2 shell (without attempting to play the files) and it seemed to work, but without the leading slash it gave an error like this. I don't have any cards with another type of media (e.g. images) but I suspect that these won't work on the desktop client either (unless the code handling audio is significantly different to the code handling images). The problem doesn't apply to the Android app, which still plays audio fine. On Tuesday, 29 September 2015 19:08:55 UTC+1, Peter Bienstman wrote: Hi, Please delete /sdcard/Mnemosyne on your phone, and then upgrade both the client and the server to 2.3.4 RC1: https://groups.google.com/forum/#!topic/mnemosyne-proj-users/9DP5Lj6zPE4 Also make sure that during the sync you stay in Wifi coverage. Let me know if the problem still occurs, and if it e.g. also occurs on a dummy sync, i.e. pressing sync even though there are no changes to sync. Cheers, Peter From: [email protected]<javascript:> [mailto:[email protected]<javascript:>] On Behalf Of David Bailey Sent: 28 September 2015 21:47 To: mnemosyne-proj-users <[email protected]<javascript:>> Subject: [mnemosyne-proj-users] Bug report Hi, just posting here with a detailed version of the bug report that I gave on the app review. The bug occurs when I add new cards and learn them from the desktop app, then sync from the Android app. Might be worth noting that I usually don't have any unreviewed cards before adding new cards. When I try to sync first, it'll give an error saying that the sync failed on both the phone and computer. Once this is dismissed and I sync again, the app asks if I'd like to fetch the remote version (i.e. computer copy) or cancel the sync. After refetching the whole database/media, the sync successfully completes. I've attached screenshots from the app of the error occurring. At the end of the Python traceback, there was a UnicodeEncodeError -- I'm studying Japanese flashcards, not sure if this is part of the cause of the error. Also, I have a feeling that if I added new words on the desktop app, then synced before learning them, learnt them on the computer and synced again, then the error wouldn't occur. (i.e. same but sync before learning cards) Desktop app information (output of pacman -Qi mnemosyne) -- I installed from the Arch User Repository: Name : mnemosyne Version : 2.3.3-1 Description : A flash-card tool with a sophisticated card review algorithm Architecture : x86_64 URL : http://www.mnemosyne-proj.org Licences : GPL Groups : None Provides : None Depends On : python2-pyqt4 python2-matplotlib python2-cherrypy python2-webob Optional Deps : texlive-core: support for mathematical formulae in cards Required By : None Optional For : None Conflicts With : mnemosyne-bzr Replaces : None Installed Size : 3.52 MiB Packager : David Bailey <[email protected]<javascript:>> Build Date : Tue 25 Aug 2015 11:01:39 BST Install Date : Tue 25 Aug 2015 11:01:52 BST Install Reason : Explicitly installed Install Script : Yes Validated By : None Android app information (screenshot from Solid Explorer's application manager): <https://lh3.googleusercontent.com/-MdiMEcS0GwA/VgmYmAdlNbI/AAAAAAAAGG4/V6ifg228W48/s1600/Screenshot_2015-09-28-20-42-44.png> <https://lh3.googleusercontent.com/-MdiMEcS0GwA/VgmYmAdlNbI/AAAAAAAAGG4/V6ifg228W48/s1600/Screenshot_2015-09-28-20-42-44.png> Hope this can help you to fix the problem!<https://lh3.googleusercontent.com/-MdiMEcS0GwA/VgmYmAdlNbI/AAAAAAAAGG4/V6ifg228W48/s1600/Screenshot_2015-09-28-20-42-44.png> David<https://lh3.googleusercontent.com/-MdiMEcS0GwA/VgmYmAdlNbI/AAAAAAAAGG4/V6ifg228W48/s1600/Screenshot_2015-09-28-20-42-44.png> -- You received this message because you are subscribed to the Google Groups "mnemosyne-proj-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/mnemosyne-proj-users/e19d2913-cf92-415c-9f39-0e341773b0b0%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.<https://lh3.googleusercontent.com/-MdiMEcS0GwA/VgmYmAdlNbI/AAAAAAAAGG4/V6ifg228W48/s1600/Screenshot_2015-09-28-20-42-44.png> -- You received this message because you are subscribed to the Google Groups "mnemosyne-proj-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/mnemosyne-proj-users/6f4f1211-0536-42a1-bd02-f748d93d70f0%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.<https://lh3.googleusercontent.com/-MdiMEcS0GwA/VgmYmAdlNbI/AAAAAAAAGG4/V6ifg228W48/s1600/Screenshot_2015-09-28-20-42-44.png> -- You received this message because you are subscribed to the Google Groups "mnemosyne-proj-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/mnemosyne-proj-users/83f45a06124c4dbb86e28aa9ddc94a22%40xmail102.UGent.be. For more options, visit https://groups.google.com/d/optout.
