From 883034d4851db9d58a91d54953aeb62c60890243 Mon Sep 17 00:00:00 2001 From: Dustin Brickwood Date: Fri, 1 Nov 2024 15:03:51 -0500 Subject: [PATCH] fix: sanitize input based on solc version (#690) --- crates/verify/src/zksync/standard_json.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/crates/verify/src/zksync/standard_json.rs b/crates/verify/src/zksync/standard_json.rs index 41fd57118..ad5f7575f 100644 --- a/crates/verify/src/zksync/standard_json.rs +++ b/crates/verify/src/zksync/standard_json.rs @@ -11,12 +11,15 @@ impl ZksyncSourceProvider for ZksyncStandardJsonSource { &self, context: &ZkVerificationContext, ) -> Result<(StandardJsonCompilerInput, String)> { - let input = foundry_compilers::zksync::project_standard_json_input( + let mut input = foundry_compilers::zksync::project_standard_json_input( &context.project, &context.target_path, ) .wrap_err("failed to get zksolc standard json")?; + // Sanitize the input + input.settings = input.settings.clone().sanitized(&context.compiler_version.solc); + let relative_path = context .target_path .strip_prefix(context.project.root())