-
-
Notifications
You must be signed in to change notification settings - Fork 32.7k
Closed
Labels
type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
Description
Bug report
Checklist
- I am confident this is a bug in CPython, not a bug in a third-party project
- I have searched the CPython issue tracker,
and am confident this bug has not been reported before
CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Output from running 'python -VV' on the command line:
Python 3.13.0a0 (heads/demo/parser:a794ebeb02, Aug 22 2023, 11:44:58) [GCC 11.3.0]
A clear and concise description of the bug:
There are some tests in the decimal module related to large numbers, they may fail due to the patch of CVE-2020-10735 (large int<->str conversions). Here is a benchmark in decimal.
cd ./Modules/_decimal/tests
../../../python bench.py
Output:
...
# ======================================================================
# Factorial
# ======================================================================
n = 100000
cdecimal:
calculation time: 0.942886s
conversion time: 0.002155s
Traceback (most recent call last):
File "/home/github/cpython/Modules/_decimal/tests/bench.py", line 121, in <module>
sy = str(y)
^^^^^^
ValueError: Exceeds the limit (4300 digits) for integer string conversion; use sys.set_int_max_str_digits() to increase the limit
Linked PRs
Metadata
Metadata
Assignees
Labels
type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error