You are not logged in.

#51 2012-09-29 16:35:44

OK100
Member
From: [U==]
Registered: 2010-04-26
Posts: 453

Re: Lyvi - command-line lyrics (and more!) viewer

zeltak wrote:

1.it seems like lyvi stopped looking first at the local images stored and goes and grabs the images from the internet first

Fixed.

zeltak wrote:

2. the lyrics are saved by file name.lyric and not tag name.lyric can there be an option to change that?

It's now possible to change that with save_lyrics_format option.

zeltak wrote:

1.auto advance lyrics- can we have the lyrics auto scroll? ideally this would be done using some basic calculation based on song length etc. but just a stupid scroll option by a constant rate would work great

Coming soon smile I will probably make it with constant rate that can be increased/decreased and toggled on/off.

zeltak wrote:

2. consider an option in config to show album cover instead of artist image? maybe also an option to toggle between them or auto switch every X seconds.

You can now toggle background image with 's' key, also there's a new bg_type option.

zeltak wrote:

3.related to above maybe ability to launch lyvi with a alternate config so we could have 2 lyvi windows tiled one with a album view (with lyrics) and one with artist view (with artist image and artist info)

There's a new command-line option for that (see lyvi -h)

Feel free to test new features and please let me know if something is not working.
I'm waiting for other ideas cool

Last edited by OK100 (2012-09-29 16:37:38)

Offline

#52 2012-09-29 17:46:16

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

-

Last edited by zeltak (2012-09-29 18:00:27)

Offline

#53 2012-09-29 17:50:23

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

heheh HOLY CRAP that was fast

as always amazing amazing work. i do have a new bug it seems that prevents lyvi from firing up:

% lyvi                                                                                                                                                                                          !254
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1028, in <module>
    curses.wrapper(main)
  File "/usr/lib/python3.2/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 988, in main
    u.album = p.album
AttributeError: 'Mpd' object has no attribute 'album'

any idea?

Also for the album cover would the user be able to specify where the covers are stored, IE in my case as opposed to the artist image which is stored in the artist root folder the album image is another level down and stored in the album folder IE:

/home/zeltak/Zmusic/N/Neil Young/Le Noise/folder.jpg

btw out of curiosity, which music player is your main player ?

thx alot

Z.

PS if i can help in anyway (testing ofc, documentation etc) please let me know!!

Offline

#54 2012-09-29 18:33:38

OK100
Member
From: [U==]
Registered: 2010-04-26
Posts: 453

Re: Lyvi - command-line lyrics (and more!) viewer

zeltak wrote:

heheh HOLY CRAP that was fast

as always amazing amazing work. i do have a new bug it seems that prevents lyvi from firing up:

% lyvi                                                                                                                                                                                          !254
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1028, in <module>
    curses.wrapper(main)
  File "/usr/lib/python3.2/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 988, in main
    u.album = p.album
AttributeError: 'Mpd' object has no attribute 'album'

any idea?

Fixed smile

zeltak wrote:

Also for the album cover would the user be able to specify where the covers are stored, IE in my case as opposed to the artist image which is stored in the artist root folder the album image is another level down and stored in the album folder IE:

/home/zeltak/Zmusic/N/Neil Young/Le Noise/folder.jpg

I'll add this option soon.

zeltak wrote:

btw out of curiosity, which music player is your main player ?

thx alot

Z.

PS if i can help in anyway (testing ofc, documentation etc) please let me know!!

My main players are cmus and shell-fm.
You can test lyvi with some other players for me if you want, as I really don't use lyvi with them.

Offline

#55 2012-09-30 00:48:28

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

hi again

as you requested im testing some other players.. funny enough cmus didnt launch ;-):


zeltak@voices ~
  % lyvi                                                                                                                                         !282
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1028, in <module>
    curses.wrapper(main)
  File "/usr/lib/python3.2/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 988, in main
    u.album = p.album
AttributeError: 'Cmus' object has no attribute 'album'

vlc worked well and ill continue with the other players in the next few days

