Skip to content

Latest commit

 

History

History
69 lines (49 loc) · 1.97 KB

File metadata and controls

69 lines (49 loc) · 1.97 KB

Contributing

Thank you for contributing to the CreateOS Python SDK.

Setup

Create a virtual environment and install the SDK with its development tools:

python -m venv .venv
.venv/bin/pip install -e '.[dev]'

Run the complete local check suite:

.venv/bin/ruff format --check src tests examples
.venv/bin/ruff check src tests examples
.venv/bin/mypy src/createos --ignore-missing-imports
.venv/bin/pytest --cov=createos --cov-fail-under=70

Commit convention

Use Conventional Commits:

<type>(<optional-scope>): <subject>

Accepted types are feat, fix, docs, style, refactor, test, chore, and perf. Write the subject in imperative mood, keep it at 50 characters or fewer, start it with a lowercase letter, and do not end it with a period.

Examples:

feat(sandbox): add disk attachment
fix(transport): honor retry-after header
docs(readme): add network example
test(processes): cover output replay
chore: prepare v0.1.0 release

For an incompatible public API change, add ! before the colon and explain the change in a BREAKING CHANGE: commit footer:

feat(sandbox)!: change create response

Before opening a pull request

Run the complete local check suite. Add or update tests for behavior changes, and update public docstrings and README examples when the public API changes.

Releasing

The package is published manually to PyPI as createos-sandbox.

  1. Bump __version__ in src/createos/_version.py (the single source of truth — pyproject.toml reads it) and move the CHANGELOG.md [Unreleased] entries under the new version.
  2. Dry run the release gate: ./scripts/publish.sh --dry.
  3. Publish: ./scripts/publish.sh. It reruns tests, lint, types, builds the sdist and wheel, uploads with twine, then tags and pushes v<version>.

Uploading needs a PyPI API token, e.g. in ~/.pypirc or as TWINE_USERNAME=__token__ TWINE_PASSWORD=pypi-....