Python 3.11: A Guided Tour Through Code Transcripts
Chapter: A Grab Bag of Minor Updates
Lecture: File Formats

Login or purchase this course to watch this video and the rest of the course contents.
0:00 The first subtopic here is file formats and the big one here is TOML. So you're probably familiar with toml. Will you use it to do things with Docker?
0:12 You use it for clearly the pyproject.html, which is becoming the new replacement for setup.py and packaging.
0:21 Previously. Until now, if you wanted to work with toml, will you had to go find a separate library? Unlike Json?
0:28 Right. There's a Json library right inside of python that just comes with it.
0:33 But toml, even though we had pyproject.Toml and it was used for packaging, you had to get a third party library. Not totally weird for python.
0:42 There are over 400,000 packages on PyPI. However,
0:47 some things cause this maybe you don't want to have to depend upon external TOML libraries and with 3.11,
0:54 you no longer have to, we have bpo-40059 and that's also PEP680.
1:00 So, the Toml lib module now includes built in parson for Toml and mentioning Json if you're using the Json
1:11 decoder, it now raises a different type of exception. A Json decode error instead of a value error. So,
1:17 if you've got code that catches the value error out of the Json decoder might want to go have a look at that and update it.


Talk Python's Mastodon Michael Kennedy's Mastodon