can i request another view to add ? i would really  like a "empty" view  where only song metadata info is shown  in the first line or two (user can choose which maybe? artist,track etc... i would use it to present a clean album image alongside a lyrics windows.

i have some more ideas but they involve reading/writing tags, i dont know how you feel about that and if you want to dive into that. some idea examples include saving the downloaded lyrics into the LYRICS tag, reading and writing rating fields etc.

Since extra tag fields are non standard among all players there is a commonly used  FLOSS  tag  guide used by many FLOSS players (gmb, amarok etc) . if interested you can take a look at  the Free Media Player Specifications Tag Specification:

http://gitorious.org/xdg-specs/xdg-spec … cation.txt

for how they define rating (FMPS_RATING) etc...


thx and all the best

Z

Last edited by zeltak (2012-09-30 01:02:01)

Offline

#56 2012-10-03 20:41:38

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

Hya again


lyvi suddenly stopped working:

  % lyvi                                                                                                                                                                                          !526
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1028, in <module>
    curses.wrapper(main)
  File "/usr/lib/python3.2/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 988, in main
    u.album = p.album
AttributeError: 'Mpd' object has no attribute 'album'



any clue?

also it seems like i would really enjoy a "clean view" (IE no  text just image) if that's possible smile

thx again

Z

Offline

#57 2012-10-04 07:41:28

OK100
Member
From: [U==]
Registered: 2010-04-26
Posts: 453

Re: Lyvi - command-line lyrics (and more!) viewer

Hello,

zeltak wrote:

Hya again


lyvi suddenly stopped working:

  % lyvi                                                                                                                                                                                          !526
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1028, in <module>
    curses.wrapper(main)
  File "/usr/lib/python3.2/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 988, in main
    u.album = p.album
AttributeError: 'Mpd' object has no attribute 'album'


any clue?

It's already fixed. Please update lyvi to latest commit and try again.

zeltak wrote:

also it seems like i would really enjoy a "clean view" (IE no  text just image) if that's possible smile

I'm currently working on features you requested and it should be ready in a few days.

Best regards
OK100

Offline

#58 2012-10-04 12:36:42

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

Hi

As always fix works like a charm smile

no rush with the features, just reporting bugs i found smile

thx alot again for everything, its so much appreciated (not just by me bit other numerous arch users! smile)

Z.

Offline

#59 2012-10-04 13:16:26

bslackr
Member
Registered: 2012-01-27
Posts: 131

Re: Lyvi - command-line lyrics (and more!) viewer

I got this error when I tried to run lyvi with mpd:

Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1019, in <module>
    curses.wrapper(main)
  File "/usr/lib/python3.2/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 937, in main
    p.status()
  File "/usr/bin/lyvi", line 313, in status
    music_dir = line.split('"')[1]
IndexError: list index out of range

I changed line 313 to "music_dir = line.split('"')[0]" and that fixed it but I don't understand why that worked, or why the problem was there to begin with. The line in question is

music_directory        "~/music"

If it is split at the quotes than music_directory should be [0] and ~/music [1]. It's working for me now, but just figured I'd let you know, not sure what's going on here.

Offline

#60 2012-10-05 12:26:51

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

Hya again

found another bug. this seems to happen only when you play external files in mpd (not in libraraym through a unix socket):

  % lyvi                                                     !661
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1019, in <module>
    curses.wrapper(main)
  File "/usr/lib/python3.2/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 986, in main
    sleep(1)
KeyboardInterrupt



as always thx alot!

Z

Offline

#61 2012-10-05 17:39:36

Rasi
Member
From: Germany
Registered: 2007-08-14
Posts: 1,832
Website

Re: Lyvi - command-line lyrics (and more!) viewer

lyvi stopped working for me.
my config is simple. a mpd_host and a mpd_port line. thats all.

First, it crashes instantly, if i dont have a ~/.mplayer/log file. Even tho i dont even want to use it with mplayer.
Second, if i create that file, it doesnt show a single thing. Just a message in its main window saying "Missing Tags"


He hoped and prayed that there wasn't an afterlife. Then he realized there was a contradiction involved here and merely hoped that there wasn't an afterlife.

Douglas Adams

Offline

#62 2012-10-06 18:15:14

OK100
Member
From: [U==]
Registered: 2010-04-26
Posts: 453

Re: Lyvi - command-line lyrics (and more!) viewer

@bslackr: Are you using latest git version? Can I see your whole mpd config?

@zeltak: Let me take a look at it.

@Rasi: Add

player = mpd

to your config file (see below)

@all:
Changes in the latest commit:

  • Hide UI: 'h' key
    Configuration option:

    ui_hidden = False
  • Autoscroll: toggle with 'i' key, faster - 'p' key, slower - 'o' key
    Configuration options:

    autoscroll = False
    autoscroll_time = 10
    autoscroll_step = 1
  • Local images: New (or changed) options:

    bg_local = False
    bg_path_artist = None
    bg_path_cover = None

    You can use <artist>, <artistinitial> and <album> variables in the paths

  • New option - player: Allows to set default player
    Configuration option:

    player = None
  • Background: PIL is now used for modifying images instead of imagemagick. Brings another dependency on python-imaging, though. Also, I had to remove python3 support as python-imaging is not available for python3 yet.
    New (or changed) options:

    bg_color = 000000
    bg_opacity = 0.15

Hope that's all tongue
Documentation is still missing, though.

...and a screenshot:
tZnMxcQ
I'm using urxvt like an image viewer... LOL

Feedback welcome.

Last edited by OK100 (2012-10-07 07:11:06)

Offline

#63 2012-10-07 00:41:24

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

hya

first of all thx for the amazing new features, its greatly appreciated!

it seems like though the new version isnt working for me in alot of areas.

fitst i cant get any images showing at all.

also using the option -c (for an alternative config file) default to the default config.

see  2 configs:

http://paste.xinu.at/81xo/
http://paste.xinu.at/heC/


and image showing the issue:
http://paste.xinu.at/ZT9/

see in the above screenshot there is an error it also outputs with the lyrics

thx alot again, lyvi is just gets better with age like a good wine ;-)

