im using Liquidsoap 0.9.2-2 from sourceforge, for now im using lastfmsubmitd
for scrobbling and worked good but sometimes i have issue when trying to
calculate file duration which takes time and my solution is using
add_timeout to the file duration function

    set("scheduler.fast_queues",2)

    def submit_lastfm(m)
      fm_artist = quote(m["artist"])
      fm_album  = quote(m["album"])
      fm_song   = quote(m["title"])
      log("getduration -> #{fm_artist}")
      fm_duration = int_of_float(file.duration(m["filename"]))
      log("scrobble -> #{fm_artist}")
      system("python
/home/deadmediafm/deadmediafm_script/lastfmsubmitd-1.0.6/lastfmsubmit
--artist #{fm_artist} --title #{fm_song} --length #{fm_duration} --album
#{fm_album}")
    end

    def submit_dispatch(m)
        add_timeout(10.,{ submit_lastfm(m);(-1.) })
    end

songs = on_track(submit_dispatch, songs)

is this correct?

thanks!


On Tue, May 18, 2010 at 12:42 PM, Romain Beauxis <[email protected]>wrote:

> Le mardi 18 mai 2010 06:43:24, David Baelde a écrit :
> > I confirm that this is a bug. Such an error should not crash
> > liquidsoap, and should not even stop the corresponding operator. Shit
> > happens over the network and we intend to support it. We'll fix it as
> > soon as possible (at least in the SVN version).
>
> That's the other question I wanted to ask: what version of liquidsoap are
> you
> using ?
>
> I do think this error crashes the SVN..
>
> Romain
>
>
> ------------------------------------------------------------------------------
>
> _______________________________________________
> Savonet-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/savonet-users
>
------------------------------------------------------------------------------

_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users

Reply via email to