Kodiologist · GitHub

Bug report

Bug description:

Python 3.14.0a2+ (main, Dec  8 2024, 10:50:32) [GCC 14.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> bytes.fromhex('deadbee')
Traceback (most recent call last):
  File "<python-input-0>", line 1, in <module>
    bytes.fromhex('deadbee')
    ~~~~~~~~~~~~~^^^^^^^^^^^
ValueError: non-hexadecimal number found in fromhex() arg at position 7
>>> bytes.fromhex('deadbeef')
b'\xde\xad\xbe\xef'

I suggest: ValueError: fromhex() arg must be of even length.

CPython versions tested on:

3.12, CPython main branch

Operating systems tested on:

Linux

Linked PRs

Read the original on github.com ↗