z.

Offline

#64 2012-10-07 07:10:37

OK100
Member
From: [U==]
Registered: 2010-04-26
Posts: 453

Re: Lyvi - command-line lyrics (and more!) viewer

Hi,

zeltak wrote:

fitst i cant get any images showing at all.

Fixed. You probably wants bg_opacity value lower than 1, not 2 (see wiki). Also, make sure you have python-imaging package installed.

zeltak wrote:

also using the option -c (for an alternative config file) default to the default config.

This works fine for me. Can you post here whole command you use to run lyvi?

By the way, your mpd_config_file option should be /home/zeltak/.mpdconf, not $HOME/.mpdconf.

zeltak wrote:

and image showing the issue:
http://paste.xinu.at/ZT9/

see in the above screenshot there is an error it also outputs with the lyrics

Do you still have this issue with latest commits?

zeltak wrote:

thx alot again, lyvi is just gets better with age like a good wine ;-)

z.

You're welcome smile

Offline

#65 2012-10-07 07:15:34

Sirsurthur
Member
Registered: 2009-02-02
Posts: 114

Re: Lyvi - command-line lyrics (and more!) viewer

Hello,

While trying to compile latest lyvi-git, I get a problem with its dependency python2-glyr-git.

I get the following output : http://pastebin.com/Wm1vm0ep

Have you an idea of the mistake I made ?

Thanks !

Last edited by Sirsurthur (2012-10-07 07:16:42)

Offline

#66 2012-10-07 08:01:13

bslackr
Member
Registered: 2012-01-27
Posts: 131

Re: Lyvi - command-line lyrics (and more!) viewer

OK100 wrote:

@bslackr: Are you using latest git version? Can I see your whole mpd config?

Yes, I am using the latest git (last updated right before my initial post).

Here is my .mpdconf minus the comments.

music_directory		"~/music"
playlist_directory "~/.mpd/playlists"
db_file "~/.mpd/mpd.db"
pid_file "~/.mpd/mpd.pid"
state_file "~/.mpd/mpdstate"

gapless_mp3_playback			"yes"
metadata_to_use	"albumartist,artist,album,title,track,name,genre,date,composer,performer,disc"

input {
        plugin "curl"
}


audio_output {
	type		"pulse"
	name		"PulseAudio"
}


replaygain			"album"
replaygain_preamp		"0"

Offline

#67 2012-10-07 10:03:42

SahibBommelig
Member
From: Germany
Registered: 2010-05-28
Posts: 80

Re: Lyvi - command-line lyrics (and more!) viewer

Sirsurthur wrote:

Hello,

While trying to compile latest lyvi-git, I get a problem with its dependency python2-glyr-git.

I get the following output : http://pastebin.com/Wm1vm0ep

Have you an idea of the mistake I made ?

