diff --git a/crates/types/network/src/error_trace.rs b/crates/types/network/src/error_trace.rs index b75d127..c3c8238 100644 --- a/crates/types/network/src/error_trace.rs +++ b/crates/types/network/src/error_trace.rs @@ -20,9 +20,10 @@ //! //! SYNC: this is a manually-kept duplicate of the canonical module in //! `succinctlabs/network-services` (PR #1191). The two proto repos are not -//! auto-synced; `FailFulfillmentRequestBody.error_trace` is wire field 4 in -//! both. Keep this file and its network-services twin logically identical — -//! change them together. +//! auto-synced; `FailFulfillmentRequestBody.error_trace` is wire field 4 and +//! `ExecuteProofRequestBody.error_trace` is wire field 11 in both repos. Keep +//! this file and its network-services twin logically identical — change them +//! together. use serde::{Deserialize, Serialize}; diff --git a/crates/types/network/src/types.rs b/crates/types/network/src/types.rs index 37fe7d6..a84d84a 100644 --- a/crates/types/network/src/types.rs +++ b/crates/types/network/src/types.rs @@ -290,6 +290,12 @@ pub struct ExecuteProofRequestBody { /// The variant of the transaction. #[prost(enumeration = "TransactionVariant", tag = "10")] pub variant: i32, + /// Optional bounded, sanitized structured failure trace, set when execution + /// failed. Same contract as FailFulfillmentRequestBody.error_trace: the network + /// re-validates and stores it in `requests.error_trace`. See + /// `spn_network_types::error_trace`. + #[prost(bytes = "vec", optional, tag = "11")] + pub error_trace: ::core::option::Option<::prost::alloc::vec::Vec>, } #[derive(serde::Serialize, serde::Deserialize)] #[derive(Clone, PartialEq, ::prost::Message)] diff --git a/crates/vapp/tests/common/mod.rs b/crates/vapp/tests/common/mod.rs index 3573192..e767fcf 100644 --- a/crates/vapp/tests/common/mod.rs +++ b/crates/vapp/tests/common/mod.rs @@ -651,6 +651,7 @@ pub fn create_clear_tx_with_options( punishment: None, failure_cause: None, variant: TransactionVariant::ExecuteVariant as i32, + error_trace: None, }; // Create and sign execute. @@ -963,6 +964,7 @@ pub fn create_clear_tx_with_public_values_hash( punishment: None, failure_cause: None, variant: TransactionVariant::ExecuteVariant as i32, + error_trace: None, }; // Create and sign execute. @@ -1170,6 +1172,7 @@ pub fn create_clear_tx_with_version( punishment: None, failure_cause: None, variant: TransactionVariant::ExecuteVariant as i32, + error_trace: None, }; // Create and sign execute. diff --git a/proto/types.proto b/proto/types.proto index f2e2e82..b157630 100644 --- a/proto/types.proto +++ b/proto/types.proto @@ -235,6 +235,11 @@ message ExecuteProofRequestBody { optional ExecuteFailureCause failure_cause = 9; // The variant of the transaction. TransactionVariant variant = 10; + // Optional bounded, sanitized structured failure trace, set when execution + // failed. Same contract as FailFulfillmentRequestBody.error_trace: the network + // re-validates and stores it in `requests.error_trace`. See + // `spn_network_types::error_trace`. + optional bytes error_trace = 11; } message ExecuteProofResponse {