We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9032491 commit f77fd62Copy full SHA for f77fd62
tests/cpydiff/types_str_formatsep.py
@@ -0,0 +1,19 @@
1
+"""
2
+categories: Types,str
3
+description: MicroPython accepts the "," grouping option with any radix, unlike CPython
4
+cause: To reduce code size, MicroPython does not issue an error for this combination
5
+workaround: Do not use a format string like ``{:,b}`` if CPython compatibility is required.
6
7
+
8
+try:
9
+ print("{:,b}".format(99))
10
+except ValueError:
11
+ print("ValueError")
12
13
+ print("{:,x}".format(99))
14
15
16
17
+ print("{:,o}".format(99))
18
19
0 commit comments