Skip to content

Commit 8c15afd

Browse files
Updated to support TOML 1.1.0
1 parent 4aef138 commit 8c15afd

File tree

13 files changed

+55
-21
lines changed

13 files changed

+55
-21
lines changed

Doc/library/tomllib.rst

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
--------------
1515

16-
This module provides an interface for parsing TOML 1.0.0 (Tom's Obvious Minimal
16+
This module provides an interface for parsing TOML 1.1.0 (Tom's Obvious Minimal
1717
Language, `https://toml.io <https://toml.io/en/>`_). This module does not
1818
support writing TOML.
1919

@@ -31,6 +31,10 @@ support writing TOML.
3131
It is a recommended replacement for this module for editing already
3232
existing TOML files.
3333

34+
.. versionchanged:: next
35+
36+
This module supports TOML 1.1.0.
37+
3438

3539
This module defines the following functions:
3640

Doc/whatsnew/3.15.rst

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -751,6 +751,7 @@ timeit
751751
:ref:`environment variables <using-on-controlling-color>`.
752752
(Contributed by Yi Hong in :gh:`139374`.)
753753

754+
754755
tkinter
755756
-------
756757

@@ -765,8 +766,16 @@ tkinter
765766
using Tcl's ``-all`` and ``-overlap`` options.
766767
(Contributed by Rihaan Meher in :gh:`130848`)
767768

769+
770+
tomllib
771+
-------
772+
773+
* Updated to support `TOML 1.1.0
774+
<https://github.com/toml-lang/toml/blob/1.1.0/CHANGELOG.md#110--2025-12-18>`__.
775+
776+
768777
types
769-
------
778+
-----
770779

771780
* Expose the write-through :func:`locals` proxy type
772781
as :data:`types.FrameLocalsProxyType`.
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
22
"local-dt": {"type":"datetime-local","value":"1988-10-27t01:01:01"},
3-
"zulu-dt": {"type":"datetime","value":"1988-10-27t01:01:01z"}
3+
"zulu-dt": {"type":"datetime","value":"1988-10-27t01:01:01z"},
4+
"local-dt-nosec": {"type":"datetime-local","value":"1988-10-27T14:30:00"}
45
}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
local-dt=1988-10-27t01:01:01
22
zulu-dt=1988-10-27t01:01:01z
3+
local-dt-nosec=1988-10-27T14:30
Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
1-
{"t":
2-
{"type":"time-local","value":"00:00:00.999999"}}
1+
{
2+
"t": {"type":"time-local","value":"00:00:00.999999"},
3+
"t2": {"type":"time-local","value":"14:30:00"}
4+
}
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
t=00:00:00.99999999999999
1+
t=00:00:00.99999999999999
2+
t2=14:30
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
{
22
"a": {"type":"string","value":"a"},
33
"b": {"type":"string","value":"b"},
4-
"c": {"type":"string","value":"c"}
4+
"c": {"type":"string","value":"c"},
5+
"d": {"type":"string","value":"d"},
6+
"esc": {"type":"string","value":"\u001b"}
57
}
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
a="\u0061"
22
b="\u0062"
3-
c="\U00000063"
3+
c="\U00000063"
4+
d="\x64"
5+
esc="\e"
Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
1-
{"arr":
2-
{"type":"array","value":
3-
[
4-
{"type":"integer","value":"1"}
5-
]
6-
}
1+
{
2+
"arr": {"type":"array","value":[{"type":"integer","value":"1"}]},
3+
"tbl": {"a":{"type":"integer","value":"1"}},
4+
"tbl2": {"b":{"type":"integer","value":"2"}}
75
}
Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
1-
arr=[1,]
1+
arr=[1,]
2+
tbl={a=1,}
3+
tbl2={
4+
b=2,
5+
}

0 commit comments

Comments
 (0)