I think yaml was a perfectly fine way to express a hash/dict like config. I am surprised that toml was so widely adopted by the community.
Python
Welcome to the Python community on the programming.dev Lemmy instance!
π Events
Past
November 2023
- PyCon Ireland 2023, 11-12th
- PyData Tel Aviv 2023 14th
October 2023
- PyConES Canarias 2023, 6-8th
- DjangoCon US 2023, 16-20th (!django π¬)
July 2023
- PyDelhi Meetup, 2nd
- PyCon Israel, 4-5th
- DFW Pythoneers, 6th
- Django Girls Abraka, 6-7th
- SciPy 2023 10-16th, Austin
- IndyPy, 11th
- Leipzig Python User Group, 11th
- Austin Python, 12th
- EuroPython 2023, 17-23rd
- Austin Python: Evening of Coding, 18th
- PyHEP.dev 2023 - "Python in HEP" Developer's Workshop, 25th
August 2023
- PyLadies Dublin, 15th
- EuroSciPy 2023, 14-18th
September 2023
- PyData Amsterdam, 14-16th
- PyCon UK, 22nd - 25th
π Python project:
- Python
- Documentation
- News & Blog
- Python Planet blog aggregator
π Python Community:
- #python IRC for general questions
- #python-dev IRC for CPython developers
- PySlackers Slack channel
- Python Discord server
- Python Weekly newsletters
- Mailing lists
- Forum
β¨ Python Ecosystem:
π Fediverse
Communities
- #python on Mastodon
- c/django on programming.dev
- c/pythorhead on lemmy.dbzer0.com
Projects
- PythΓΆrhead: a Python library for interacting with Lemmy
- Plemmy: a Python package for accessing the Lemmy API
- pylemmy pylemmy enables simple access to Lemmy's API with Python
- mastodon.py, a Python wrapper for the Mastodon API
Feeds
Yaml is fine until you want to abbreviate Norway and get false... toml doesn't handle everything well but at least it doesn't have insane problems like that.
While that shouldn't happen with a current-spec YAML parser, I agree even the current spec does way too much with types.
I've come to love NestedText's approach of leaving all type handling to the ingesting code.
You should make a post about NestedText. That looks interesting and pretty close to my own internal note-taking style.
Would you suggest a topic or tooling to pair with it, so I can provide a good demo for working with it in a real and useful context?
I made a CLI tool for working with it but want to avoid making a look-at-me spammy post, and I think the NestedText site itself explains the ideas pretty well already.
First, I have to apologize, I just meant post a link to NestText as a post in c/Python. I definitely didn't mean to imply you should have to go write a blog post (or something) about it just for me. I swear this was just an attempt to get another person posting interesting things to c/Python. π¬
Looking through the community projects and docs, the use cases/tooling that really stood out to me were:
parametrize_from_file
, for definingpytest
parametrize
params in a file- validating NestedText content with Pydantic, particularly something like the example Django settings they provide
Thinking about how I might use it:
- Meeting notes
- A personal log of todo items, observations, feelings during the day
- Scoring a baseball game using a more sane version of Retrosheet's Event File format
- A possible human AND machine readable format for Architectural Decision Records
As someone who had tried to wrap their mind around YAML spec...
Fuck yaml. It is ridiculous how much junk there is in that spec.
YAML is extremely complex for a configuration format and it has many really weird edge cases:
The problem is IMHO made worse because it looks so friendly at first glance.
I love toml. It's so natural. I use it all the time (for smaller configs)