Re: [Savonet-users] [savonet/liquidsoap] Random playlists (#600)

2018-08-22 Thread Niall Lindsay
How can I use check_next I can’t find documentation for its use. Thanks.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/600#issuecomment-415208829--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Audio stream becomes blank (#572)

2018-08-22 Thread Niall Lindsay
Also @toots I attempted opam install of liquidsoap and I get this error on run.

https://user-images.githubusercontent.com/9781846/44161386-0e0c1e00-a0b5-11e8-977e-418eb83c5d97.png
^ above imagd

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/572#issuecomment-415172289--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Audio stream becomes blank (#572)

2018-08-22 Thread Niall Lindsay
I was thinking earlier maybe it’s the mksafe() coming into action producing a 
blank stream of the sources are failing

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/572#issuecomment-415171619--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Audio stream becomes blank (#572)

2018-08-22 Thread Niall Lindsay
Current script that I’m having problems with

‘’’#!/usr/bin/liquidsoap


Re: [Savonet-users] [savonet/liquidsoap] Telnet is not working properly (#610)

2018-08-22 Thread dromer
Try this:

```
set("server.telnet.bind_addr", "127.0.0.1")
set("server.telnet.port", 1234)
set("server.telnet", true)
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/610#issuecomment-415154699--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Process hangs while decoding (#611)

2018-08-22 Thread Romain Beauxis
Thanks for this report, much appreciated. I'll look at it ASAP.

Meanwhile, if that is production critical, you can look at the new build-in 
`FFMPEG` decode, which should not have these hang ups (haha)

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/611#issuecomment-415145409--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Process hangs while decoding (#611)

2018-08-22 Thread jdbuys
Yep 4.05.0, which I installed through opam.

On Wed, Aug 22, 2018, 17:25 Gilou  wrote:

> what version of ocaml are you using? 4.05.0 from the ubuntu repos?
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> ,
> or mute the thread
> 
> .
>


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/611#issuecomment-415137083--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Process hangs while decoding (#611)

2018-08-22 Thread Gilou
what version of ocaml are you using? 4.05.0 from the ubuntu repos?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/611#issuecomment-415072172--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Liquidsoap freezes on a complex script (#609)

2018-08-22 Thread Gilou
and interestingly (or not), liq honored USR1 in that state, because it 
truncated the log file upon receiving!

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/609#issuecomment-415021474--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Liquidsoap freezes on a complex script (#609)

2018-08-22 Thread Gilou
if I attach strace to stereotool, it seems to be alive and waiting for data... 
`[pid 30093] read(0, `


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/609#issuecomment-415020296--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Process hangs while decoding (#611)

2018-08-22 Thread Gilou
Ha! Now I'm not the only one... though your issue is with decoding, mine with 
outputs (#609).. but common ground: process handling in liq... 

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/611#issuecomment-414990009--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


Re: [Savonet-users] [savonet/liquidsoap] Liquidsoap freezes on a complex script (#609)

2018-08-22 Thread Gilou
I removed all outputs but the one streaming the piped stream, as I suspect it's 
the culprit, it froze again after 1h40, smart_crossfade managed to squeeze one 
more line:
`2018/08/22 12:06:31 [smart_crossfade:3] new >= old + margin, old <= medium and 
new <= high.`
This time I had a socket connected before, and it's responding... 
```
uptime
0d 01h 53m 51s
restart
restart called
```
but it's not doing anything
the external process is still running, hasn't crashed, doesn't complain on 
stderr
If I attach strace to liq, I get:
```
sudo strace -fp 29444
strace: Process 29444 attached with 7 threads
[pid 29454] futex(0x56309c3428a0, FUTEX_WAIT_PRIVATE, 2, NULL   
[pid 29449] futex(0x7f93d8000b48, FUTEX_WAIT_PRIVATE, 0, NULL   
[pid 29448] futex(0x7f93dc000b48, FUTEX_WAIT_PRIVATE, 0, NULL   
[pid 29447] restart_syscall(<... resuming interrupted poll ...> 
[pid 29446] select(0, NULL, NULL, NULL, {tv_sec=0, tv_usec=21809} 
[pid 29445] futex(0x56309c3428a0, FUTEX_WAIT_PRIVATE, 2, NULL 
[pid 29444] futex(0x56309c3428a0, FUTEX_WAIT_PRIVATE, 2, NULL 
[pid 29446] <... select resumed> )  = 0 (Timeout)
[pid 29446] select(0, NULL, NULL, NULL, {tv_sec=0, tv_usec=5}) = 0 (Timeout)
[pid 29446] select(0, NULL, NULL, NULL, {tv_sec=0, tv_usec=5}) = 0 (Timeout)
[pid 29446] select(0, NULL, NULL, NULL, {tv_sec=0, tv_usec=5}) = 0 (Timeout)
[pid 29446] select(0, NULL, NULL, NULL, {tv_sec=0, tv_usec=5}) = 0 (Timeout)
[pid 29446] select(0, NULL, NULL, NULL, {tv_sec=0, tv_usec=5}) = 0 (Timeout)
```
If I kill the external process, liq uses 100% of CPU.
I'll try and monitor the external process next time.
I added merge_tracks and drop_metadata to try making stereotool happier, but I 
don't think that's the issue ☹


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/609#issuecomment-414989013--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


[Savonet-users] [savonet/liquidsoap] Process hangs while decoding (#611)

2018-08-22 Thread jdbuys
Hi,

Liquidsoap correctly uses the ffmpeg decoder, but then hangs and doesn't 
actually stream or give an error, and you can't terminate the process because 
it seems like it can't close ffmpeg.
Attached are the files that cause the issue. I can't replicate it with any 
other files so far.
Any help would be appreciated.

I have compiled the latest version from source on Ubuntu 18.04.
Liquidsoap 1.3.3+scm 
(git://github.com/savonet/liquidsoap.git@a1602f7193774d874d188cd94a2080d56afbbc80:20180822:100724)

And here is my script:

`#!/usr/local/bin/liquidsoap
set("log.file.path","error.log")
set("log.stdout", true)
set("server.telnet",false)
set("server.socket",true)
set("server.socket.path","lsoap.sock")
set("server.socket.permissions",511)
set("server.timeout",20.)
set("scheduler.generic_queues",2)
set("scheduler.non_blocking_queues",2)
set("scheduler.fast_queues",0)
set("scheduler.log",true)
set("init.catch_exn",true)
set("log.level",8)


#Add ffmpeg
def test_ffmpeg(file) = -1 end
ffmpeg_p = "/tmp/ffmpeg/ffmpeg -i - -f mp3 -"
add_decoder(name="FFMPEG",description="Decode files using the ffmpeg decoder 
binary",mimes=["audio/aacp","application/octet-stream","audio/x-wav"],test=test_ffmpeg,ffmpeg_p)


source=fallback(track_sensitive=false,[playlist("/tmp/playlist.pls"),request.queue(id="queue",length=10.0),request.equeue(id="equeue")])
source=audio_to_stereo(id="source",source)
source=mksafe(source)


output.icecast(%mp3(stereo=true,bitrate=64,samplerate=44100),id="icecast",host="127.0.0.1",port=80,user="source",password="hackme",fallible=true,name="GreenMonkey",description="Green
 Monkeys 
Unite!!",mount="idGreenMonkeyUnited",url="http://green-monkey.com",source)
`

[music.zip](https://github.com/savonet/liquidsoap/files/2309821/music.zip)


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/611--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


[Savonet-users] [savonet/liquidsoap] Telnet is not working properly (#610)

2018-08-22 Thread EntityinArray
Liquidsoap 1.3.3+scm running on Windows 8.1 x64

I was trying to make station interactable through Telnet server, but after i 
execute a command it says that no such command exists (even if i type "help" 
command that 100% exists) and then my connection to Telnet server times out.

Here's my station code:

set("server.telnet",true)

vol = interactive.float("volume",1.0)

source = amplify(vol,mksafe(playlist("playlist.m3u")))

output.icecast(%mp3,
host = "coolgoga.hldns.ru", port = 8000,
password = "xxx", mount = "entity",
name="cool music", genre="cool", description="hmm",
source
)`

And here what happens when i try to interact through PuTTY telnet client:

https://i.imgur.com/PupBzyH.png
https://i.imgur.com/phgnbvl.png


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/610--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users


[Savonet-users] [savonet/liquidsoap] Liquidsoap freezes on a complex script (#609)

2018-08-22 Thread Gilou
Hi,
So running most components from master (cry, dtools, duppy, faad, mad, mm). 
Thing is, that script is quite complex, but if I remove each part, the bug is 
really hard to reproduce... All parts have been tested stand alone though.

The script combines:

- playlist()s with a custom check_next function to avoid repetitions
- annotate protocol to set liq_replaygain outside of liq (to avoid cpu 
hogging...)
- amplify
- classical fallback/switch
- smart_crossfade
- on_track to store played tracks 
- input.external using cat on a fifo
- output.external using stereotool, itself outputting to the fifo
- insert_metadata to patch metadata through to icecast
- output.icecast using %mp3(bitrate=256)
- a ladspa "simple" DSP

at the moment I had it freeze, it was outputting 3 streams to icecast:
- the "bypass", basically the smart_crossfade output
- the same processed by the ladspa processor
- the same processed and piped through stereotool

This is really frustrating, and I'm now back to investigating this again, 
trying to strip all parts... I'm dumping here as a "reference" until I can 
narrow it down.
The "freeze" means stdout is stuck, the server doesn't answer the socket. The 
process is alive, but seems stuck polling for something, doesn't respond to 
QUIT/^C.

Script is run using liquidsoap -v full.liq, and is here with supporting 
functions.liq: https://gist.github.com/gilou/43133d2619202791e153211471aff6a1
[liq.log](https://github.com/savonet/liquidsoap/files/2309319/liq.log) contains 
the end of the log, timestamp is hours before I killed it.

[bt.txt](https://github.com/savonet/liquidsoap/files/2309321/bt.txt) is the 
backtrace from the core I got using kill -ABORT on it

It's running on a cheap VPS, using Ubuntu 18.04 on KVM. On this version it 
crashes in less than an hour.





-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/savonet/liquidsoap/issues/609--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Savonet-users mailing list
Savonet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-users