Skip to main content

Add your description here

Project description

lyric-py-worker

A Python worker implementation for the lyric.

It allows you to run your python code in a wasm environment.

Installation

pip install lyric-py-worker

How To Add Your Dependencies

  1. You can add your dependencies to the app-requrements.txt file.
echo "chardet" >> app-requirements.txt
  1. Import the dependencies src/worker.py

Modify the src/worker.py file to import your dependencies.

import asyncio
# ...
# Import your dependencies at the top of the file
import chardet
# ...
import shortuuid
from lyric_task.std import *
  1. Build the worker
make build

After building the worker, you can see the wheel file in the ../dist directory.

ls ../dist/lyric_py_worker-*.whl
../dist/lyric_py_worker-0.1.7rc0-py3-none-any.whl

The output may be like the above.

  1. Install the worker

You can install your worker using the following command.

pip install --force-reinstall lyric_py_worker-0.1.7rc0-py3-none-any.whl

Make sure to replace the wheel file name with the one you have and the path to the wheel file.

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

lyric_py_worker-0.1.7.tar.gz (10.8 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lyric_py_worker-0.1.7-py3-none-any.whl (10.9 MB view details)

Uploaded Python 3

File details

Details for the file lyric_py_worker-0.1.7.tar.gz.

File metadata

  • Download URL: lyric_py_worker-0.1.7.tar.gz
  • Upload date:
  • Size: 10.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for lyric_py_worker-0.1.7.tar.gz
Algorithm Hash digest
SHA256 06328b3806bddac258fcc81eab444c351d22157839c0f7d2f5ac1a1df5bfe179
MD5 4319abf41937e5a33a3f6a9453c57b2c
BLAKE2b-256 286e674988e462db7e9748688713a8b3e24034848c3a5518f1bbed7f7ec9b183

See more details on using hashes here.

File details

Details for the file lyric_py_worker-0.1.7-py3-none-any.whl.

File metadata

File hashes

Hashes for lyric_py_worker-0.1.7-py3-none-any.whl
Algorithm Hash digest
SHA256 fb2f437bad7638185f1ef182722d449523dd7a518400744dc42a99cb3d8e25a3
MD5 f29adf389f5c0218bac272df496e4cf3
BLAKE2b-256 f8c44d68e8d32a5e0876ede77af11c4a10739e47a0688c91eae9194935cec86a

See more details on using hashes here.

Supported by

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