Skip to content

feat: add managed vault protobuf definitions#56

Merged
johnletey merged 28 commits intonoble-assets:managed-vaultfrom
iqlusioninc:zaki/managed-vault-protos
Sep 25, 2025
Merged

feat: add managed vault protobuf definitions#56
johnletey merged 28 commits intonoble-assets:managed-vaultfrom
iqlusioninc:zaki/managed-vault-protos

Conversation

@zmanian
Copy link
Copy Markdown

@zmanian zmanian commented Sep 8, 2025

This PR adds the v2 proto definitions for managed vaults functionality.

Changes

  • Added cross-chain support proto definitions
  • Added event definitions for vault operations
  • Added fee structure definitions
  • Added genesis state definitions
  • Added NAV (Net Asset Value) calculations
  • Added oracle integration definitions
  • Added query service definitions
  • Added transaction message definitions
  • Added core vault type definitions

All proto files have been formatted using buf.

zmanian and others added 21 commits August 12, 2025 16:11
Clarify that there is only 1 vault and multiple remote positions
Co-authored-by: Justin Tieri <37750742+jtieri@users.noreply.github.com>
…ation-for-emergency-mode

docs: describe emergency mode in vaults v2 overview
Co-authored-by: John Letey <j@letey.de>
Co-authored-by: John Letey <j@letey.de>
Co-authored-by: John Letey <j@letey.de>
Co-authored-by: John Letey <j@letey.de>
Co-authored-by: John Letey <j@letey.de>
Co-authored-by: John Letey <j@letey.de>
Co-authored-by: John Letey <j@letey.de>
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Sep 8, 2025

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

✨ Finishing touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Member

@g-luca g-luca left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some initial feedback 😄

Comment thread proto/noble/dollar/vaults/v2/query.proto
Comment thread proto/noble/dollar/vaults/v2/cross_chain.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/cross_chain.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/cross_chain.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/oracle.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/genesis.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/genesis.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/genesis.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/genesis.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/fees.proto Outdated
Copy link
Copy Markdown

@cbrit cbrit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some items pertaining to the vaults, tx, and query protos. Mostly to do with inconsistencies against the spec, but also some questions.

Comment thread proto/noble/dollar/vaults/v2/vaults.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/vaults.proto Outdated
Comment thread proto/noble/dollar/vaults/v2/tx.proto
Comment thread proto/noble/dollar/vaults/v2/tx.proto
rpc ProcessWithdrawalQueue(MsgProcessWithdrawalQueue) returns (MsgProcessWithdrawalQueueResponse);

// Update vault configuration (authority only)
rpc UpdateVaultConfig(MsgUpdateVaultConfig) returns (MsgUpdateVaultConfigResponse);
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Messages not in the spec

string total_value = 3; // deposit + yield
string unrealized_gain = 4;
string locked_amount = 5; // amount in withdrawal queue
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Different field names than the UserShares in the queries spec

string yield_rate = 2; // current APY
CheckResultsView checks = 3;
repeated string warnings = 4;
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

QuerySimulateDepositResponse has some different field names than in the spec

string principal_portion = 2;
string yield_portion = 3;
uint64 queue_position = 4;
string estimated_fulfillment_time = 5; // seconds
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are also some differences in the field names compared to the spec here

Comment thread proto/noble/dollar/vaults/v2/query.proto
option go_package = "dollar.noble.xyz/v2/types/vaults/v2";

// Query defines the gRPC querier service for V2 vaults
service Query {
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing a VaultStats handler mentioned in the spec

@johnletey johnletey changed the title Add managed vault v2 proto definitions feat: add managed vault protobuf definitions Sep 25, 2025
@johnletey johnletey merged commit 813e9b3 into noble-assets:managed-vault Sep 25, 2025
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants