Home - Summaries: (main) : (py3.11) : Everything - Nightly builds - Benchmarks - RPython - Builders - About

lib-python/3/test/test_audit.py::unmodified

== PyPy 3.12.13 (37b9293223c4, Jul 09 2026, 17:47:31) [PyPy 8.0.0-alpha0 with GCC 10.2.1 20210130 (Red Hat 10.2.1-11)]
== Linux-6.1.0-22-amd64-x86_64-with-glibc2.17 little-endian
== Python build: release with_assert
== cwd: /tmp/pytest/test_python_worker_1092385æ
== CPU count: 4
== encodings: locale=UTF-8 FS=utf-8
== resources (3): curses,gui,network

Using random seed: 126542452
0:00:00 load avg: 1.00 Run 1 test sequentially in a single process
0:00:00 load avg: 1.00 [1/1] test_audit
test_basic (test.test_audit.AuditTest.test_basic) ... ok
test_block_add_hook (test.test_audit.AuditTest.test_block_add_hook) ... ok
test_block_add_hook_baseexception (test.test_audit.AuditTest.test_block_add_hook_baseexception) ... ok
test_cantrace (test.test_audit.AuditTest.test_cantrace) ... FAIL
test_excepthook (test.test_audit.AuditTest.test_excepthook) ... ok
test_gc (test.test_audit.AuditTest.test_gc) ... FAIL
test_http (test.test_audit.AuditTest.test_http) ... ('http.client.connect', ' ', 'www.python.org 80')
('http.client.send', ' ', "b'GET / HTTP/1.1\\r\\nHost: www.python.org\\r\\nAccept-Encoding: identity\\r\\n\\r\\n'")
ok
test_marshal (test.test_audit.AuditTest.test_marshal) ... FAIL
test_mmap (test.test_audit.AuditTest.test_mmap) ... ok
test_monkeypatch (test.test_audit.AuditTest.test_monkeypatch) ... FAIL
test_not_in_gc (test.test_audit.AuditTest.test_not_in_gc) ... ok
test_open (test.test_audit.AuditTest.test_open) ... ok
test_pickle (test.test_audit.AuditTest.test_pickle) ... ok
test_socket (test.test_audit.AuditTest.test_socket) ... ('socket.gethostname', '', '')
('socket.__new__', ' ', '<socket.socket fd=-1, family=0, type=0, proto=0> 2 1 0')
('socket.bind', ' ', "<socket.socket fd=3, family=2, type=1, proto=0, laddr=('0.0.0.0', 0)> ('127.0.0.1', 8080)")
ok
test_sqlite3 (test.test_audit.AuditTest.test_sqlite3) ... ('sqlite3.connect', ' ', "(':memory:',)")
('sqlite3.connect/handle', ' ', '(<_sqlite3.Connection object at 0x00007f2d8456bf30>,)')
('sqlite3.connect', ' ', "(':memory:',)")
('sqlite3.connect/handle', ' ', '(<_sqlite3.Connection object at 0x00007f2d8456bf68>,)')
('sqlite3.enable_load_extension', ' ', '(<_sqlite3.Connection object at 0x00007f2d8456bf30>, False)')
('sqlite3.load_extension', ' ', "(<_sqlite3.Connection object at 0x00007f2d8456bf30>, 'test')")
ok
test_sys_getframe (test.test_audit.AuditTest.test_sys_getframe) ... ('sys._getframe', ' ', 'test_sys_getframe')
ok
test_sys_getframemodulename (test.test_audit.AuditTest.test_sys_getframemodulename) ... ('sys._getframemodulename', ' ', '0')
ok
test_sys_monitoring_register_callback (test.test_audit.AuditTest.test_sys_monitoring_register_callback) ... FAIL
test_syslog (test.test_audit.AuditTest.test_syslog) ... Events:
  ('syslog.openlog', ' ', 'python 0 8')
  ('syslog.syslog', ' ', '6 test')
  ('syslog.setlogmask', ' ', '7')
  ('syslog.closelog', '', '')
  ('syslog.syslog', ' ', '6 test2')
  ('syslog.openlog', ' ', 'audit-tests.py 0 8')
  ('syslog.openlog', ' ', 'audit-tests.py 8 128')
  ('syslog.openlog', ' ', 'None 0 8')
  ('syslog.closelog', '', '')
ok
test_threading (test.test_audit.AuditTest.test_threading) ... ('test.test_func', ' ', '()')
FAIL
test_unraisablehook (test.test_audit.AuditTest.test_unraisablehook) ... FAIL
test_winapi_createnamedpipe (test.test_audit.AuditTest.test_winapi_createnamedpipe) ... skipped "The '_winapi' module is only available on Windows"
test_winreg (test.test_audit.AuditTest.test_winreg) ... skipped "No module named 'winreg'"
test_wmi_exec_query (test.test_audit.AuditTest.test_wmi_exec_query) ... skipped "No module named '_wmi'"

======================================================================
FAIL: test_cantrace (test.test_audit.AuditTest.test_cantrace)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 79, in test_cantrace
    self.do_test("test_cantrace")
         ^^^^^^^
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 34, in do_test
    self.fail("".join(p.stderr))
         ^^^^
AssertionError

======================================================================
FAIL: test_gc (test.test_audit.AuditTest.test_gc)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 134, in test_gc
    self.fail(stderr)
         ^^^^
