Skip to content

test_os.TimerfdTests fails on FreeBSD 14 and 15: missing select.epoll() #110697

Closed
@vstinner

Description

@vstinner

os.timerfd_create() is documented to be available only on Linux, but it's always available on FreeBSD 14.

Problem: the test uses epoll() which is not available on FreeBSD. The test should be redesigned with selectors.DefaultSelector to become portable.

os.timerfd_create() was added recently to the main branch by PR gh-108382: see issue gh-108277.

cc @m-tmatma

Logs:

======================================================================
ERROR: test_timerfd_epoll (test.test_os.TimerfdTests.test_timerfd_epoll)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/buildbot/buildarea/3.x.opsec-fbsd14/build/Lib/test/test_os.py", line 4099, in test_timerfd_epoll
    ep = select.epoll()
         ^^^^^^^^^^^^
AttributeError: module 'select' has no attribute 'epoll'. Did you mean: 'poll'?

======================================================================
ERROR: test_timerfd_ns_epoll (test.test_os.TimerfdTests.test_timerfd_ns_epoll)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/buildbot/buildarea/3.x.opsec-fbsd14/build/Lib/test/test_os.py", line 4255, in test_timerfd_ns_epoll
    ep = select.epoll()
         ^^^^^^^^^^^^
AttributeError: module 'select' has no attribute 'epoll'. Did you mean: 'poll'?

FreeBSD 14 build: https://buildbot.python.org/all/#/builders/1232/builds/208

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions