Skip to content

test_xpickle failure, something about builtins.sentinel #149650

@smontanaro

Description

@smontanaro

Bug report

Bug description:

test_xpickle is failing on MacOS for me (main branch). It seems there's a new sentinel name in builtins. I see a bunch tracebacks like this:

ERROR: test_builtin_types (test.test_xpickle.CPicklePython315Compat.test_builtin_types) (name='sentinel', proto=5)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/skip/src/python/cpython/Lib/test/pickletester.py", line 3300, in test_builtin_types
    s = self.dumps(t, proto)
  File "/Users/skip/src/python/cpython/Lib/test/test_xpickle.py", line 190, in dumps
    return self.send_to_worker(python, data)
           ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
  File "/Users/skip/src/python/cpython/Lib/test/test_xpickle.py", line 172, in send_to_worker
    raise exception
AttributeError: module 'builtins' has no attribute 'sentinel'

I suspect it's expecting – but not finding – sentinel in the builtins of older versions. The test finds versions of the interpreter on my machine from 3.7 onwards. FWIW, it passes on my Ubuntu laptop (many fewer versions of the interpreter there, however). Seems odd that it would be MacOS-specific though.

CPython versions tested on:

CPython main branch

Operating systems tested on:

macOS

Metadata

Metadata

Assignees

No one assigned

    Labels

    pendingThe issue will be closed if no feedback is providedtestsTests in the Lib/test dirtype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions