-
Notifications
You must be signed in to change notification settings - Fork 25k
Add sets to list of safe objects to de-serialize #138866
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
To make sure that something like the following works ```python torch.save({1, 2, 3}, "foo.pt") torch.load("foo.pt", weights_only=True) ``` Fixes #138851
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/138866
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit 4841586 with merge base 889717a ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
Co-authored-by: mikaylagawarecki <mikaylagawarecki@gmail.com>
@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 |
@pytorchbot merge -f "Mac jobs are always queued" |
The merge job was canceled or timed out. This most often happen if two merge requests were issued for the same PR, or if merge job was waiting for more than 6 hours for tests to finish. In later case, please do not hesitate to reissue the merge command |
Merge startedYour change will be merged immediately since you used the force (-f) flag, bypassing any CI checks (ETA: 1-5 minutes). Please use Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
Lists, dicts and tuples are already allowed, it's a bit weird not to exclude set from the list of basic containers.
Test plan (in addition to unittest):
Fixes #138851