[mythtv-commits] Ticket #13545: Music scripts: add python3 compatibility

MythTV noreply at mythtv.org
Mon Dec 30 13:47:37 UTC 2019


#13545: Music scripts: add python3 compatibility
------------------------------------+--------------------------
     Reporter:  rcrdnalor           |      Owner:  paulh
         Type:  Patch - Bug Fix     |     Status:  new
     Priority:  minor               |  Milestone:  needs_triage
    Component:  Plugin - MythMusic  |    Version:  Master Head
     Severity:  medium              |   Keywords:  python3
Ticket locked:  0                   |
------------------------------------+--------------------------
 The attached patch adds compatibility to python3 for the
 grabber and lyrics scripts in
 `mythtv/programs/scripts/metadata/Music`.

 Note: The following scripts seem to be broken for python2 and are not
 handled by this patch:
   - Music/lyrics/alsong.py
   - Music/lyrics/baidu.py
   - Music/lyrics/lyricsmode.py



 Tested with
 {{{
 $ python[2,3] filelyrics.py -v
 $ python[2,3] filelyrics.py -d -t
 $ python[2,3] darklyrics.py -v
 $ python[2,3] darklyrics.py -d -t
 $ python[2,3] embedlrc.py -v
 $ python[2,3] embedlrc.py -d -t
 $ python[2,3] genius.py -v
 $ python[2,3] genius.py -d -t
 $ python2 genius.py -s -a "Celine Dion" -b "D'Eux" -n "J'attendais"
 $ python3 genius.py -s -a "Céline Dion" -b "D'Eux" -n "J'attendais"
 $ python[2,3] lyricscom.py -v
 $ python[2,3] lyricscom.py -d -t
 $ python2 lyricscom.py -s -a "Celine Dion" -b "D'Eux" -n "J'attendais"
 $ python3 lyricscom.py -s -a "Céline Dion" -b "D'Eux" -n "J'attendais"
 $ python[2,3] lyricswiki.py -v
 $ python[2,3] lyricswiki.py --d -t
 $ python2 lyricswiki.py -s -a "Celine Dion" -b "D'Eux" -n "J'attendais"
 $ python3 lyricswiki.py -s -a "Céline Dion" -b "D'Eux" -n "J'attendais"
 $ python[2,3] ttplayer.py -v
 $ python[2,3] ttplayer.py -d -t
 $ python[2,3] mbutils.py -v
 $ python[2,3] mbutils.py -d -t
 $ python[2,3] mbutils.py -s -a 'Dire Straits'
 $ python[2,3] mbutils.py -s -a "Céline Dion"
 $ python[2,3] mbutils.py -g -i "847e8a0c-cc20-4213-9e16-975515c2a926"
 $ python[2,3] mbutils.py -r -a "Céline Dion" -b "D'Eux"
 $ python[2,3] mbutils.py -f --id '65528137-f5e3-4d94-8e0c-f984346e4ef6'
 $ python[2,3] mbutils.py --finddisc --cddevice /dev/sr0   -->  Santana:
 Supernatural
 }}}

 Not working grabbers and therefore not handled within this issue:
 {{{
 $ python2 alsong.py -d -t
     --> NOK  urllib2.URLError: <urlopen error [Errno -2] Name or service
 not known>

 $ python2 baidu.py -d -t
     --> NOK   http://music.baidu.com/search/lrc?key=Money For Nothing-Dire
 Straits

 $ python2 lyricsmode.py -d -t
     --> NOK
 }}}

-- 
Ticket URL: <https://code.mythtv.org/trac/ticket/13545>
MythTV <http://www.mythtv.org>
MythTV Media Center


More information about the mythtv-commits mailing list