Skip to main content

playbacque

Loop play audio

Usage

> pip install playbacque
> playbacque "audio.wav"

Requires FFmpeg on PATH

Use Ctrl+C to stop playback

Supports most file formats (as this uses FFmpeg)

Supports taking audio from stdin

> ffmpeg -i "audio.mp3" -f wav pipe: | playbacque -

Advanced

When input is from stdin, an internal buffer is automatically used to loop the audio

If input is from a URL (not seekable), pass --buffer to force buffering the audio

For PCM encoded input, ensure it is 48000 Hz signed 16 bit stereo audio, and pass --pcm

To write PCM encoded audio to stdout, pass --out

To specify a specific audio device to output to, pass --device <id> (list devices using --list-devices)

On Windows, there is a Microsoft Sound Mapper - Output, MME (0 in, 2 out) device that redirects to the default output device and also works after disconnecting

Development

This project uses Hatch for project management and hatch-vcs for getting the version from Git tags when building

However, other tools can be used, such as virtualenv for isolating dependencies, pip to install the project, build to build the project, and twine to publish the project

I recommend using pipx to install Hatch and hatch-vcs

Install pipx globally

> pip install --user pipx
> pipx ensurepath

Install Hatch 1.0 (currently in prerelease) and inject the hatch-vcs plugin

> pipx install "hatch>=1.0.0.dev"
> pipx inject hatch hatch-vcs

Run the project using Hatch

> hatch run playbacque -V

Run linters and tests

> hatch run lint:all
> hatch run test:all

If you have Python 3.7 - 3.10 all installed for some reason, run tests on all of them

> hatch run test-matrix:all

Metadata

Release files for playbacque 0.2.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for playbacque 0.2.3
File Size Uploaded Provenance
playbacque-0.2.3.tar.gz 6.9 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for playbacque 0.2.3
File Interpreter ABI Platform
playbacque-0.2.3-py3-none-any.whl Python 3 none any Details

Total release size: 14.3 kB

Release files / playbacque-0.2.3.tar.gz

Download URL playbacque-0.2.3.tar.gz
Size 6.9 kB
Tags Source
SHA-256 checksum
How to use checksums
82506b9c3305eaab60bca5a39c90b533d7856886915b4a624a4f26d8779b632b
BLAKE2b-256 checksum
How to use checksums
5ebf28fe8275e60506653b402d226ced6623d7f89ed1b35f11e107ef974ef5f2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-httpx/0.22.0

Release files / playbacque-0.2.3-py3-none-any.whl

Download URL playbacque-0.2.3-py3-none-any.whl
Size 7.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5d742d0ccaf47588a2e8bbd28a320af050413dbac5d794eacdc1238a69bca7ae
BLAKE2b-256 checksum
How to use checksums
3e4af444cbe41d71db00a9984777a122250dc625a47eb64bbc06f55648f111ce
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-httpx/0.22.0

Security for playbacque 0.2.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page