Thanks !

Looks like you have an old libglyr version installed. (It is the library that does actually find the metadata in the web).
Please update and try again:

$ yaourt -S glyr-git
$ glyrc --version                                                                                                                                          
Version 1.0.0 (Bloody Boar) of [Oct  7 2012] compiled at [05:13:17]
...

@zeltak: Please use code tags when posting tracebacks. smile

Offline

#68 2012-10-07 11:53:41

Sirsurthur
Member
Registered: 2009-02-02
Posts: 114

Re: Lyvi - command-line lyrics (and more!) viewer

@SahibBommelig : Indeed it worked, thanks a lot !

Offline

#69 2012-10-07 12:05:57

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

Hi again

yes the errors still happen even in the latest commit. see screen:

http://paste.xinu.at/Tit/


and error:
                               
         lyrics    All (10s)Exception in thread Thread-3:
                            Traceback (most recent call last):
                                                                File "/usr/lib/python2.7/threading.py", line 551, in __bootstrap_inner
                                                                                                                                          self.run()
                                                                                                                                                      File "/usr/lib/python2.7/threading.py", line 504, in run
                                                            self.__target(*self.__args, **self.__kwargs)
                                                                                                          File "/usr/bin/lyvi", line 283, in get_and_update
         f = codecs.open('%s/%s' % (path, lyric_filename), 'w', 'utf-8')
                                                                          File "/usr/lib/python2.7/codecs.py", line 881, in open
                                                                                                                                    file = __builtin__.open(filename, mode, buffering)
                                IOError: [Errno 2] No such file or directory: u'no/A/Art Garfunkel/Everything Waits To Be Noticed/07 - Perfect Moment.lyric'                           
                                 


the lyrics still switch when the songs changes but the error is there.

as for the alternate config it seems it is actually reading it (the artist bio comes on) but it still ignores the hidden UI line and i  still get a black background using the same parameters that now work in the default config. here is the alt config updated:

http://paste.xinu.at/SF5/

thx again

Z

Offline

#70 2012-10-07 14:42:48

OK100
Member
From: [U==]
Registered: 2010-04-26
Posts: 453

Re: Lyvi - command-line lyrics (and more!) viewer

@bslackr: Latest commit should fix your issue. If not, please post your complete mpd config (WITH comments).

@zeltak:
You probably have similar issue as bslackr, so try updating again.

zeltak wrote:

as for the alternate config it seems it is actually reading it (the artist bio comes on) but it still ignores the hidden UI line and i  still get a black background using the same parameters that now work in the default config. here is the alt config updated:
http://paste.xinu.at/SF5/

Fixed with latest commit (hopefully big_smile).
Also, please use code tag when posting tracebacks as SahibBommelig suggested smile.

Offline

#71 2012-10-07 16:54:05

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

Hi again

i have no idea what a code tag is but i assume its the forum tag option. please let me know if thats not what you meant

the error message in the lyrics view seems to be fixed.

the alternate config wont start now:



  % lyvi -c /home/zeltak/.config/lyvi/rc_alt                                                  !784
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1147, in <module>
    curses.wrapper(main)
  File "/usr/lib/python2.7/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 1051, in main
    ui = Ui(stdscr)
  File "/usr/bin/lyvi", line 885, in __init__
    self.hide()
  File "/usr/bin/lyvi", line 962, in hide
    bg_unset()
  File "/usr/bin/lyvi", line 184, in bg_unset
    image = Image.new('RGB', (100, 100), '#' + SETTINGS['bg_color'])
TypeError: cannot concatenate 'str' and 'int' objects

thx

Z.

Offline

#72 2012-10-07 17:11:38

OK100
Member
From: [U==]
Registered: 2010-04-26
Posts: 453

Re: Lyvi - command-line lyrics (and more!) viewer

zeltak wrote:

Hi again

i have no idea what a code tag is but i assume its the forum tag option. please let me know if thats not what you meant

the error message in the lyrics view seems to be fixed.

the alternate config wont start now:



  % lyvi -c /home/zeltak/.config/lyvi/rc_alt                                                  !784
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1147, in <module>
    curses.wrapper(main)
  File "/usr/lib/python2.7/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 1051, in main
    ui = Ui(stdscr)
  File "/usr/bin/lyvi", line 885, in __init__
    self.hide()
  File "/usr/bin/lyvi", line 962, in hide
    bg_unset()
  File "/usr/bin/lyvi", line 184, in bg_unset
    image = Image.new('RGB', (100, 100), '#' + SETTINGS['bg_color'])
