Flaky test: tests/sentry/spans/consumers/process/test_consumer.py::test_schema_validator_rejects_none_fields[span_id]
- Dominant language
- Python
- Stars
- 44.8k
- Forks
- 4.9k
- Avg merge
- 21h 10m
- Merged PRs (30d)
- 635
Description
Failing test: `tests/sentry/spans/consumers/process/test_consumer.py::test_schema_validator_rejects_none_fields[span_id]`
Sentry sha: d9ad7639e47f7492cc115bef2a69b9f344529f4f
Run: https://github.com/getsentry/sentry/actions/runs/22299889218
```
[1m[31m.venv/lib/python3.13/site-packages/_pytest/runner.py[0m:340: in from_call
result: Optional[TResult] = func()
[1m[31m.venv/lib/python3.13/site-packages/_pytest/runner.py[0m:240: in
lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise
[1m[31m.venv/lib/python3.13/site-packages/pluggy/_hooks.py[0m:513: in __call__
return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult)
[1m[31m.venv/lib/python3.13/site-packages/pluggy/_manager.py[0m:120: in _hookexec
return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
[1m[31m.venv/lib/python3.13/site-packages/_pytest/threadexception.py[0m:87: in pytest_runtest_call
yield from thread_exception_runtest_hook()
[1m[31m.venv/lib/python3.13/site-packages/_pytest/threadexception.py[0m:63: in thread_exception_runtest_hook
yield
[1m[31m.venv/lib/python3.13/site-packages/_pytest/unraisableexception.py[0m:90: in pytest_runtest_call
yield from unraisable_exception_runtest_hook()
[1m[31m.venv/lib/python3.13/site-packages/_pytest/unraisableexception.py[0m:80: in unraisable_exception_runtest_hook
warnings.warn(pytest.PytestUnraisableExceptionWarning(msg))
[1m[31mE pytest.PytestUnraisableExceptionWarning: Exception ignored in: [0m
[1m[31mE [0m
[1m[31mE Traceback (most recent call last):[0m
[1m[31mE File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 195, in _send[0m
[1m[31mE self.ensure_running()[0m
[1m[31mE ~~~~~~~~~~~~~~~~~~~^^[0m
[1m[31mE File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 114, in ensure_running[0m
[1m[31mE return self._reentrant_call_error()[0m
[1m[31mE ~~~~~~~~~~~~~~~~~~~~~~~~~~^^[0m
[1m[31mE File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 75, in _reentrant_call_error[0m
[1m[31mE raise ReentrantCallError([0m
[1m[31mE "Reentrant call into the multiprocessing resource tracker")[0m
[1m[31mE multiprocessing.resource_tracker.ReentrantCallError: Reentrant call into the multiprocessing resource tracker[0m
[1m[31mE [0m
[1m[31mE During handling of the above exception, another exception occurred:[0m
[1m[31mE [0m
[1m[31mE Traceback (most recent call last):[0m
[1m[31mE File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/util.py", line 216, in __call__[0m
[1m[31mE res = self._callback(*self._args, **self._kwargs)[0m
[1m[31mE File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/synchronize.py", line 88, in _cleanup[0m
[1m[31mE unregister(name, "semaphore")[0m
[1m[31mE ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^[0m
[1m[31mE File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 191, in unregister[0m
[1m[31mE self._send('UNREGISTER', name, rtype)[0m
[1m[31mE ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^[0m
[1m[31mE File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 201, in _send[0m
[1m[31mE warnings.warn([0m
[1m[31mE ~~~~~~~~~~~~~^[0m
[1m[31mE f"ResourceTracker called reentrantly for resource cleanup, "[0m
[1m[31mE ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^[0m
[1m[31mE f"which is unsupported. "[0m
[1m[31mE ^^^^^^^^^^^^^^^^^^^^^^^^^[0m
[1m[31mE f"The {rtype} object {name!r} might leak.")[0m
[1m[31mE ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^[0m
[1m[31mE UserWarning: ResourceTracker called reentrantly for resource cleanup, which is unsupported. The semaphore object '/mp-56zm9rij' might leak.[0m
```
Contributor guide
Research direction
Start with tests/sentry/spans/consumers/process/test_consumer.py::test_schema_validator_rejects_none_fields[span_id] and reproduce the failure using the linked GitHub Actions run and Sentry SHA. Inspect the Python 3.13 multiprocessing resource_tracker warning and confirm the test completes reliably without the unraisable-exception warning.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100