pyevilgenius
Asynchronous library to control devices by Evil Genius Labs
Requires Python 3.8+ and uses asyncio and aiohttp.
import asyncio
from pprint import pprint
import aiohttp
from pyevilgenius import EvilGeniusDevice
HOST = "192.168.1.113"
async def main():
async with aiohttp.ClientSession() as session:
await run(session)
async def run(websession):
device = pyevilgenius.EvilGeniusDevice(host, websession)
data = await client.get_data()
pprint(device.details)
await device.set_path_value('power', '1')
asyncio.run(main())
Testing locally
python3 example.py <host>
Timeouts
Pyevilgenius does not specify any timeouts for any requests. You will need to specify them in your own code. We recommend the async_timeout package:
import async_timeout
with async_timeout.timeout(10):
devices = await hub.get_device_list()
Contribution guidelines
Object hierarchy and property/method names should match the Evil Genius Device APIs.
Metadata
Release files for pyevilgenius 2.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pyevilgenius-2.0.0.tar.gz | 6.6 kB | Without provenance | Details for pyevilgenius-2.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pyevilgenius-2.0.0-py3-none-any.whl | Python 3 | none | any | Details for pyevilgenius-2.0.0-py3-none-any.whl |
Total release size: 13.5 kB
Release files / pyevilgenius-2.0.0.tar.gz
| Download URL | pyevilgenius-2.0.0.tar.gz |
|---|---|
| Size | 6.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0dcf3bf5c6347650efd9bd3c13f37650439c181736fba34ae7228023ea9035ae
|
|
BLAKE2b-256 checksum How to use checksums |
7052be37508c166b91447c0c30e855a3d790dc01eef27e10435bdb0e8f52c761
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.10.4
|
Release files / pyevilgenius-2.0.0-py3-none-any.whl
| Download URL | pyevilgenius-2.0.0-py3-none-any.whl |
|---|---|
| Size | 6.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
cbc63cbf5f3ede3985df364d4c3a6af76010bd5876e554b68619f64a0d150ea1
|
|
BLAKE2b-256 checksum How to use checksums |
162c7548aa00c38d1f6d151a9adaca2df5278ef350322b82cfcad80c5c2f4526
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.10.4
|
Security for pyevilgenius 2.0.0
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.