TypeError: cannot concatenate 'str' and 'int' objects

thx

Z.

Fixed smile

You are finally using code tags tongue

Last edited by OK100 (2012-10-07 17:13:06)

Offline

#73 2012-10-07 17:31:59

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

hya, updated from git but still get an error smile


  % lyvi -c /home/zeltak/.config/lyvi/rc_alt                                                                                                                                                      !790
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1147, in <module>
    curses.wrapper(main)
  File "/usr/lib/python2.7/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 1051, in main
    ui = Ui(stdscr)
  File "/usr/bin/lyvi", line 885, in __init__
    self.hide()
  File "/usr/bin/lyvi", line 962, in hide
    bg_unset()
  File "/usr/bin/lyvi", line 184, in bg_unset
    image = Image.new('RGB', (100, 100), '#' + str(SETTINGS['bg_color']))
  File "/usr/lib/python2.7/site-packages/PIL/Image.py", line 1761, in new
    color = ImageColor.getcolor(color, mode)
  File "/usr/lib/python2.7/site-packages/PIL/ImageColor.py", line 101, in getcolor
    color = getrgb(color)
  File "/usr/lib/python2.7/site-packages/PIL/ImageColor.py", line 97, in getrgb
    raise ValueError("unknown color specifier: %r" % color)
ValueError: unknown color specifier: '#0'

any idea?

this is my alt_config

ui_hidden = True

bg=True

bg_opacity=0.5

bg_color=000000

bg_local=True
bg_path_artist=/home/zeltak/Zmusic/<artistinitial>/<artist>/<album>/
bg_type=cover

mpd_config_file=/home/zeltak/.mpdconf

mpd_host=localhost
mpd_port=6600
player=mpd

view=artistbio
save_lyrics=False

best

Z

Offline

#74 2012-10-07 17:55:32

OK100
Member
From: [U==]
Registered: 2010-04-26
Posts: 453

Re: Lyvi - command-line lyrics (and more!) viewer

zeltak wrote:

hya, updated from git but still get an error smile


  % lyvi -c /home/zeltak/.config/lyvi/rc_alt                                                                                                                                                      !790
Traceback (most recent call last):
  File "/usr/bin/lyvi", line 1147, in <module>
    curses.wrapper(main)
  File "/usr/lib/python2.7/curses/wrapper.py", line 43, in wrapper
    return func(stdscr, *args, **kwds)
  File "/usr/bin/lyvi", line 1051, in main
    ui = Ui(stdscr)
  File "/usr/bin/lyvi", line 885, in __init__
    self.hide()
  File "/usr/bin/lyvi", line 962, in hide
    bg_unset()
  File "/usr/bin/lyvi", line 184, in bg_unset
    image = Image.new('RGB', (100, 100), '#' + str(SETTINGS['bg_color']))
  File "/usr/lib/python2.7/site-packages/PIL/Image.py", line 1761, in new
    color = ImageColor.getcolor(color, mode)
  File "/usr/lib/python2.7/site-packages/PIL/ImageColor.py", line 101, in getcolor
    color = getrgb(color)
  File "/usr/lib/python2.7/site-packages/PIL/ImageColor.py", line 97, in getrgb
    raise ValueError("unknown color specifier: %r" % color)
ValueError: unknown color specifier: '#0'

any idea?

this is my alt_config

ui_hidden = True

bg=True

bg_opacity=0.5

bg_color=000000

bg_local=True
bg_path_artist=/home/zeltak/Zmusic/<artistinitial>/<artist>/<album>/
bg_type=cover

mpd_config_file=/home/zeltak/.mpdconf

mpd_host=localhost
mpd_port=6600
player=mpd

view=artistbio
save_lyrics=False

best

Z

Hope it's working with latest commit big_smile

Offline

#75 2012-10-07 18:41:48

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 165

Re: Lyvi - command-line lyrics (and more!) viewer

heheh ok it does actually run now but i still get the black box in the alt config (it uses covers). normal config with backdrop and lyrics works great though smile

Z.

Offline

Board footer

Powered by FluxBB