Skip to main content

Style preserving TOML library

Project description

GitHub Release PyPI Version Python Versions License
Tests

TOML Kit - Style-preserving TOML library for Python

TOML Kit is a 1.1.0-compliant TOML library.

It includes a parser that preserves all comments, indentations, whitespace and internal element ordering, and makes them accessible and editable via an intuitive API.

You can also create new TOML documents from scratch using the provided helpers.

Part of the implementation has been adapted, improved and fixed from Molten.

Usage

See the documentation for more information.

Installation

If you are using uv, you can add tomlkit to your pyproject.toml file by using:

uv add tomlkit

Or just:

uv pip install tomlkit

If not, you can use pip:

pip install tomlkit

Running tests

Please clone the repo with submodules with the following command:

git clone --recurse-submodules https://github.com/python-poetry/tomlkit.git

The toml-test submodule is required for running the tests.

You can then run the tests with

poetry run pytest -q tests

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

tomlkit-0.15.0.tar.gz (161.9 kB view details)

Uploaded Source

Built Distribution

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

tomlkit-0.15.0-py3-none-any.whl (41.3 kB view details)

Uploaded Python 3

File details

Details for the file tomlkit-0.15.0.tar.gz.

File metadata

  • Download URL: tomlkit-0.15.0.tar.gz
  • Upload date:
  • Size: 161.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.12.3 Linux/6.17.0-1010-azure

File hashes

Hashes for tomlkit-0.15.0.tar.gz
Algorithm Hash digest
SHA256 7d1a9ecba3086638211b13814ea79c90dd54dd11993564376f3aa92271f5c7a3
MD5 e50005d2f05d57d234fde1f47a4a6bae
BLAKE2b-256 51db03eaf4331631ef6b27d6e3c9b68c54dc6f0d63d87201fed600cc409307fd

See more details on using hashes here.

File details

Details for the file tomlkit-0.15.0-py3-none-any.whl.

File metadata

  • Download URL: tomlkit-0.15.0-py3-none-any.whl
  • Upload date:
  • Size: 41.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.12.3 Linux/6.17.0-1010-azure

File hashes

Hashes for tomlkit-0.15.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4dbc8f0fc024412b57ced8757ac7461305126a648ff8c2c807fcb8e133a78738
MD5 cd32d7135162074f22ea0b287554660e
BLAKE2b-256 6a438bd850ee71a191bf072e31302c73a66be413fecdd98fdcd111ecbcce13ca

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