Skip to content

Commit 76d01c8

Browse files
committed
Fix fips test failures
1 parent 28f9c07 commit 76d01c8

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

relenv/runtime.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
import site
2222
import subprocess
2323
import sys
24-
import tempfile
2524
import textwrap
2625
import warnings
2726

@@ -826,6 +825,11 @@ def install_cargo_config():
826825
if sys.platform != "linux":
827826
return
828827

828+
# We need this as a late import for python < 3.12 becuase importing it will
829+
# load the ssl module. Causing out setup_openssl method to fail to load
830+
# fips module.
831+
import tempfile
832+
829833
install_cargo_config.tmpdir = tempfile.TemporaryDirectory(prefix="relenvcargo")
830834
cargo_home = pathlib.Path(install_cargo_config.tmpdir.name)
831835

0 commit comments

Comments
 (0)