Skip to main content

A audio player extension for schemdule.

Project description

schemdule-extensions-audioplay

Schemdule

Downloads

A audio player extension for Schemdule.

Install

Install dependencies:

# Install dependencies on Linux (only)
sudo apt-get install -y python3-dev libasound2-dev

# Install ffmpeg
choco install ffmpeg        # Windows
apt-get install -y ffmpeg   # Linux
brew install ffmpeg         # MacOS

Use pip:

pip install schemdule-extensions-audioplay

Or use pipx:

pipx inject schemdule schemdule-extensions-audioplay

# Upgrade
pipx upgrade schemdule --include-injected

Check if the extension installed:

schemdule ext

Usage

This extension provide a AudioPlayerPrompter and add the following extension methods on PrompterBuilder and PayloadBuilder.

class PrompterBuilder:
    def useAudioPlayer(self: PrompterBuilder, endSpace: Optional[timedelta] = None, final: bool = False) -> PrompterBuilder:
        """
        endSpace: Stop audio before next event, default 10 seconds. The empty space leads to the next event outdated.
        """
        ...

class PayloadBuilder:
    def useAudio(self, files: Iterable[str]) -> "PayloadBuilder":
        ...

Use the extension in the schema script.

# schema.py
ext("audioplay")

at(..., payloads().useAudio(["file1"]))

prompter.useAudioPlayer()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

schemdule-extensions-audioplay-0.1.0.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

File details

Details for the file schemdule-extensions-audioplay-0.1.0.tar.gz.

File metadata

  • Download URL: schemdule-extensions-audioplay-0.1.0.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.6.14

File hashes

Hashes for schemdule-extensions-audioplay-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2f0483dae409edfe10e0755752c97dce4d873c1e313a142a6c9aefd307debffc
MD5 4c6c88f2e79c955d10f513f538d50a4b
BLAKE2b-256 f5a6dda0bfa09f953b3bbd2b7de3926e4c2d54d075eb42dc5cc39b24a8702c35

See more details on using hashes here.

File details

Details for the file schemdule_extensions_audioplay-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: schemdule_extensions_audioplay-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.6.14

File hashes

Hashes for schemdule_extensions_audioplay-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a356da5dc0768f4bfe4e5fef69caf8058f5a1b2b302168c24bc27ad21fd0c74b
MD5 6f0a73b0f705d57ccaf99f40e927f4f7
BLAKE2b-256 97a0fcbcf84c9cd4dcb883ca7b80eb2144079eae28a9179f81de363297ac71e7

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page