Changelog for discord-haskell-voice-3.0.0
Changelog for discord-haskell-voice
Unreleased changes
3.0.0 — 2025 March
-
Breaking API changes
- Replaced previously separate playing functions with a single
playfunction - New
AudioResourcetype represents a resource to be played, made with e.g.createYoutubeResource - New audio transformation abilities via FFmpeg flags and Haskell conduits
- Use FFmpeg's direct Ogg/Opus output to skip the FFmpeg->PCM->Opus translation if there are no Haskell conduits that operate on PCM
- Can now specify a codec in
playto skip on using FFmpeg at all if input is already PCM or Opus - Can now use
ffprobeto automatically detect if the input resource is already PCM or Opus and intelligently skip FFmpeg - New dependency on
typed-processfor safer external process - New dependency on
opusfrom Hackage instead of direct git source - Remove ExceptT from the Voice monad stack
- Remove
SubprocessExceptiontype from the library as it became unused - Remove
InvalidPayloadOrderfrom theVoiceErrorADT since it became unused
- Replaced previously separate playing functions with a single
-
Bug Fixes
- Fix
OpusBufferTooSmallwhen receiving Opus data due to buffer being half the size it should be - Fix the library crashing when joining a call with another user already in it, which triggers Opcodes 11/18/20 before Opcode 4
- Fix
leavecausing MVar thread deadlock due to the BoundedChan consumer thread being killed - Fix possibility of audio artifacts when sending multiple audio resources back-to-back due to incorrect silence frames #45
- Fix posibility of the last few bytes of Opus frames being cut off during transmission due to a buffer too small #45
- Fix
-
Miscellaneous
- Support GHC 8.10.7, 9.0.2, 9.2.4, and 9.6.6
- Improve BasicMusicBot example to be less lisp-y in terms of brackets, and fix all warnings
- Improve error messages when parsing Ogg containers fail
- Use
DerivingStrategiesin the library code to make explicit where deriving typeclasses are from - Add a compile flag (
-use-crypton) to use acrypton-based encryption backend, which removes the necessity for libsodium - Remove
containersdependency - Relax package bounds:
aesonfrom ==1.5.6.0 to <2.3bytestringfrom <0.11 to <0.13conduitfrom <=1.3.4.2 to <1.4.0.0mtlfrom ==2.2.2 to <2.4saltinefrom <0.2 to <0.4stmfrom <2.5.1 to <2.6textfrom <2 to <3timefrom <=1.13 to <1.15websocketsfrom <0.12.8 to <0.14wussfrom <=1.2 to <2.1discord-haskellfrom <= 1.14.0 to <= 1.17.1
- Add build CI for Cabal & Stack for all supported GHC versions except 9.6.6
- Renamed
masterbranch tomain - Updated copyright to current year and include contributors where applicable
- Added link to GitHub Sponsors
- Updated Haddock for all functions and added examples and usage to many functions
- Added upper bound of
<0.5to microlens and microlens-th
2.3.1 — 2022 July
- Update
discord-haskelldependency bounds to>= 1.12.0 && <= 1.14.0. - Use
UnliftIO.MVarfunctions internally for MVar operations inDiscordHandler IOExceptions thrown by e.g. createProcess duringrunVoiceare no longer caught and subdued - they are propagated to the user.
2.3.0 — 2022 May
- Export
playYouTubeWithandplayYouTubeWith'fromDiscord.Voice. - Update
discord-haskelldependency bounds to>= 1.12.0 && <= 1.13.0. - Migrate from
lenstomicrolens, following theopuspackage doing the same.
2.2.2 — 2022 February
- Update
discord-haskelldependency to 1.12.0 - Bump copyright to 2022
- Fix incomplete pattern match crash in the example bot when using
bot --bash-completion-script
2.2.1 — 2022 January
- Patch README having incorrect non-published details after Hackage publication.
2.2.0 — 2022 January
- Change the definition of
Voicefrom a type alias exposing dangerous internal handles, to a newtype wrapper. This also changes the definition ofliftDiscordto maintain identical behaviour. - Update
discord-haskelldependency to 1.11.0
2.1.0 — 2022 January
- Removed
updateSpeakingStatusfrom the publicly exported function list forDiscord.Voice.
2.0.0 — 2021 December
- Rewrite the entire library (see #1).
- Introduce the
Voicemonad, and all functions in it:join,play, and all other variants ofplay. - Add
lensas a dependency for internal library use. - Add
conduitas the main method of piping and transforming audio on the fly. - Remove all previous functions:
joinVoice,leaveVoice,playPCM, etc. - Add package documentation to public modules, and make sure the abstraction layer is solid (don't export useless internals).
- Rename the JoinSpecificVC example to BasicMusicBot and add a
bot volumecommand to change the volume.
0.0.1 — 2021 June
- Initial release.
- Implement
joinVoice,leaveVoice, etc and useDiscordVoiceHandleto maintain a reference to the voice handle. - Add JoinAllVC and JoinSpecificVC as example usages of the library.