From d5f2ea07e9afbe9be2711b46c44eb44498c08c00 Mon Sep 17 00:00:00 2001 From: Gabriel Barreto Date: Tue, 12 Nov 2024 09:53:03 -0300 Subject: [PATCH] fixed emission --- src/core/cli/repl.rs | 1 + src/lair/execute.rs | 8 ++++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/core/cli/repl.rs b/src/core/cli/repl.rs index 9cdec349..2671ca74 100644 --- a/src/core/cli/repl.rs +++ b/src/core/cli/repl.rs @@ -321,6 +321,7 @@ impl, C2: Chipset> Repl { bytes: Default::default(), emitted: Default::default(), debug_data: Default::default(), + provable: false, } } diff --git a/src/lair/execute.rs b/src/lair/execute.rs index e984cbd4..819ef996 100644 --- a/src/lair/execute.rs +++ b/src/lair/execute.rs @@ -82,6 +82,7 @@ pub struct QueryRecord { pub(crate) bytes: BytesRecord, pub(crate) emitted: Vec>, pub(crate) debug_data: DebugData, + pub(crate) provable: bool, } #[derive(Default, Clone, Debug, Eq, PartialEq)] @@ -287,6 +288,7 @@ impl QueryRecord { bytes: BytesRecord::default(), emitted: vec![], debug_data: DebugData::default(), + provable: true, } } @@ -463,8 +465,10 @@ impl, C2: Chipset> Toplevel { public_values.extend(depth.to_le_bytes().map(F::from_canonical_u8)); } queries.public_values = Some(public_values); - let map = queries.nonce_map(self); - queries.fix_nonces(&map); + if queries.provable { + let map = queries.nonce_map(self); + queries.fix_nonces(&map); + } Ok(out) }