Toolkit for compiling and executing the Linden Scripting Language as Python
Project description
Lummao
Lummao is a toolkit for compiling and executing the Linden Scripting Language as Python. It aims to ease testing of LSL code by leveraging Python's existing ecosystem for debugging and testing. Think of it as the less opinionated, stupider cousin of LSLForge's unit testing framework.
The runtime is largely handled by the excellent implementation of LSL's basic operations and library functions from Sei Lisa's LSL-PyOptimizer. See vendor/lslopt for Lummao's vendored copy of LSL-Pyoptimizer.
To see an example input script and its Python output, see the test_resources
directory.
Setup
pip install --upgrade pip
pip install lummao
From source
- Download https://github.com/SaladDais/tailslide and follow the compilation instructions, doing
make install
at the end - Download https://github.com/SaladDais/Lummao
pip install -e .
How
For a real-world example, see https://github.com/SaladDais/SLGraphPather's tests and test coverage reporting.
Along with the python API, a helper lummao
script is provided that takes in an LSL file and outputs a python file.
It can be invoked like lummao input.lsl output.py
.
Why
If you've ever written a sufficiently complicated system in LSL, you know how annoying it is to debug your scripts or be sure if they're even correct. Clearly the sanest way to bring sanity to your workflow is to convert your LSL scripts to Python, so you can mock LSL library functions and use Python debuggers. Hence the name "Lummao".
TODO
- Symbol shadowing behavior is not correct. Python has very different shadowing rules.
- Provide mock helpers for:
-
- inter-script communication
-
- HTTP
-
- auto-stubs for all functions
-
- state-aware event queueing
License
GPLv3
Licensing Clarifications
The output of the compiler necessarily links against the GPL-licensed runtime code from LSL-PyOptimizer for functionality, and LSL-PyOptimizer does not provide a library exception in its license. You should assume that any LSL converted to Python by the compiler and any testcases you write exercising them must also be distributable under the GPL.
In short: If or when you distribute your testcases, you must also allow distribution of their direct dependencies (your LSL scripts) under the terms of the GPL. This does not necessarily change the license of your LSL scripts themselves, or require consumers of your scripts to license their own scripts under the GPL. It is perfectly possible to have an otherwise MIT-licensed or proprietary library with a GPL-licensed test suite. No distribution of testcases == no requirement to distribute under the GPL.
Suggested reading to understand your rights and obligations under the GPL when using a GPL-licensed test suite:
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
Built Distributions
File details
Details for the file lummao-0.3.0.post2.tar.gz
.
File metadata
- Download URL: lummao-0.3.0.post2.tar.gz
- Upload date:
- Size: 239.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c00d9840ab33bf8d2bd63ac1d59518ea85608d2d81b435e79fcc580e540400aa |
|
MD5 | 0f1bb1ce9d2dd9736f4de8ba1595c5a4 |
|
BLAKE2b-256 | 28f4b752bddc7951fb9990139ceaca038aad0b1fedfa001c8b6da4a4b688ce8b |
File details
Details for the file lummao-0.3.0.post2-cp38-abi3-win_amd64.whl
.
File metadata
- Download URL: lummao-0.3.0.post2-cp38-abi3-win_amd64.whl
- Upload date:
- Size: 193.4 kB
- Tags: CPython 3.8+, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7a340e0edbb6e1c4a04d6b1ba471fbffcff5a605ca22d79b443a3348a52ffb87 |
|
MD5 | adbd68874385e46c9b23adafef0a18ec |
|
BLAKE2b-256 | fca4bae99a153769d1bb25c310babd787b8cd2f4673e7c5ba1a61372011b77f6 |
File details
Details for the file lummao-0.3.0.post2-cp38-abi3-manylinux_2_24_x86_64.whl
.
File metadata
- Download URL: lummao-0.3.0.post2-cp38-abi3-manylinux_2_24_x86_64.whl
- Upload date:
- Size: 3.5 MB
- Tags: CPython 3.8+, manylinux: glibc 2.24+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b57145b07b38078b6a90855bd64a65b806e7cf98a9973ac9ff8969d7580a2fef |
|
MD5 | d0563df1c7640d6f71265c8d3b56eeb4 |
|
BLAKE2b-256 | 788d3d13d0ab11525a5efc7005ed77979322307130f87586301d0fb7d54170cd |
File details
Details for the file lummao-0.3.0.post2-cp38-abi3-macosx_10_15_x86_64.whl
.
File metadata
- Download URL: lummao-0.3.0.post2-cp38-abi3-macosx_10_15_x86_64.whl
- Upload date:
- Size: 238.1 kB
- Tags: CPython 3.8+, macOS 10.15+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d9df3d97a93d545bbb0133304de15eb69e70a3f51f4d3de4f122972f3a922481 |
|
MD5 | 9a8b64f6ea7518877792422d028ea741 |
|
BLAKE2b-256 | 444017a318e4d6cf75ae0495ddaa476d1e3904a4a62c1ec37b6e6cff5c5d3102 |