gh-130091: Reorder _PyThreadState_Attach to avoid data race
#130092
Merged
_PyThreadState_Attach to avoid data race
#130092