getsentry / getsentry/sentry

Flaky test: tests/sentry/spans/consumers/process/test_consumer.py::test_schema_validator_rejects_none_fields[start_timestamp]

Open
#108,839 1 comment 0 reactions 0 assignees View on GitHub
flaky-test Tests
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[start_timestamp]`
Sentry sha: 94d9d60db8e0e6f4937593247f1d6d178df1bcaa
Run: https://github.com/getsentry/sentry/actions/runs/22267329565

```
.venv/lib/python3.13/site-packages/_pytest/runner.py:340: in from_call
result: Optional[TResult] = func()
.venv/lib/python3.13/site-packages/_pytest/runner.py:240: in
lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise
.venv/lib/python3.13/site-packages/pluggy/_hooks.py:513: in __call__
return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult)
.venv/lib/python3.13/site-packages/pluggy/_manager.py:120: in _hookexec
return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
.venv/lib/python3.13/site-packages/_pytest/threadexception.py:87: in pytest_runtest_call
yield from thread_exception_runtest_hook()
.venv/lib/python3.13/site-packages/_pytest/threadexception.py:63: in thread_exception_runtest_hook
yield
.venv/lib/python3.13/site-packages/_pytest/unraisableexception.py:90: in pytest_runtest_call
yield from unraisable_exception_runtest_hook()
.venv/lib/python3.13/site-packages/_pytest/unraisableexception.py:80: in unraisable_exception_runtest_hook
warnings.warn(pytest.PytestUnraisableExceptionWarning(msg))
E pytest.PytestUnraisableExceptionWarning: Exception ignored in: 
E 
E Traceback (most recent call last):
E File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 195, in _send
E self.ensure_running()
E ~~~~~~~~~~~~~~~~~~~^^
E File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 114, in ensure_running
E return self._reentrant_call_error()
E ~~~~~~~~~~~~~~~~~~~~~~~~~~^^
E File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 75, in _reentrant_call_error
E raise ReentrantCallError(
E "Reentrant call into the multiprocessing resource tracker")
E multiprocessing.resource_tracker.ReentrantCallError: Reentrant call into the multiprocessing resource tracker
E 
E During handling of the above exception, another exception occurred:
E 
E Traceback (most recent call last):
E File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/util.py", line 216, in __call__
E res = self._callback(*self._args, **self._kwargs)
E File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/synchronize.py", line 88, in _cleanup
E unregister(name, "semaphore")
E ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
E File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 191, in unregister
E self._send('UNREGISTER', name, rtype)
E ~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
E File "/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/multiprocessing/resource_tracker.py", line 201, in _send
E warnings.warn(
E ~~~~~~~~~~~~~^
E f"ResourceTracker called reentrantly for resource cleanup, "
E ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E f"which is unsupported. "
E ^^^^^^^^^^^^^^^^^^^^^^^^^
E f"The {rtype} object {name!r} might leak.")
E ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E UserWarning: ResourceTracker called reentrantly for resource cleanup, which is unsupported. The semaphore object '/mp-yd6_ru1u' might leak.
```

Contributor guide

Open the contributing guide

Research direction

Start with tests/sentry/spans/consumers/process/test_consumer.py::test_schema_validator_rejects_none_fields[start_timestamp] and reproduce the failure using the recorded Sentry SHA and Python 3.13 environment. Inspect the multiprocessing resource_tracker traceback and related test setup. Done means the test runs reliably without the reentrant cleanup warning or unraisable exception.

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
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.