fix(dao): wire V2 cost model into proposal_create staging
Without staging.language_view(), pallas does not compute script_data_hash. Chain rejects the tx with PPViewHashesDontMatch. Same trap that plutus_mint hit on 2026-05-07 — same fix here. Caught attempting first dao_proposal_create_unsigned on preprod_test DAO 2026-05-07 PM after deploying governor + proposal validator ref UTxOs via the new file-path workaround for the MCP large-string bug.
This commit is contained in:
parent
2d4c2163a9
commit
044ebd2379
1 changed files with 12 additions and 1 deletions
|
|
@ -43,7 +43,7 @@ use pallas_codec::minicbor;
|
|||
use pallas_codec::utils::KeyValuePairs;
|
||||
use pallas_crypto::hash::Hash;
|
||||
use pallas_primitives::PlutusData;
|
||||
use pallas_txbuilder::{BuildConway, ExUnits, Input, Output, StagingTransaction};
|
||||
use pallas_txbuilder::{BuildConway, ExUnits, Input, Output, ScriptKind, StagingTransaction};
|
||||
|
||||
use crate::agora::governor::GovernorDatum;
|
||||
use crate::agora::proposal::{
|
||||
|
|
@ -589,6 +589,17 @@ pub fn build_unsigned_proposal_create(
|
|||
|
||||
staging = staging.fee(args.fee_lovelace).network_id(network_id);
|
||||
|
||||
// Wire the V2 cost model so pallas computes script_data_hash. Without
|
||||
// this the chain rejects with PPViewHashesDontMatch — same trap the
|
||||
// plutus_mint path tripped over on 2026-05-07. All Agora validators
|
||||
// we witness here (governor, stake, proposalSt policy) are PlutusV2
|
||||
// on the current preprod linker output, so a single language_view
|
||||
// entry covers all three.
|
||||
staging = staging.language_view(
|
||||
ScriptKind::PlutusV2,
|
||||
aldabra_core::plutus_cost_models::PLUTUS_V2_COST_MODEL_PREPROD.to_vec(),
|
||||
);
|
||||
|
||||
let built = staging
|
||||
.build_conway_raw()
|
||||
.map_err(|e| DaoError::Backend(format!("build_conway_raw: {e}")))?;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue