Ticket #332 (new Bugs)

Opened 8 months ago

Last modified 44 hours ago

command server bugs

Reported by: infl00p Owned by: admin
Priority: 1 Milestone:
Component: Liquidsoap Version: 0.9.2+svn
Keywords: Cc:
Mac OSX: yes Linux: yes
NetBSD: yes Other Operating System: yes
FreeBSD: yes

Description

Hello, I'm using the command server (telnet) to feed a web panel with the status of the radio. My radio plays a randomized playlist source and has a request queue source. When there is a request on the queue playing the on_air command outputs both IDs, the one in the playlist and the one on the queue head.

An example output follows


on_air 48 47 END trace 48 [2010/01/01 10:21:02] Pushed ["/opt/storage/share/Music//OverClocked ReMix? OCR01001 to OCR01900/Final_Fantasy_6_Seized_with_Fury_OC_ReMix.ogg";...]. [2010/01/01 10:21:11] Currently on air. END trace 47 [2010/01/01 10:20:32] Pushed ["/opt/storage/share/Music/OverClocked ReMix? OCR00001 to OCR01000/Final_Fantasy_6_Dancing_Madly_(Second_Form)_OC_ReMix.ogg";...]. [2010/01/01 10:20:32] Entering the secondary queue. [2010/01/01 10:26:32] Entering the primary queue. [2010/01/01 10:26:42] Currently on air. END


This of course messes up my web panel since the song playing is not 48 but 47.

Also if I issue a radio(dot)ogg.skip command it skips both sources and plays the new one in the playlist not the new one in the queue.

I don't know if this is a bug in my script but it's based entirely on the advanced case study script on the site.

script follows


#!/usr/local/bin/liquidsoap

# Settings set("server.telnet",true) set("server.telnet.bind_addr","127.0.0.1") set("server.telnet.port",1234) set("server.telnet.reverse_dns",false)

set("harbor.bind_addr","127.0.0.1") set("harbor.port",8005) set("harbor.password","xxx") set("harbor.reverse_dns",false) set("harbor.timeout",10.)

# sources on_fail = single("/home/xxx/radio/fail.ogg") mpdplayback = input.harbor(id="playlist", "playlist.ogg", buffer=5.)

def mpd_title(m) =

title = mtitle? [("title","#{title} - radio")]

end mpdplayback = map_metadata(mpd_title, strip=true, mpdplayback)

# clock jingle clock = playlist(mode="random",reload=3600, "/home/xxx/radio/clock.list")

# User requests req = request.equeue(id="request")

def req_title(m) =

title = mtitle? [("title","#{title} - radio requests")]

end req = map_metadata(req_title, strip=true, req)

randomplay = smart_crossfade(start_next=2., normalize(playlist(mode="random",reload=1200,"/opt/storage/share/Music/")))

def random_title(m) =

title = mtitle? [("title","#{title} - radio random play")]

end randomplay = map_metadata(random_title, strip=true, randomplay)

scheduler = add(weights=[1,4],

[fallback([ mpdplayback, req, randomplay, on_fail ]),

switch([({ 0m and 0s-5s },delay(5.,clock))])])

def live_title(m) =

[("title","Now Live @ radio")]

end

def full

emission = input.harbor("emission.ogg") emission = map_metadata(live_title, strip=true, emission) emission = strip_blank(emission, length=10., threshold=-50.) fallback(track_sensitive=false, [ emission, scheduler ])

end

# Outputs out = output.icecast.vorbis(

host="localhost", port= 8000, password = "xxx", quality=5., public=true, name="Radio", genre="misc", url=" http://radio", description="Radio")

out(mount="radio.ogg",full)

Change History

Changed 8 months ago by infl00p

Found that it's caused by smart_crossfade but I believe that on_air and skip should work on the playing song.

Changed 44 hours ago by 太阳能

China is the world's commitment to implement energy-saving emission reduction targets, to enhance policy support the new energy economy strategy, accelerating the construction of solar photovoltaic technology in rural and urban areas of the application, the relevant state ministries launch solar roofs program. Solar roof planned efforts to break through the integration and solution architecture design of a lack of optical, optoelectronic products combined with low level of construction, optical and network problems, low market awareness of the problem. Solar Roofs Plan into consideration economic and social benefits and other factors, at this stage of economic development, industrial base cities to actively promote a better solar roofs, building integrated photovoltaic curtain wall and other optical model; actively support development in rural and remote areas from the net-generation, implementation of transmission to rural areas, the implementation of the national farmer-friendly policy. Solar roof planned to mobilize all sectors of society through the development of demonstration projects and promote the implementation of relevant national policies. Demonstration projects to strengthen advocacy, to expand its influence, increase market awareness, formation and development of solar photovoltaic products, a good social atmosphere; to promote the implementation of tariff and other Internet-sharing policy, the formation of policy together, amplifying the effect of policies; the optical construction applications as an important building energy efficiency content, in new construction, existing building energy-saving, actively promote the use of urban lighting. Policy limit sun roof demonstration project must be greater than 50kW, which requires at least 400 square meters of total floor area, construction is difficult to participate in the general population, eligible owners will focus on schools, hospitals and government and other public and commercial buildings. Ministry of Finance to consider subsidies, the cost of electricity can be reduced to 0.58 yuan / kWh. Whether PV electricity price electricity price in the thermal power given premium is not clear, but even without the premium, due to lower power generation cost sales price, the owners are still building solar power projects to generate electricity for personal use, replacement power purchased from power. Moreover, local governments can be expected to give additional subsidies, electricity costs will decline further  http://solar-poweronline.info/

Note: See TracTickets for help on using tickets.