Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 107edd7

Browse files
claudevdmClaude
andauthored
Copy sys.module.items() in case it changes during iteration. (#34592)
Co-authored-by: Claude <[email protected]>
1 parent feb0dfe commit 107edd7

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

sdks/python/apache_beam/internal/cloudpickle_pickler.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ def _get_proto_enum_descriptor_class():
8282

8383

8484
def _reconstruct_enum_descriptor(full_name):
85-
for _, module in sys.modules.items():
85+
for _, module in list(sys.modules.items()):
8686
if not hasattr(module, 'DESCRIPTOR'):
8787
continue
8888

0 commit comments

Comments
 (0)