From d6038ae80a151b30afa52f05fef6bdee106bcff7 Mon Sep 17 00:00:00 2001 From: Alex Mazzeo Date: Fri, 19 Dec 2025 09:22:08 -0800 Subject: [PATCH] Remove stdlib_module_names test that is no longer relevant --- .../workflow_sandbox/test_restrictions.py | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/tests/worker/workflow_sandbox/test_restrictions.py b/tests/worker/workflow_sandbox/test_restrictions.py index 27310c1ed..3bea4c51c 100644 --- a/tests/worker/workflow_sandbox/test_restrictions.py +++ b/tests/worker/workflow_sandbox/test_restrictions.py @@ -16,25 +16,6 @@ ) -def test_workflow_sandbox_stdlib_module_names(): - if sys.version_info[1] != 11: - pytest.skip("Test only runs on 3.11") - actual_names = ",".join(sorted(sys.stdlib_module_names)) - # Uncomment to print code for generating these - code_lines = [""] - for mod_name in sorted(sys.stdlib_module_names): - if code_lines[-1]: - code_lines[-1] += "," - if len(code_lines[-1]) > 80: - code_lines.append("") - code_lines[-1] += mod_name - code = '_stdlib_module_names = (\n "' + '"\n "'.join(code_lines) + '"\n)' - # TODO(cretz): Point releases may add modules :-( - assert actual_names == ",".join( - sys.stdlib_module_names - ), f"Expecting names as {actual_names}. In code as:\n{code}" - - def test_workflow_sandbox_restrictions_add_passthrough_modules(): updated = SandboxRestrictions.default.with_passthrough_modules("module1", "module2") assert (