Bugs item #1565765, was opened at 2006-09-26 14:21
Message generated for change (Comment added) made by johnmolohan
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=446895&aid=1565765&group_id=46652
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: music
Group: 1.5.x svn
Status: Pending
Resolution: Fixed
Priority: 5
Submitted By: Duncan Webb (duncanwebb)
Assigned to: Nobody/Anonymous (nobody)
Summary: Coversearch crashes when artist or album has unicode char
Initial Comment:
Hi all,
These is an unicode error in freevo-1.5.4 coversearch
when an artist or
album name contains none ascii characters.
audio/plugins/coversearch.py line: 190 can be changed to:
dict_tmp = { "artist":
artist.encode('ascii','replace'), "album":
album.encode('ascii','replace') }
which stop a crash.
But I feel that there is a better fix for this, but
can't figure it out.
----------------------------------------------------------------------
Comment By: John Molohan (johnmolohan)
Date: 2006-10-04 20:37
Message:
Logged In: YES
user_id=774680
Seems to work well.
----------------------------------------------------------------------
Comment By: Duncan Webb (duncanwebb)
Date: 2006-09-30 13:20
Message:
Logged In: YES
user_id=104395
This is now fixed, at least for latin-1 locales.
Searching amazon seems to use latin-1 and the message box is
also correct.
Applied in r8280.
----------------------------------------------------------------------
Comment By: Duncan Webb (duncanwebb)
Date: 2006-09-29 05:46
Message:
Logged In: YES
user_id=104395
That's exactly what the patch was supposed to stop. The real
problem is what encoding can be used coversearch when the
artist of album contains a non-ascii character. Trouble is I
don't know.
May be someone knows and could say what could or should be done.
----------------------------------------------------------------------
Comment By: John Molohan (johnmolohan)
Date: 2006-09-28 21:04
Message:
Logged In: YES
user_id=774680
A traceback :(
Traceback (most recent call last):
File "/usr/lib/python2.4/site-packages/freevo/main.py",
line 321, in eventhandler
app.eventhandler(event)
File "/usr/lib/python2.4/site-packages/freevo/menu.py",
line 561, in eventhandler
action( arg=arg, menuw=self )
File "/usr/lib/python2.4/site-packages/freevo/menu.py",
line 87, in select
self.function(arg=self.arg, menuw=menuw)
File
"/usr/lib/python2.4/site-packages/freevo/audio/plugins/coversearch.py",
line 191, in cover_search_file
box = PopupBox(text=_( 'No matches for %(artist)s -
%(album)s' ) % dict_tmp )
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in
position 7: ordinal not in range(128)
----------------------------------------------------------------------
Comment By: Duncan Webb (duncanwebb)
Date: 2006-09-28 08:34
Message:
Logged In: YES
user_id=104395
That's what I expect to happen. What happens if the reverse
patch is applied, does it find the cover or do you get a crash?
Thanks
----------------------------------------------------------------------
Comment By: John Molohan (johnmolohan)
Date: 2006-09-27 19:35
Message:
Logged In: YES
user_id=774680
I tried this on a directory called sigur rós and get no
traceback but an osd saying no matches found for sigur_r?s.
----------------------------------------------------------------------
Comment By: Duncan Webb (duncanwebb)
Date: 2006-09-26 14:21
Message:
Logged In: YES
user_id=104395
Fix applied
----------------------------------------------------------------------
Comment By: Duncan Webb (duncanwebb)
Date: 2006-09-26 14:21
Message:
Logged In: YES
user_id=104395
Patch applied to branches/rel-1-5/freevo at:
svn://svn.freevo.org/freevo/branches/rel-1-5/freevo
Please test
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=446895&aid=1565765&group_id=46652
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Freevo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-devel