gh-88750: Remove the PYTHONTHREADDEBUG env var support.#92509
gh-88750: Remove the PYTHONTHREADDEBUG env var support.#92509gpshead merged 2 commits intopython:mainfrom
Conversation
|
I left the empty |
vstinner
left a comment
There was a problem hiding this comment.
LGTM.
My remark about PyThread_release_lock() is unrelated to your PR.
|
|
||
| if (!(aLock && LeaveNonRecursiveMutex((PNRMUTEX) aLock))) | ||
| dprintf(("%lu: Could not PyThread_release_lock(%p) error: %ld\n", PyThread_get_thread_ident(), aLock, GetLastError())); | ||
| if (aLock) { |
There was a problem hiding this comment.
Wait, we have a special case to do nothing if the lock is not initialized? Only for the Windows implementation and only for PyThread_release_lock()? That's weird. I suggest to replace the if() with an assert(), but done in a separated PR. (I can do it if I don't forget.)
It's weird because the pthread implement has no special case for PyThread_release_lock() and so the code is not portable. Or maybe I misunderstood something.
There was a problem hiding this comment.
I'd be surprised to ever see this called with aLock == NULL, I just figured I should preserve the exact semantics when removing the debug print. Agreed on the assert, but that does make more sense in a followup PR.
No description provided.