From 1b90f8cc89af2c726790abbcf49b74052be0c7ae Mon Sep 17 00:00:00 2001 From: Itay Tsabary Date: Wed, 4 Dec 2024 15:21:19 +0200 Subject: [PATCH] chore(blockifier): move env var from run time to compile time commit-id:80a7265d --- crates/blockifier/src/test_utils/cairo_compile.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/blockifier/src/test_utils/cairo_compile.rs b/crates/blockifier/src/test_utils/cairo_compile.rs index 9d22166540..14c26b0636 100644 --- a/crates/blockifier/src/test_utils/cairo_compile.rs +++ b/crates/blockifier/src/test_utils/cairo_compile.rs @@ -83,7 +83,7 @@ pub fn cairo1_compiler_tag() -> String { /// overridden by the environment variable (otherwise, the default is used). fn local_cairo1_compiler_repo_path() -> PathBuf { // Location of blockifier's Cargo.toml. - let manifest_dir = env::var("CARGO_MANIFEST_DIR").unwrap(); + let manifest_dir = env!("CARGO_MANIFEST_DIR"); Path::new(&manifest_dir).join( env::var(CAIRO1_REPO_RELATIVE_PATH_OVERRIDE_ENV_VAR) @@ -217,7 +217,7 @@ fn verify_cairo0_compiler_deps() { } else { format!("installed version: {cairo_lang_version}") }, - env::var("CARGO_MANIFEST_DIR").unwrap(), + env!("CARGO_MANIFEST_DIR"), CAIRO0_PIP_REQUIREMENTS_FILE ); }