picnixz · GitHub

Bug report

Bug description:

./python -c 'import sys; import itertools; print(itertools.count(sys.maxsize))'
count(<NULL>)

This aborts on DEBUG builds. See #126595 (comment).

I'd like to address this issue separately since the free-threaded code would be different.

CPython versions tested on:

CPython main branch

Operating systems tested on:

No response

Linked PRs

Read the original on github.com ↗