Repository navigation
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/190543
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit d4571d2 with merge base 63d4ffc ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
…dlock FileBaton.try_acquire() creates a lock file and only removes it in a finally, so a builder killed by SIGKILL/OOM/Slurm leaves the file behind and every later load() spins forever in FileBaton.wait(). Replace it with a blocking torch.utils._filelock.FileLock (an OS-level flock), which the kernel releases when the holder dies. The build now runs inside the lock with the version re-check, so a crashed build is retried instead of leaving waiters to load a partial module. FileBaton is kept for BC. Fixes #189245 Test Plan: python test/test_cpp_extensions_jit.py -k stale_lock Co-Authored-By: Claude Opus 4.8 <[email protected]> ghstack-source-id: 14cb2ba Pull-Request: #190543
|
@pytorchbot merge |
Merge failedReason: This PR needs a If not, please add the To add a label, you can comment to pytorchbot, for example For more information, see Details for Dev Infra teamRaised by workflow job |
|
@pytorchbot merge |
Merge startedYour change will be merged once all checks pass (ETA 0-4 Hours). Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
…dlock (pytorch#190543) FileBaton.try_acquire() creates a lock file and only removes it in a finally, so a builder killed by SIGKILL/OOM/Slurm leaves the file behind and every later load() spins forever in FileBaton.wait(). Replace it with a blocking torch.utils._filelock.FileLock (an OS-level flock), which the kernel releases when the holder dies. The build now runs inside the lock with the version re-check, so a crashed build is retried instead of leaving waiters to load a partial module. FileBaton is kept for BC. Fixes pytorch#189245 Test Plan: python test/test_cpp_extensions_jit.py -k stale_lock Co-Authored-By: Claude Opus 4.8 <[email protected]> Pull Request resolved: pytorch#190543 Approved by: https://github.com/ezyang, https://github.com/Skylion007
…dlock (pytorch#190543) FileBaton.try_acquire() creates a lock file and only removes it in a finally, so a builder killed by SIGKILL/OOM/Slurm leaves the file behind and every later load() spins forever in FileBaton.wait(). Replace it with a blocking torch.utils._filelock.FileLock (an OS-level flock), which the kernel releases when the holder dies. The build now runs inside the lock with the version re-check, so a crashed build is retried instead of leaving waiters to load a partial module. FileBaton is kept for BC. Fixes pytorch#189245 Test Plan: python test/test_cpp_extensions_jit.py -k stale_lock Co-Authored-By: Claude Opus 4.8 <[email protected]> Pull Request resolved: pytorch#190543 Approved by: https://github.com/ezyang, https://github.com/Skylion007
…dlock (pytorch#190543) FileBaton.try_acquire() creates a lock file and only removes it in a finally, so a builder killed by SIGKILL/OOM/Slurm leaves the file behind and every later load() spins forever in FileBaton.wait(). Replace it with a blocking torch.utils._filelock.FileLock (an OS-level flock), which the kernel releases when the holder dies. The build now runs inside the lock with the version re-check, so a crashed build is retried instead of leaving waiters to load a partial module. FileBaton is kept for BC. Fixes pytorch#189245 Test Plan: python test/test_cpp_extensions_jit.py -k stale_lock Co-Authored-By: Claude Opus 4.8 <[email protected]> Pull Request resolved: pytorch#190543 Approved by: https://github.com/ezyang, https://github.com/Skylion007
…dlock (pytorch#190543) FileBaton.try_acquire() creates a lock file and only removes it in a finally, so a builder killed by SIGKILL/OOM/Slurm leaves the file behind and every later load() spins forever in FileBaton.wait(). Replace it with a blocking torch.utils._filelock.FileLock (an OS-level flock), which the kernel releases when the holder dies. The build now runs inside the lock with the version re-check, so a crashed build is retried instead of leaving waiters to load a partial module. FileBaton is kept for BC. Fixes pytorch#189245 Test Plan: python test/test_cpp_extensions_jit.py -k stale_lock Co-Authored-By: Claude Opus 4.8 <[email protected]> Pull Request resolved: pytorch#190543 Approved by: https://github.com/ezyang, https://github.com/Skylion007
…dlock (pytorch#190543) FileBaton.try_acquire() creates a lock file and only removes it in a finally, so a builder killed by SIGKILL/OOM/Slurm leaves the file behind and every later load() spins forever in FileBaton.wait(). Replace it with a blocking torch.utils._filelock.FileLock (an OS-level flock), which the kernel releases when the holder dies. The build now runs inside the lock with the version re-check, so a crashed build is retried instead of leaving waiters to load a partial module. FileBaton is kept for BC. Fixes pytorch#189245 Test Plan: python test/test_cpp_extensions_jit.py -k stale_lock Co-Authored-By: Claude Opus 4.8 <[email protected]> Pull Request resolved: pytorch#190543 Approved by: https://github.com/ezyang, https://github.com/Skylion007
Stack from ghstack (oldest at bottom):
FileBaton.try_acquire() creates a lock file and only removes it in a
finally, so a builder killed by SIGKILL/OOM/Slurm leaves the file behind
and every later load() spins forever in FileBaton.wait(). Replace it with
a blocking torch.utils._filelock.FileLock (an OS-level flock), which the
kernel releases when the holder dies. The build now runs inside the lock
with the version re-check, so a crashed build is retried instead of
leaving waiters to load a partial module. FileBaton is kept for BC.
Fixes #189245
Test Plan:
python test/test_cpp_extensions_jit.py -k stale_lock
Co-Authored-By: Claude Opus 4.8 [email protected]
cc @janeyx99