Skip to content
Merged
Show file tree
Hide file tree
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
- [BREAKING] Renamed `--url` CLI flags and `*_URL` env vars to `--listen` / `*_LISTEN` across all components.
- [BREAKING] Removed `miden-node validator` subcommand and created a separate `miden-validator` binary ([#2053](https://github.com/0xMiden/node/pull/2053)).
- [BREAKING] Removed `miden-node ntx-builder` subcommand and created a separate `miden-ntx-builder` binary ([#2067](https://github.com/0xMiden/node/pull/2067)).
- [BREAKING] Reworked note proto types for multi-attachment support: `NoteMetadata` now carries `attachment_schemes` (repeated) and `attachments_commitment` instead of a single `attachment`. `Note` and `NetworkNote` gained an `attachments` field. `NoteSyncRecord` now embeds full `NoteMetadata` instead of `NoteMetadataHeader`. Removed `NoteAttachmentKind` enum and `NoteMetadataHeader` message ([#2078](https://github.com/0xMiden/node/pull/2078)).

## v0.14.10 (2026-05-29)

Expand Down
40 changes: 20 additions & 20 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 10 additions & 4 deletions bin/network-monitor/src/counter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ use miden_protocol::note::{
Note,
NoteAssets,
NoteAttachment,
NoteMetadata,
NoteAttachments,
NoteRecipient,
NoteScript,
NoteStorage,
NoteType,
PartialNoteMetadata,
};
use miden_protocol::transaction::{InputNotes, PartialBlockchain, TransactionArgs};
use miden_protocol::utils::serde::{Deserializable, Serializable};
Expand Down Expand Up @@ -946,9 +947,9 @@ fn create_network_note(
let target = NetworkAccountTarget::new(counter_account.id(), NoteExecutionHint::Always)
.context("Failed to create NetworkAccountTarget for counter account")?;
let attachment: NoteAttachment = target.into();
let attachments = NoteAttachments::from(attachment);

let metadata =
NoteMetadata::new(wallet_account.id(), NoteType::Public).with_attachment(attachment);
let partial_metadata = PartialNoteMetadata::new(wallet_account.id(), NoteType::Public);

let serial_num = Word::new([
Felt::new(rng.random()),
Expand All @@ -959,7 +960,12 @@ fn create_network_note(

let recipient = NoteRecipient::new(serial_num, script, NoteStorage::new(vec![])?);

let network_note = Note::new(NoteAssets::new(vec![])?, metadata, recipient.clone());
let network_note = Note::with_attachments(
NoteAssets::new(vec![])?,
partial_metadata,
recipient.clone(),
attachments,
);
Ok((network_note, recipient))
}

Expand Down
31 changes: 14 additions & 17 deletions bin/stress-test/src/seeding/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ use miden_protocol::account::{
StorageSlot,
StorageSlotName,
};
use miden_protocol::asset::{Asset, FungibleAsset, TokenSymbol};
use miden_protocol::asset::{Asset, AssetAmount, FungibleAsset, TokenSymbol};
use miden_protocol::batch::{BatchAccountUpdate, BatchId, ProvenBatch};
use miden_protocol::block::{
BlockHeader,
Expand Down Expand Up @@ -58,8 +58,7 @@ use miden_protocol::utils::serde::Serializable;
use miden_protocol::vm::ExecutionProof;
use miden_protocol::{Felt, ONE, Word};
use miden_standards::account::auth::AuthSingleSig;
use miden_standards::account::faucets::{BasicFungibleFaucet, TokenMetadata};
use miden_standards::account::metadata::{FungibleTokenMetadata, TokenName};
use miden_standards::account::faucets::{FungibleFaucet, TokenName};
use miden_standards::account::policies::{
BurnPolicyConfig,
MintPolicyConfig,
Expand Down Expand Up @@ -455,7 +454,7 @@ fn create_note(faucet_ids: &[AccountId], target_id: AccountId, rng: &mut RandomC
target_id,
assets,
miden_protocol::note::NoteType::Public,
miden_protocol::note::NoteAttachment::default(),
miden_protocol::note::NoteAttachments::empty(),
rng,
)
.expect("note creation failed")
Expand Down Expand Up @@ -579,20 +578,18 @@ fn create_faucet_with_seed(index: u64) -> Account {
let init_seed: Vec<_> = index.to_be_bytes().into_iter().chain([0u8; 24]).collect();

let token_symbol = TokenSymbol::new("TEST").unwrap();
let token_metadata = FungibleTokenMetadata::builder(
TokenName::new("TEST").unwrap(),
token_symbol,
2,
FungibleAsset::MAX_AMOUNT,
)
.build()
.unwrap();
let faucet = FungibleFaucet::builder()
.name(TokenName::new("TEST").unwrap())
.symbol(token_symbol)
.decimals(2)
.max_supply(AssetAmount::new(FungibleAsset::MAX_AMOUNT).unwrap())
.build()
.unwrap();

AccountBuilder::new(init_seed.try_into().unwrap())
.account_type(AccountType::FungibleFaucet)
.storage_mode(AccountStorageMode::Private)
.with_component(token_metadata)
.with_component(BasicFungibleFaucet)
.with_component(faucet)
.with_components(TokenPolicyManager::new(
PolicyAuthority::AuthControlled,
MintPolicyConfig::AllowAll,
Expand Down Expand Up @@ -756,11 +753,11 @@ fn create_emit_note_tx(
) -> ProvenTransaction {
let initial_account_hash = faucet.to_commitment();

let metadata_slot_name = TokenMetadata::metadata_slot();
let slot = faucet.storage().get_item(metadata_slot_name).unwrap();
let token_config_slot = FungibleFaucet::token_config_slot();
let slot = faucet.storage().get_item(token_config_slot).unwrap();
faucet
.storage_mut()
.set_item(metadata_slot_name, [slot[0] + Felt::new(10), slot[1], slot[2], slot[3]].into())
.set_item(token_config_slot, [slot[0] + Felt::new(10), slot[1], slot[2], slot[3]].into())
.unwrap();

faucet.increment_nonce(ONE).unwrap();
Expand Down
4 changes: 2 additions & 2 deletions crates/block-producer/src/test_utils/account.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,14 @@ impl<const NUM_STATES: usize> MockPrivateAccount<NUM_STATES> {
init_seed,
AccountType::RegularAccountUpdatableCode,
AccountStorageMode::Private,
AccountIdVersion::Version0,
AccountIdVersion::Version1,
Word::empty(),
Word::empty(),
)
.unwrap();

Self::new(
AccountId::new(account_seed, AccountIdVersion::Version0, Word::empty(), Word::empty())
AccountId::new(account_seed, AccountIdVersion::Version1, Word::empty(), Word::empty())
.unwrap(),
if new_account {
Word::empty()
Expand Down
8 changes: 5 additions & 3 deletions crates/block-producer/src/test_utils/proven_tx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ use miden_protocol::account::AccountId;
use miden_protocol::account::delta::AccountUpdateDetails;
use miden_protocol::asset::FungibleAsset;
use miden_protocol::block::BlockNumber;
use miden_protocol::note::{Note, Nullifier};
use miden_protocol::note::{Note, NoteAttachments, Nullifier};
use miden_protocol::transaction::{
InputNote,
InputNoteCommitment,
OutputNote,
PrivateNoteHeader,
PrivateOutputNote,
ProvenTransaction,
TxAccountUpdate,
};
Expand Down Expand Up @@ -134,7 +134,9 @@ impl MockProvenTxBuilder {
.map(|note_index| {
let note = Note::mock_noop(Word::from([0, 0, 0, note_index]));

OutputNote::Private(PrivateNoteHeader::new(note.header().clone()).unwrap())
OutputNote::Private(
PrivateOutputNote::new(*note.header(), NoteAttachments::empty()).unwrap(),
)
})
.collect();

Expand Down
Loading
Loading