KeyError: frame = sys._current_frames()[thread_id]
Issue #24
new
KeyError at dogslow/__init__.py in peek, line 226
Python Version: 2.7.15
gunicorn version 19.9.0
Django version 1.11.29
dogslow==1.2
Comments (2)
-
reporter -
I think it’s possible to hit a race condition, where the thread handling the request finishes only just after the Dogslow timer triggers. That would cause this error.
- Log in to comment
A tad more info; I traced some variables. In one case, dogslow is looking for thread_id
139760463324008
but these are the available thread IDs fromsys._current_frames()
[139760441603840, 139760449996544, 139760657008448]