An async library/wrapper for interacting with remote consoles on Minecraft Java Edition servers
Project description
Aio-MC-RCON
An asynchronous RCON client/wrapper written in Python for Minecraft Java Edition servers!
Installation
pip install -U aio-mc-rcon
Example Usage
- See the examples folder.
Documentation
class aiomcrcon.Client(host: str, port: int, password: str):
- Arguments:
host: str
- The hostname / ip of the server to connect to.port: int
- The port of the server to connect to.password: str
- The password to connect, can be found as the value underrcon.password
in theserver.properties
file.
- Methods:
connect(timeout: int = 2)
- wheretimeout
has a default value of 2 seconds.send_cmd(cmd: str, timeout: int = 2)
- wherecmd
is the command to be executed on the server and timeout has a default value of 2 seconds.close()
- closes the connection between the client and server.
exception aiomcrcon.RCONConnectionError
- Raised when the connection to the server fails.
exception aiomcrcon.IncorrectPasswordError
- Raised when the provided password/authentication is invalid.
exception aiomcrcon.ClientNotConnectedError
- Raised when the connect() method hasn't been called yet, and commands cannot be sent.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
aio-mc-rcon-3.0.1.tar.gz
(4.1 kB
view hashes)
Built Distribution
Close
Hashes for aio_mc_rcon-3.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bc402d07ac6cafd9954f5ce355477ac3ab5e71a35a24e4b82f4783c72b143d7d |
|
MD5 | dffaef14fed66bebc56368696a4ce498 |
|
BLAKE2b-256 | 9d812a61402007fa3fd09814c3547554207f4a7be71b2539052ef11daf88392c |