AssertionError

======================================================================
FAIL: test_marshal (test.test_audit.AuditTest.test_marshal)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 65, in test_marshal
    self.do_test("test_marshal")
         ^^^^^^^
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 34, in do_test
    self.fail("".join(p.stderr))
         ^^^^
AssertionError

======================================================================
FAIL: test_monkeypatch (test.test_audit.AuditTest.test_monkeypatch)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 73, in test_monkeypatch
    self.do_test("test_monkeypatch")
         ^^^^^^^
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 34, in do_test
    self.fail("".join(p.stderr))
         ^^^^
AssertionError

======================================================================
FAIL: test_sys_monitoring_register_callback (test.test_audit.AuditTest.test_sys_monitoring_register_callback)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 265, in test_sys_monitoring_register_callback
    self.fail(stderr)
         ^^^^
AssertionError

======================================================================
FAIL: test_threading (test.test_audit.AuditTest.test_threading)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 217, in test_threading
    self.assertEqual(actual, expected)
         ^^^^^^^^^^^
AssertionError: Lists differ: [('test.test_func', '()')] != [('_thread.start_new_thread', '(<test_func>,[34 chars]()')]

First differing element 0:
('test.test_func', '()')
('_thread.start_new_thread', '(<test_func>, (), None)')

Second list contains 1 additional elements.
First extra element 1:
('test.test_func', '()')

+ [('_thread.start_new_thread', '(<test_func>, (), None)'),
- [('test.test_func', '()')]
? ^

+  ('test.test_func', '()')]
? ^


======================================================================
FAIL: test_unraisablehook (test.test_audit.AuditTest.test_unraisablehook)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/test_audit.py", line 96, in test_unraisablehook
    self.fail(stderr)
         ^^^^
AssertionError

----------------------------------------------------------------------
Ran 24 tests in 2.160s

FAILED (failures=7, skipped=3)
0:00:02 load avg: 1.00 [1/1/1] test_audit failed (7 failures)

== Tests result: FAILURE ==

1 test failed:
    test_audit

Total duration: 2.2 sec
Total tests: run=24 failures=7 skipped=3
Total test files: run=1/1 failed=1
Result: FAILURE
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 553, in <module>
    globals()[test](*sys.argv[2:])
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 270, in test_cantrace
    assertSequenceEqual(["call"] * 4, traced)
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 66, in assertSequenceEqual
    raise AssertionError(f"{x!r} should equal {y!r}")
AssertionError: ['call', 'call', 'call', 'call'] should equal []
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 553, in <module>
    globals()[test](*sys.argv[2:])
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 370, in test_gc
    gc.get_objects(generation=1)
       ^^^^^^^^^^^
NotImplementedError: get_objects(generation=None) accepts only None on PyPy
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 553, in <module>
    globals()[test](*sys.argv[2:])
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 127, in test_marshal
    assertSequenceEqual(actual, [(o, marshal.version)] * 2)
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 66, in assertSequenceEqual
    raise AssertionError(f"{x!r} should equal {y!r}")
AssertionError: [] should equal [(('a', 'b', 'c', 1, 2, 3), 4), (('a', 'b', 'c', 1, 2, 3), 4)]
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 553, in <module>
    globals()[test](*sys.argv[2:])
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 184, in test_monkeypatch
    assertSequenceEqual(
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 66, in assertSequenceEqual
    raise AssertionError(f"{x!r} should equal {y!r}")
AssertionError: [(<class '__main__.test_monkeypatch.<locals>.C'>, '__name__'), (<class '__main__.test_monkeypatch.<locals>.C'>, '__bases__'), (<class '__main__.test_monkeypatch.<locals>.C'>, '__bases__'), (<__main__.test_monkeypatch.<locals>.B object at 0x00007f23a7145e50>, '__class__')] should equal []
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 553, in <module>
    globals()[test](*sys.argv[2:])
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 533, in test_sys_monitoring_register_callback
    sys.monitoring.register_callback(1, 1, None)
        ^^^^^^^^^^
AttributeError: module 'sys' has no attribute 'monitoring'
Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib_pypy/_testcapi.py", line 17, in <module>
    module_from_spec(spec)
  File "<frozen importlib._bootstrap>", line 813, in module_from_spec
  File "<builtin>/frozen importlib._bootstrap_external", line 1293, in create_module
  File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
ImportError: /build_dir/pypy-c-jit-linux-x86-64/build/lib_pypy/_testcapi.pypy312-pp80-x86_64-linux-gnu.so: cannot open shared object file: No such file or directory

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 553, in <module>
    globals()[test](*sys.argv[2:])
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib-python/3/test/audit-tests.py", line 300, in test_unraisablehook
    from _testcapi import write_unraisable_exc
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib_pypy/_testcapi.py", line 25, in <module>
    mod = _pypy_testcapi.compile_shared(cfile, '_testcapi', thisdir)
                         ^^^^^^^^^^^^^^
  File "/build_dir/pypy-c-jit-linux-x86-64/build/lib_pypy/_pypy_testcapi.py", line 65, in compile_shared
    from distutils.ccompiler import new_compiler
ModuleNotFoundError: No module named 'distutils'
test test_audit failed
builder: pypy-c-jit-linux-x86-64 build #11857+
test: lib-python/3/test/test_audit.py::unmodified