@solana/transaction-messages 2.4.0-canary-20250709085047 → 2.4.0-canary-20250709085504

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -585,17 +585,22 @@ function getCompiledStaticAccounts(orderedAccounts) {
585
585
  }
586
586
 
587
587
  // src/compile/message.ts
588
+ var EMPTY_BLOCKHASH_LIFETIME_CONSTRAINT = {
589
+ blockhash: "11111111111111111111111111111111",
590
+ lastValidBlockHeight: 0n
591
+ };
588
592
  function compileTransactionMessage(transactionMessage) {
589
593
  const addressMap = getAddressMapFromInstructions(
590
594
  transactionMessage.feePayer.address,
591
595
  transactionMessage.instructions
592
596
  );
593
597
  const orderedAccounts = getOrderedAccountsFromAddressMap(addressMap);
598
+ const lifetimeConstraint = transactionMessage.lifetimeConstraint ?? EMPTY_BLOCKHASH_LIFETIME_CONSTRAINT;
594
599
  return {
595
600
  ...transactionMessage.version !== "legacy" ? { addressTableLookups: getCompiledAddressTableLookups(orderedAccounts) } : null,
596
601
  header: getCompiledMessageHeader(orderedAccounts),
597
602
  instructions: getCompiledInstructions(transactionMessage.instructions, orderedAccounts),
598
- lifetimeToken: getCompiledLifetimeToken(transactionMessage.lifetimeConstraint),
603
+ lifetimeToken: getCompiledLifetimeToken(lifetimeConstraint),
599
604
  staticAccounts: getCompiledStaticAccounts(orderedAccounts),
600
605
  version: transactionMessage.version
601
606
  };