Skip to main content

Integrity

GitHub Actions PyPI PyPI - Python Version Code style: black Discord

Development facilities for the bolt environment

from integrity import Component

from ./settings import settings
from ./blocks import blocks
from ./player import player

main = Component()

function main.on("main"):
    if score settings.data.activated obj matches 1:
        main.run("active")

function main.on("active"):
    as @a at @s:
        player.run("main")

function blocks.on("placed_by_player"):
    if block ~ ~ ~ stone expand:
        say Placed stone!
        player.run("placed_stone")

Installation

The package can be installed with pip. Note, you must have both beet and mecha installed to use this package.

$ pip install integrity

Getting Started

To use this package, we must add the plugin to the require section in the beet project file alongside with mecha and bolt.

require:
    - bolt
    - integrity
pipeline:
    - mecha

Now that we've enabled integrity, we can import the module directly inside a bolt script

from integrity import Component

foo = Component("foo")

Features

  • Components

Contributing

Contributions are welcome. Make sure to first open an issue discussing the problem or the new feature before creating a pull request. The project uses poetry.

$ poetry install

You can run the tests with poetry run pytest.

$ poetry run pytest

The project must type-check with pyright. If you're using VSCode the pylance extension should report diagnostics automatically. You can also install the type-checker locally with npm install and run it from the command-line.

$ npm run watch
$ npm run check

The code follows the black code style. Import statements are sorted with isort.

$ poetry run isort bolt_expressions examples tests
$ poetry run black bolt_expressions examples tests
$ poetry run black --check bolt_expressions examples tests

License - MIT

Metadata

Release files for integrity 0.9.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for integrity 0.9.0
File Size Uploaded
integrity-0.9.0.tar.gz 6.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for integrity 0.9.0
File Interpreter ABI Platform
integrity-0.9.0-py3-none-any.whl Python 3 none any Details

Total release size: 12.5 kB

Release files / integrity-0.9.0.tar.gz

Download URL integrity-0.9.0.tar.gz
Size 6.0 kB
Tags Source
SHA-256 checksum
How to use checksums
25cd7be964de1d2f13e4772f9744bf7a0c136f06713986601639856da2daf238
BLAKE2b-256 checksum
How to use checksums
38c96cecc3f5a0463517f30b744cd32d0849682a73306f4d3a195a25ab175bbd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.3 readme-renderer/35.0 requests/2.28.0 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.64.0 importlib-metadata/4.11.4 keyring/23.6.0 rfc3986/2.0.0 colorama/0.4.5 CPython/3.10.5

Release files / integrity-0.9.0-py3-none-any.whl

Download URL integrity-0.9.0-py3-none-any.whl
Size 6.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0b2b04fa5ba8a4a1c9dfa5094f2898f3653e07d9d27601ac28323e8f106bbf2c
BLAKE2b-256 checksum
How to use checksums
fcb373c3fe947d541c7c8e2f192f0a72289e07c64cc532d9fed8176befd0157a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.3 readme-renderer/35.0 requests/2.28.0 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.64.0 importlib-metadata/4.11.4 keyring/23.6.0 rfc3986/2.0.0 colorama/0.4.5 CPython/3.10.5

Release history Release notifications | RSS feed

This release

0.9.0 This release

2 release files

0.8.0

2 release files

0.7.1

2 release files

0.7.0

2 release files

0.6.1

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page