Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions packages/evolution/src/sdk/builders/TxBuilderImpl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -203,11 +203,11 @@ export const calculateReferenceScriptFee = (

yield* Effect.logDebug(`[RefScriptFee] Total reference script size: ${totalScriptSize} bytes`)

if (totalScriptSize > 200_000) {
// maxRefScriptSizePerTx from Conway ledger rules (CIP-0069 / CIP-0112)
if (totalScriptSize > 204_800) {
// maxRefScriptSizePerTx: 200 * 1024 = 204,800 bytes (200 KiB). Hardcoded in Conway era, becomes a protocol parameter in Dijkstra era.
return yield* Effect.fail(
new TransactionBuilderError({
message: `Total reference script size (${totalScriptSize} bytes) exceeds maximum limit of 200,000 bytes`
message: `Total reference script size (${totalScriptSize} bytes) exceeds maximum limit of 204,800 bytes`
})
)
}
Expand Down
Loading