Metadata-Version: 2.5
Name: worldcut
Version: 0.1.1
Summary: Independent Python verifier for the WorldCut decision-coherence protocol
Project-URL: Homepage, https://github.com/Jason-Doyle/WorldCut
Project-URL: Issues, https://github.com/Jason-Doyle/WorldCut/issues
Project-URL: Repository, https://github.com/Jason-Doyle/WorldCut
Author: Jason Doyle
License-Expression: Apache-2.0
Keywords: consistency,distributed-systems,provenance,verification
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Typing :: Typed
Requires-Python: >=3.11
Requires-Dist: rfc8785==0.1.4
Provides-Extra: dev
Requires-Dist: build>=1.2.2; extra == 'dev'
Requires-Dist: hypothesis>=6.130; extra == 'dev'
Requires-Dist: mypy>=1.15; extra == 'dev'
Requires-Dist: pytest>=8.3; extra == 'dev'
Requires-Dist: ruff>=0.11; extra == 'dev'
Requires-Dist: twine>=6.1; extra == 'dev'
Description-Content-Type: text/markdown

# WorldCut Python

Independent Python implementation of WorldCut protocol **0.1**, engine
**0.1.2**, and canonicalization **worldcut-json-v1**. Python 3.11 or newer is
required.

## Install

Install from PyPI after the `0.1.1` registry release is live:

```sh
python -m pip install worldcut==0.1.1
```

Until then, or when a source install is preferred, use the protected tag:

```sh
python -m pip install "worldcut @ git+https://github.com/Jason-Doyle/WorldCut.git@ports/python/v0.1.1#subdirectory=ports/python"
```

## Library

```python
from pathlib import Path

from worldcut import parse_input, verify

parsed = parse_input(Path("verification.json").read_bytes())
result = verify(parsed)
print(result["verdict"])
print(result["verificationRecordDigest"])
```

`ParsedInput` is an immutable validated snapshot. Every verification returns a
fresh result, so mutating one result cannot affect later verification.

## CLI

```sh
worldcut-py verification.json
worldcut-py --require-satisfied verification.json
```

The second form exits with status 2 unless the verdict is
`CONTRACT_SATISFIED`.

## Validate

```sh
python -m pip install -e ".[dev]"
ruff format --check .
ruff check .
mypy src
pytest
python -m build
twine check dist/*
```

The source distribution includes the complete mirrored conformance corpus and
can run its tests without files from the parent repository. This port includes
the verifier and CLI only; integrations are intentionally not included yet.
