mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Revert "[dynamo] allow global import from collections import deque
in user code (#148676)"
This reverts commit 685fb377131cc684633dc5471e77038988db53f6.
Reverted https://github.com/pytorch/pytorch/pull/148676 on behalf of https://github.com/malfet due to Looks like it broke ROCM, see f1444f006c/1
(default%2C%201&mergeLF=true ([comment](https://github.com/pytorch/pytorch/pull/148676#issuecomment-2709057326))
This commit is contained in:
@ -563,6 +563,7 @@ class DequeVariable(CommonListMethodsVariable):
|
||||
)
|
||||
|
||||
def reconstruct(self, codegen: "PyCodegen") -> None:
|
||||
assert "deque" not in codegen.tx.f_globals
|
||||
codegen.add_push_null(
|
||||
lambda: codegen.append_output(
|
||||
codegen.create_load_python_module(collections.deque)
|
||||
|
Reference in New Issue
Block a user