tomli-w icon indicating copy to clipboard operation
tomli-w copied to clipboard

A lil' TOML writer (counterpart to https://github.com/hukkin/tomli)

Results 7 tomli-w issues
Sort by recently updated
recently updated
newest added

updates: - [github.com/PyCQA/isort: dbf82f2dd09ae41d9355bcd7ab69187a19e6bf2f → c235f5e450b4b84e58d114ed4c589cbf454175a3](https://github.com/PyCQA/isort/compare/dbf82f2dd09ae41d9355bcd7ab69187a19e6bf2f...c235f5e450b4b84e58d114ed4c589cbf454175a3) - [github.com/psf/black: e87737140f32d3cd7c44ede75f02dcd58e55820e → b965c2a5026f8ba399283ba3e01898b012853c79](https://github.com/psf/black/compare/e87737140f32d3cd7c44ede75f02dcd58e55820e...b965c2a5026f8ba399283ba3e01898b012853c79) - [github.com/pre-commit/pre-commit-hooks: f71fa2c1f9cf5cb705f73dffe4b21f7c61470ba9 → 2c9f875913ee60ca25ce70243dc24d5b6415598c](https://github.com/pre-commit/pre-commit-hooks/compare/f71fa2c1f9cf5cb705f73dffe4b21f7c61470ba9...2c9f875913ee60ca25ce70243dc24d5b6415598c) - [github.com/PyCQA/flake8: 10f4af6dbcf93456ba7df762278ae61ba3120dc6 → e43806be3607110919eff72939fda031776e885a](https://github.com/PyCQA/flake8/compare/10f4af6dbcf93456ba7df762278ae61ba3120dc6...e43806be3607110919eff72939fda031776e885a) - [github.com/pre-commit/mirrors-mypy: 08cbc46b6e135adec84911b20e98e5bc52032152 → d4911cfb7f1010759fde68da196036feeb25b99d](https://github.com/pre-commit/mirrors-mypy/compare/08cbc46b6e135adec84911b20e98e5bc52032152...d4911cfb7f1010759fde68da196036feeb25b99d)

Current type hinting with `dict` is too strict, and read-only types like MappingProxyType are refused by type checkers.

@hukkin If it's alright with you, this seems to be preferred by most people and is also used in the examples https://toml.io/en/v1.0.0#array

Hi! Below, I provide (A) the output of the latest Tomli-W and (B) what I propose for "simple" lists (i.e. those containing only literal values: booleans, numbers, strings, time). The...

enhancement

Hello again! This is the counterpart to https://github.com/hukkin/tomli/pull/165, without (hopefully?) the bootstrapping concerns 🙂

Alternative to https://github.com/hukkin/tomli-w/pull/27 (keeps backwards compatibility). Allows using `tomli_w.dumps(data, indent=2)` similar like stdlib `json.dumps`.

It would be nice if pathlib.Path objects were serializable by default: ```py import pathlib import tomli_w root_dir = pathlib.Path("/") data = { "target": { "ip": "xx.xx.xx.xx", "os": { "os": "win...