Releases: savonet/liquidsoap
Liquidsoap 2.3.2
Not an april's fool joke! 😄
This is the second bugfix release of the 2.3.x
release branch of liquidsoap!
We highly suggest to update your script to this version if you are on the 2.3.x
release!
Other than that, this release includes a collection of nice bugfixes and other optimization.
🚨 While we have your attention: the 5th Liquidshop is taking place on Friday, June 13th! Please consider attending and/or presenting your project, community or topic of interest! More info: https://www.liquidsoap.info/liquidshop/5/
2.3.2 (2025-04-01) 🃏
New:
- Added support for multiple metadata fields in
ogg and flac metadata - Added support for track-level REM ALBUM in cue file parsing
(#4381)
Changed:
- Added
"pic"
to list of excluded metadata for automatic charset conversion. - Added
settings.charset.max_string_length
setting to prevent automatic charset
conversions of strings over that length.
Fixed:
- Optimized CPU usage (#4369, #4370)
- Fixed empty initial HLS segment (#4401)
- Fixed support for
duration
metadata in image decoder (#4397) - Fixed cue-out bug in cue file parsing (#4381)
- Bring back parse error location. (#4362)
- Fixed SRT encoding when restarting a stream with reverse data flow
(#4399) - Make sure that audioscrobbler
on_track
/on_end
operations are
sent to a asynchronous task queue. - Fixed resources accumulation leading to catchup when using
crossfade
(#4419, #4410) - Fixed source reselection logic issue that was causing crashes when using
switch
andfallback
operators (#4420) - Fixed self-sync logic with pulse audio outputs (#4429)
- Fixed script caching on windows.
Liquidsoap Rolling Release 2.3.x
This release provides liquidsoap assets before they are published as a new versioned release.
You can use it to install the latest stable code before it is published and test/prepare your production environment for it.
Rolling releases can also be useful for us to quickly detect and report bugs before the final published release!
Assets in this release will be deleted. If you are looking for permanent links to release assets, please head over to https://github.com/savonet/liquidsoap-release-assets/releases
For more details about our release process, please checkout https://github.com/savonet/liquidsoap#release-details
\n\n
2.3.2 (unreleased)
New:
- Added support for multiple metadata fields in
ogg and flac metadata - Added support for track-level REM ALBUM in cue file parsing
(#4381)
Changed:
- Added
"pic"
to list of excluded metadata for automatic charset conversion. - Added
settings.charset.max_string_length
setting to prevent automatic charset
conversions of strings over that length.
Fixed:
- Optimized CPU usage (#4369, #4370)
- Fixed empty initial HLS segment (#4401)
- Fixed support for
duration
metadata in image decoder (#4397) - Fixed cue-out bug in cue file parsing (#4381)
- Bring back parse error location. (#4362)
- Fixed SRT encoding when restarting a stream with reverse data flow
(#4399) - Make sure that audioscrobbler
on_track
/on_end
operations are
sent to a asynchronous task queue. - Fixed resources accumulation leading to catchup when using
crossfade
(#4419, #4410) - Fixed source reselection logic issue that was causing crashes when using
switch
andfallback
operators (#4420) - Fixed self-sync logic with pulse audio outputs (#4429)
- Fixed script caching on windows.
Liquidsoap 2.3.1
This is the first bugfix release of the liquidsoap 2.3.x
release cycle!
So far, the 2.3.0
release has shown to be a pretty solid one! Therefore, this release only has minor bugfixes, most importantly about alsa devices and flac encoder.
Along with it are a couple of exciting features to keep things moving:
- The
lastfm
scrobbler implementation has been fixed and came with support forxml
parsing and rendering. - The CUE file parser for playlists has been rewritten natively and now supports many more dialects of the CUE file.
So, if you have a bunch of 90s CDs ripped with EAC that you want to scrobble to lastfm, this is your release! 😅
Also, we recommend that everyone else update to this version as well. It contains more bug fixes that may be affecting you and should be just as stable as 2.3.0
!
Assets in this release may be deleted or updated. If you are looking for permanent links to release assets, please head over to https://github.com/savonet/liquidsoap-release-assets/releases
Full changelog:
2.3.1 (2025-02-05)
New:
- Added support for address resolution preference in SRT (#4317)
- Added global address resolution settings for SRT and Icecast (#4317)
- Added support for parsing and rendering XML natively (#4252)
- Added support for
WAVE_FORMAT_EXTENSIBLE
to the internal wav decoder. - Added optional
buffer_size
parameter toinput.alsa
andoutput.alsa
(#4243) - Reimplemented audioscrobbler support natively using the more recent protocol (#4250)
- Added boolean getter to disable/enable normalization (#4308)
Changed:
- Make alsa I/O work with buffer size different than liquidsoap internal frame (#4236)
- Reimplemented CUE file parser in native liquidsoap script, added support for multiple files and EAC non-compliant extension (#1373, #4330)
- Make
"song"
metadata mapping to"title"
metadata ininput.harbor
disabled when either"artist"
or"title"
is also passed. Add a configuration key to disable this mechanism. (#4235, #2676) output.icecast
now re-sends the last metadata when connecting to the remote server unless explicitly disabled using thesend_last_metadata_on_connect
option (#3906)- Add full explicit support for
ipv4
vs.ipv6
resolution in SRT inputs and outputs, add globalsettings.srt.prefer_address
andsettings.icecast.prefer_address
(#4317) - Added generic SRT socket get/set API. Added new socket options, including
latency
andipv6only
.
Fixed:
- Fixed request resolution loop when enabling both
autocue
andreplaygain
metadata resolvers (#4245, fixed in #4246) - Fixed
flac
encoding segfault (#4286, #4274) - Fixed source
last_metadata
not being properly updated (#4262) - Convert all ICY (icecast) metadata from
input.http
toutf8
. - Fixed
inotify
unwatching due to GC cleanup (#4275) - Fixed
delay
initial conditions (#4281)
Liquidsoap 2.3.0
We are stoked to announce the release of liquidsoap 2.3.0
! 🎉 ✨
This release brings a lot of exciting changes. As usual, we recommend to first test it in a staging environment before deploying it to production. Migration notes for this release can be found here.
A lot of hard engineering work went into this release! The largest changes should that happened during this cycle were under the hood:
Complete re-implementation of the streaming cycle and clocks
This change allowed us to prepare the codebase to use OCaml's new multicore support in future releases and get rid of design decisions that were 20 years old now. Back then, we had no idea how things would evolve! In particular, we had to account for new form of content such as raw video and encoded content.
Instead of filling a partial frame during the streaming cycle, we are now manipulating chunks of immutable content, concatenating them to build a frame on each streaming cycle. This is much more inline with the logic underlying video and encoded content where pieces of content can happen at random time, according to their presentation timestamp (PTS) or decoder timestamp (DTS).
Abstracting content this way has allowed us to finally get rid of frame breaks doubling as both track marks and partial filling marks. With the new content model, track marks and metadata are first-class content and part of the frame generation.
If you have ever encountered any of the infamous #get_frame didn't add exactly one break!
fatal error, you know what we mean. This early design decision had plagued us for a while and it's wonderful to see it gone!
Along with these changes, we also reimplemented from scratch our notion of clocks, the abstract API that runs the main streaming cycles.
While clocks are still a pretty complex topic (self-sync, active vs. passive etc), we hope that this rewrite will clarify things. It was a good opportunity to clean up our implementation and use the experience gained about it in the recent years.
With these changes, clocks are now surfaced to the user via a clock
method on each source. This makes it possible to directly access source clocks, animate them in your script, etc. We've also started to support synchronous streaming scripts, which should make it possible to use liquidsoap as a CLI for offline processing.
Script caching and memory optimization
Another important new feature with this release is the ability to cache the standard library and user scripts. This allows liquidsoap to run much faster. More details are available in this blog post
Incidentally, script caching also has very important benefits for memory usage. This is documented here.
This feature is probably the most important one of this release for most users!
Internal autocue
Autocue, the method for computing the perfect crossfade has also been polished in this release. We have now switched to our internal implementation, which is available when enabling our ffmpeg
support.
You should be able to enable it by adding this to your script:
enable_autocue_metadata()
With this, all requests should resolve with the appropriate metadata so that any crossfade
produces perfect transitions!
Remember that this feature requires CPU-heavy computations on each track!
A lot of testing went into this feature so we are really thankful to our users for the support and patience!
Other new features
Here's a list of other notable changes in this release:
- Frame duration was dropped to
0.02s
. This should enhance streams latency and was made possible thanks to the new streaming implementation. See #4033 for a discussion about the trade-offs involved with this setting. - New support for video size-independent placement of video elements. This makes it possible to design video streams with different elements whose placement is independent of the final video resolution. See this blog post for an example of it.
- Support for NDI output. We always try to extend the scope of applications that can be interfaced with liquidsoap. In the future, we would like to add support for NDI inputs and extend the supported formats.
The rest of the changelog is included below.
As with each release, we want to thank all our users for their patience, early testing and collaboration to make this release possible. It's a testament to their help that we are able to ship this release with such a level of confidence despite all the major changes that happened in the code base.
Special thanks go to: @vitoyucepi, @gAlleb, @RM-FM, @Moonbase59, @Russsgithub, @gilou, Xogium, the whole AzuraCast and Radio France team and everyone who helped reporting, fixing and confirming bugs.
Thanks y'all!
2.3.0 (2024-11-27)
New:
- Rewrote the streaming API to work with immutable frame content. This
should greatly impact impredictable side-effect of the previous models w.r.t.
track marks, content sharing and more. This also impacts multiple operators
behavior. Mostly, things should be roughly the same with differences around
behaviors related to track marks (source.on_track
and etc). (#3577) - Added script caching layer for faster script startup time. See: https://www.liquidsoap.info/blog/2024-06-13-a-faster-liquidsoap/ for details (#3924, #3949, #3959 and #3977)
- Rewrote the clock/streaming loop layer. This prepares our streaming system to
support multicore when the OCaml compiler is mature enough to allow it. Clocks
are now attached to sources via theirclock
methods. Returned value is a stripped
downclock
variable. Users can use theclock
function to retrieve the full
methods, e.g.s = sine(); c = clock(s.clock)
. This value has advanced functions
for clock control such asstart
/stop
,ticks
andself_sync
to check for
self-sync
. (#3781) - Allow frames duration shorter than one video frames, typically values under
0.04s
.
Smaller frames means less latency and memory consumption at the expense of
a higher CPU usage (#3607) - Change default frame duration to
0.02s
(#4033) - Optimized runtime (#3927, #3928, #3919)
- Added NDI output support (#4181)
- Added
finally
to execute code regardless of whether or not an exception is raised
(see: #3895 for more details). - Added support for Spinitron submission API (#4158)
- Removed gstreamer support. Gstreamer's architecture was never a good fit for us
and created a huge maintenance and debugging burden and it had been marked as
deprecated for a while. Most, if not all of its features should be available using
ffmpeg
. (#4036) - Removed
taglib
support. It is superseded by the internalocaml-metadata
module
and taglib, with its dependency on the C++ runtime library, has been causing issues
with binary builds portability and crashes with the (not yet supported) OCaml 5
compiler. (#4087) - Added
video.canvas
to make it possible to position video elements independently
of the rendered video size (#3656, blog post) - Added cover manager from an original code by @vitoyucepi (#3651)
- Added non-interleaved API to
%ffmpeg
encoder, enabled by default when only
one stream is encoded. - Allow trailing commas in record definition (#3300).
- Added
metadata.getter.source.float
(#3356). - BREAKING: Added
duration
andticks
to metadata available when computing HLS segment names (#4135) - Added optional
main_playlist_writer
tooutput.file.hls
and
derivated operator (#3484) - Added
is_nan
,is_infinite
,ceil
,floor
,sign
andround
(#3407) - Added
%track.drop
to the%ffmpeg
encoder to allow partial encoding
of a source's available tracks (#3480) - Added
let { foo? } = ...
pattern matching (#3481) - Added
metadata.replaygain
method to extract unified replay gain value from metadata (#3438). - Added
metadata.parse.amplify
to manually parse amplify override metadata. - Added
compute
parameter tofile.replaygain
to control gain calculation (#3438). - Added
compute
parameter toenable_replaygain_metadata
to control replay gain calculation (#3438). - Added
copy:
protocol (#3506) - Added
file.touch
. - Added support for sqlite databases (#3575).
- Added
string.of_int
andstring.spaces
. - Added
list.assoc.nullable
. - Added
source.cue
(#3620). - Added
string.chars
(#4111) - Added atomic file write operations.
- Added new
macos_say
speech synthesis protocol. Make it the default implementation for thesay:
protocol onmacos
. - Added
settings.request.timeout
to set the request timeout globally.
Changed:
- Reimplemented
request.once
,single
and more usingsource.dynamic
. Removed experiment
flag onsource.dynamic
. The operator is considered stable enough to define advanced sources
but the user should be careful when using it. - Mute SDL startup messages (#2913).
int
can optionally raises an error when passingnan
orinfinity
,int(infinity)
now returnsmax_int
andint(-infinity)
returnsmin_int
. (#3407)- Made default font a setting (#3507)
- Changed internal metadata format to be immutable (#3297).
- Removed
source.dump
andsource.drop
in favor of saferrequest.dump
andrequest.drop
.
source.{dump, drop}
can still be implemented manually when needed and with the proper
knowledge of what's going on. - Allow a getter for the ...
Liquidsoap Rolling Release 2.2.x
This release provides liquidsoap assets before they are published as a new versioned release.
You can use it to install the latest stable code before it is published and test/prepare your production environment for it.
Rolling releases can also be useful for us to quickly detect and report bugs before the final published release!
Assets in this release will be deleted. If you are looking for permanent links to release assets, please head over to https://github.com/savonet/liquidsoap-release-assets/releases
For more details about our release process, please checkout https://github.com/savonet/liquidsoap#release-details
2.2.5 (unreleased)
New:
- Added various ffmpeg timestamps when exporting ffmpeg metadata from filters.
- Added
enable_autocue_metadata
andautocue:
protocol to automatically compute cue points and crossfade parameters (#3753, @RM-FM and @Moonbase59) - Added
db_levels
method toblank.*
sources (#3790) - Added
excluded_metadata_resolvers
torequest.create
to make it possible to selectively disable specific metadata resolvers when resolving requests.
Changed:
- Allow to disable
http.*
url normalization. Add warning when url normalization changes the url (#3789)
Fixed:
- Fixed
source.drop
andsource.dump
clock initialization. - Fixed bogus report of non-monotonous PTS content when using raw ffmpeg content.
- Fixed streaming errors when disconnecting
input.harbor
. - Fixed issues with rendered id3v2 frame that contain binary data (#3817)
Liquidsoap 2.2.5
This is the fifth release of the 2.2.x
release cycle, following the initial 2.2.0
release.
This release comes with some minor bugfixes and changed feature and one big chunk of new functionality around crossfading: autocue
.
We will post a longer article about this on our blog. The gist of the functionality is that it should allow to compute excellent crossfade transition parameters in your sources, at the expense of an increased CPU usage.
Users can register their own autocue
implementations and there is a default one that is available if you have compiled liquidsoap
with its ffmpeg
support.
In this case, you can try to add:
enable_autocue_metadata()
To your script and see what happens!
2.2.5 (2024-05-01) (Mayday!)
New:
- Added
enable_autocue_metadata
andautocue:
protocol to automatically compute cue points and crossfade parameters (#3753, #3811, @RM-FM and @Moonbase59) - Added various ffmpeg timestamps when exporting ffmpeg metadata from filters.
- Added
db_levels
method toblank.*
sources (#3790) - Added
excluded_metadata_resolvers
torequest.create
to make it possible to selectively disable specific metadata resolvers when resolving requests. - Normalized expected API from
autocue
, allow multiple implementation and adaptcross
/crossfade
to work with it out of the box with workaround for short tracks. - Added private and swapped memory reporting when compiled with
mem_usage
. - Added priorities to metadata deocoders, allows finer-control of metadata overriding. (#3887)
Changed:
- Allow to disable
http.*
url normalization. Add warning when url normalization changes the url (#3789) - Add
namespace
and optional source IDs tomix
.
Fixed:
- Prevent request metadata from overriding root metadata (#3813)
- Fixed
source.drop
andsource.dump
clock initialization. - Fixed bogus report of non-monotonous PTS content when using raw ffmpeg content.
- Fixed streaming errors when disconnecting
input.harbor
. - Fixed issues with rendered id3v2 frame that contain binary data (#3817)
- Fixed memory leaks with SRT listen socket polling callbacks.
- Fixed
%ffmpeg
copy muxer logic with some audio/video streams (#3840) - Fixed
duration
metadata calculation in the presence ofcue_in
/cue_out
metadata.
Liquidsoap 2.2.4
This is the fourth follow-up release from the 2.2.x
branch. This release comes with important bug fixes related to memory consumption and audio quality.
You can refer to the liquidsoap blog for more details about this release: https://www.liquidsoap.info/blog/2024-02-07-liquidsoap-v2.2.4/
As usual, we recommend any user on the 2.2.x
branch to upgrade to this version. However, this time, it is recommended to read about the non-trivial changes it brings and to test it with your staging or pre-prod environment!
Full release changelog:
2.2.4 (2024-02-04)
New:
- Added support for
id3v2
metadata inoutput.*.hls
when using%mp3
,%shine
or%fdkaac
encoders (#3604) - Added option to set preferred address class (
ipv4
,ipv6
or system default) when resolving hostnames in http transports andoutput.icecast
- Added
self_sync
option toinput.srt
to accommodate for streams in file mode (#3684) - Added
curve
parameter to fade functions andliq_fade_{in,skip,out}_curve
metadata override (#3691) - Added
delay
parameter to fade functions to make it possible to add delay before fade happens. Addliq_fade_{in,skip,out}_delay
metadata override. - Added
single_track
option to allowsequence
to play each source until they are unavailable while keeping track marks.
Changed:
cue_cut
operator has been removed. Cueing mechanisms have been moved to underlying file-based sources. See migration notes for more details.
Fixed:
- Fix pop/click at the end of fade out/in (#3318)
- Fix audio/video synchronization issues when decoding live streams using ffmpeg.
- Fix issues with TLS connecting clients not being properly timed out (#3598)
- Make sure reconnection errors are router through the regulat
on_error
callback inoutput.icecast
(#3635) - Fixed discontinuity count after a restart in HLS outputs.
- Fixed file header logic when reopening in
output.file
(#3675) - Fixed memory leaks when using dynamically created sources (
input.harbor
,input.ffmepg
, SRT sources andrequest.dynamic
) - Fixed invalid array fill in
add
(#3678) - Fixed deadlock when connecting to a non-SSL icecast using the TLS transport (#3681)
- Fixed crash when closing external process (#3685)
Liquidsoap 2.2.3
This is the third and, hopefully, near final point release of the liquidsoap 2.2.x
release cycle.
The most important changes in this release are:
- A fix involving shared active sources leading to infinite loop and CPU usage going to 100%. This impacted in particular scripts doing recording of a streamer being sent via another output. See: #3537 for such an example.
- Several SRT-related fixes w.r.t file descriptor leaks and the caller connection not being properly processed asynchronously.
This release should be safe to upgrade to for any script on the 2.2.x
branch. But, as usual, don't forget to test it with a staging environment first!
2.2.3 (2023-12-14)
New:
- Added
register_telnet
option to all outputs to
prevent telnet commands registration (#3545) - Added
file.touch
Changed:
- BREAKING:
setting.playlists
has been renamed
setting.playlist
,settings.playlist.mime_types
now refers to a full list of records (#3561)
Fixed:
- Cleanup telnet commands on output shutdown,
prevent commands registration for internal
outputs (#3545, fixes: #3541) - Allow overwrite in youtube-dl/yt-dlp call,
remove use of unix-specific process call.
(#3563) - Fixed playlist parsers not being registered
when evaluatin top-level script (#3553) - Fixed infinite loop on some active sources
(#3560, fixes: #3544, and #3537) - Fixed fd leak on failed connection in srt
caller mode (#3583) - Fixed high CPU usage on failed connection
in srt caller mode (#3583, #3573) - Prevent outputs from keeping the last 10 cover
metadata (#3504)
Liquidsoap 2.2.2
This release is the second bugfix release of the 2.2.x
release cycle. The most important fix is related to pop/clicks heard during crossfade (#3318) and the ffmpeg decoder failing with files and streams with unknown codecs.
This is the first release since we improved developers tools so feel free to also take this opportunity to update your developer setup!
As usual, we recommend trying this version with a staging/preview system before putting it on production. Beside that, this release should improve the stability of all scripts running on the 2.2.x
release branch.
We want to thank all contributors, bug reporters and patient users who have helped us bring all these improvements!
2.2.2 (2023-11-02)
New:
- Added
string.escape.html
(#3418, @ghostnumber7) - Add support for getters in arguments of
blank.detect
(#3452). - Allow float in source content type annotation so that it possible to write:
source(audio=pcm(5.1))
Changed:
- Trim urls in
input.ffmpeg
by default. Disable usingtrim_url=false
(#3424) - Automatically add HLS-specific ffmpeg parameters to
%ffmpeg
encoder (#3483) - BREAKING: default
on_fail
removed onplaylist
(#3479)
Fixed:
- Allow
channel_layout
argument in ffmpeg encoder to set the number of channels. - Improved support for unitary minus, fix runtime call of optional methods (#3498)
- Fixed
map.metadata
mutating existing metadata. - Fixed reloading loop in playlists with invalid files (#3479)
- Fixed main HLS playlist codecs when using
mpegts
(#3483) - Fixed pop/clicks in crossfade and source with caching (#3318)
- Fixed pop/clicks when resampling using
libsamplerate
(#3429) - Fixed gstreamer compilation. Remember that gstreamer features are DEPRECATED! (#3459)
- Fixed html character escaping in
interactive.harbor
(#3418, @ghostnumber7) - Fixed icecast not reconnecting after erroring out while closing connection in some circumstances (#3427)
- Fixed parse-only mode (#3423)
- Fixed ffmpeg decoding failing on files with unknown codecs.
- Fixed a crash due to
wait_until
timestamp being in the past when usingposix-time2
- Make sure that temporary files are always cleaned up in HLS outputs (#3493)
Liquidsoap 2.2.1
This is the first bugfix release from the liquidsoap 2.2.x
release cycle! It contains important fixed in the HLS outputs and muxer operator. This release should be safe to upgrade from 2.2.0
with some minor breaking changes on the HLS output on_file_change
callback to account for the atomic file operations.
2.2.1 (2023-09-05)
Changed:
- BREAKING: on HLS outputs,
on_file_change
events are
now"created"
,"updated"
and"deleted"
, to better
reflect the new atomic file operations (#3284) - Added
compact
argument to thehttp.response.json
function.http.response.json
will produce minified JSON by
default. Added a newline symbol to the end of the JSON data produced byhttp.response.json
. (#3299) - Bumped internal ogg decoder to make sure that it is used over the ffmpeg decoder whenever possible.
FFmpeg has issues with metadata in chained streams which needs to be fixed upstream. Unfortunately,
input.http
can only use the ffmpeg decoder at the moment. - Cleanup
output.file
encoding and file handling logic (#3328) - Added
ratio
tosource.{dump,drop}
to make it possible to control its CPU peaks. - Enhanced clock error reporting (#3317)
Fixed:
- Fixed slow memory leak in muxer operator (#3372, #3181, #3334)
- Fixed discontinuity logic error in HLS outputs after a restart.
- Fixed HTTP response status in
output.harbor
(#3255) - Make sure main HLS playlist is regenerated after being
unlinked (#3275) - Fixed hard crash on icecast disconnection errors.
- Fix
output.harbor
encoder header when encoding with
%ogg
,%vorbis
and etc. (#3276) - Fixed quality argument parsing in ffmpeg encoders (#3267)
- Make all HLS file write atomic (#3284)
- Allow seek and cue operators to work with muxed sources
using a single underlying source (#3252) - Fixed export of cover art metadata (#3279)
- Remove use of
stereo:
protocol insay:
protocol:
this is now handled automatically by the decoder and generates latency via
high CPU usage peak. - Fixed
output.file
reopening with flac encoding (#3328)