aiovlc package

Control VLC over telnet connection using asyncio.

Subpackages

Submodules

aiovlc.cli module

aiovlc.client module

Provide a client for aiovlc.

class aiovlc.client.Client(password: str, host: str = 'localhost', port: int = 4212, timeout: int = 10)[source]

Bases: object

Represent a client for aiovlc.

async add(playlist_item: str) None[source]

Send the add command.

async clear() None[source]

Send the clear command.

async connect() None[source]

Connect the client.

async disconnect() None[source]

Disconnect the client.

async enqueue(playlist_item: str) None[source]

Send the enqueue command.

async get_length() GetLengthOutput[source]

Send the get_length command.

async get_time() GetTimeOutput[source]

Send the get_time command.

async info() InfoOutput[source]

Send the info command.

async login() PasswordOutput[source]

Login.

async next() None[source]

Send the next command.

async pause() None[source]

Send the pause command.

async play() None[source]

Send the play command.

async prev() None[source]

Send the prev command.

async random(mode: Literal['on', 'off'] | None = None) None[source]

Send the random command.

async read(read_until: str = '\n') str[source]

Return a decoded message.

async seek(seconds: int) None[source]

Send the seek command.

async set_volume(volume: int) None[source]

Send the volume command with a parameter to set volume.

async status() StatusOutput[source]

Send the status command.

async stop() None[source]

Send the stop command.

async volume() VolumeOutput[source]

Send the volume command.

async write(command: str) None[source]

Write a command to the connection.

aiovlc.const module

Provide common constants.

aiovlc.exceptions module

Provide exceptions for aiovlc.

exception aiovlc.exceptions.AIOVLCError[source]

Bases: Exception

Represent a common error for aiovlc.

exception aiovlc.exceptions.AuthError[source]

Bases: AIOVLCError

Represent an authentication error.

exception aiovlc.exceptions.CommandError[source]

Bases: AIOVLCError

Represent a command error.

exception aiovlc.exceptions.CommandParameterError[source]

Bases: CommandError

Represent an error with a parameter when calling the command.

exception aiovlc.exceptions.CommandParseError[source]

Bases: CommandError

Represent an error when parsing the command output.

exception aiovlc.exceptions.ConnectError[source]

Bases: AIOVLCError

Represent a connection error for aiovlc.

exception aiovlc.exceptions.ConnectReadError(error: Exception, partial_bytes: bytes | None = None)[source]

Bases: ConnectError

The client failed to read.