Skip to content

Commit

Permalink
properly format the protos
Browse files Browse the repository at this point in the history
  • Loading branch information
jonfung-dydx committed Aug 2, 2024
1 parent b1cb4d0 commit c194c38
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 20 deletions.
10 changes: 6 additions & 4 deletions proto/dydxprotocol/clob/order.proto
Original file line number Diff line number Diff line change
Expand Up @@ -229,16 +229,18 @@ message TransactionOrdering {
uint32 transaction_index = 2;
}

// StreamLiquidationOrder represents an protocol-generated IOC liquidation order.
// Used in full node streaming.
// StreamLiquidationOrder represents an protocol-generated IOC liquidation
// order. Used in full node streaming.
message StreamLiquidationOrder {
// Information about this liquidation order.
PerpetualLiquidationInfo liquidation_info = 1;

// CLOB pair ID of the CLOB pair the liquidation order will be matched against.
// CLOB pair ID of the CLOB pair the liquidation order will be matched
// against.
uint32 clob_pair_id = 2;

// True if this is a buy order liquidating a short position, false if vice versa.
// True if this is a buy order liquidating a short position, false if vice
// versa.
bool is_buy = 3;

// The number of base quantums for this liquidation order.
Expand Down
13 changes: 7 additions & 6 deletions proto/dydxprotocol/clob/query.proto
Original file line number Diff line number Diff line change
Expand Up @@ -241,17 +241,18 @@ message StreamTakerOrder {
// after it is attempted to be matched on the orderbook.
// It is intended to be used only in full node streaming.
message StreamTakerOrderStatus {
// The state of the taker order after attempting to match it against the orderbook.
// Possible enum values can be found here:
// The state of the taker order after attempting to match it against the
// orderbook. Possible enum values can be found here:
// https://github.com/dydxprotocol/v4-chain/blob/main/protocol/x/clob/types/orderbook.go#L105
uint32 order_status = 1;

// The amount of remaining (non-matched) base quantums of this taker order.
uint64 remaining_quantums = 2;

// The amount of base quantums that were *optimistically* filled for this taker order
// when the order is matched against the orderbook. Note that if any quantums of this order
// were optimistically filled or filled in state before this invocation of the matching loop,
// this value will not include them.
// The amount of base quantums that were *optimistically* filled for this
// taker order when the order is matched against the orderbook. Note that if
// any quantums of this order were optimistically filled or filled in state
// before this invocation of the matching loop, this value will not include
// them.
uint64 optimistically_filled_quantums = 3;
}
10 changes: 6 additions & 4 deletions protocol/x/clob/types/order.pb.go

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

13 changes: 7 additions & 6 deletions protocol/x/clob/types/query.pb.go

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

0 comments on commit c194c38

Please sign in to comment.