Skip to content

Commit

Permalink
revert "Cherry pick 18359 to 1.28.0 (#18386)"
Browse files Browse the repository at this point in the history
This reverts commit 1d48056.
  • Loading branch information
longbowlu committed Jun 24, 2024
1 parent 1d48056 commit ddc1d0c
Show file tree
Hide file tree
Showing 15 changed files with 20 additions and 946 deletions.
1 change: 0 additions & 1 deletion Cargo.lock

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

38 changes: 0 additions & 38 deletions crates/sui-framework/docs/bridge/committee.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ title: Module `0xb::committee`
- [Struct `BlocklistValidatorEvent`](#0xb_committee_BlocklistValidatorEvent)
- [Struct `BridgeCommittee`](#0xb_committee_BridgeCommittee)
- [Struct `CommitteeUpdateEvent`](#0xb_committee_CommitteeUpdateEvent)
- [Struct `CommitteeMemberUrlUpdateEvent`](#0xb_committee_CommitteeMemberUrlUpdateEvent)
- [Struct `CommitteeMember`](#0xb_committee_CommitteeMember)
- [Struct `CommitteeMemberRegistration`](#0xb_committee_CommitteeMemberRegistration)
- [Constants](#@Constants_0)
Expand Down Expand Up @@ -138,39 +137,6 @@ title: Module `0xb::committee`
</dl>


</details>

<a name="0xb_committee_CommitteeMemberUrlUpdateEvent"></a>

## Struct `CommitteeMemberUrlUpdateEvent`



<pre><code><b>struct</b> <a href="committee.md#0xb_committee_CommitteeMemberUrlUpdateEvent">CommitteeMemberUrlUpdateEvent</a> <b>has</b> <b>copy</b>, drop
</code></pre>



<details>
<summary>Fields</summary>


<dl>
<dt>
<code>member: <a href="../move-stdlib/vector.md#0x1_vector">vector</a>&lt;u8&gt;</code>
</dt>
<dd>

</dd>
<dt>
<code>new_url: <a href="../move-stdlib/vector.md#0x1_vector">vector</a>&lt;u8&gt;</code>
</dt>
<dd>

</dd>
</dl>


</details>

<a name="0xb_committee_CommitteeMember"></a>
Expand Down Expand Up @@ -697,10 +663,6 @@ title: Module `0xb::committee`
<b>let</b> (_, member) = self.members.get_entry_by_idx_mut(idx);
<b>if</b> (member.sui_address == ctx.sender()) {
member.http_rest_url = new_url;
emit (<a href="committee.md#0xb_committee_CommitteeMemberUrlUpdateEvent">CommitteeMemberUrlUpdateEvent</a> {
member: member.bridge_pubkey_bytes,
new_url
});
<b>return</b>
};
idx = idx + 1;
Expand Down
3 changes: 1 addition & 2 deletions crates/sui-framework/docs/bridge/message.md
Original file line number Diff line number Diff line change
Expand Up @@ -622,8 +622,7 @@ Emergency op payload is just a single byte


<pre><code><b>public</b> <b>fun</b> <a href="message.md#0xb_message_extract_blocklist_payload">extract_blocklist_payload</a>(<a href="message.md#0xb_message">message</a>: &<a href="message.md#0xb_message_BridgeMessage">BridgeMessage</a>): <a href="message.md#0xb_message_Blocklist">Blocklist</a> {
// blocklist payload should consist of one byte blocklist type, and list of 20 bytes evm addresses
// derived from ECDSA <b>public</b> keys
// blocklist payload should consist of one byte blocklist type, and list of 33 bytes ecdsa pub keys
<b>let</b> <b>mut</b> <a href="../move-stdlib/bcs.md#0x1_bcs">bcs</a> = bcs::new(<a href="message.md#0xb_message">message</a>.payload);
<b>let</b> blocklist_type = <a href="../move-stdlib/bcs.md#0x1_bcs">bcs</a>.peel_u8();
<b>let</b> <b>mut</b> address_count = <a href="../move-stdlib/bcs.md#0x1_bcs">bcs</a>.peel_u8();
Expand Down
9 changes: 0 additions & 9 deletions crates/sui-framework/packages/bridge/sources/committee.move
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,6 @@ module bridge::committee {
stake_participation_percentage: u64
}

public struct CommitteeMemberUrlUpdateEvent has copy, drop {
member: vector<u8>,
new_url: vector<u8>,
}

public struct CommitteeMember has copy, drop, store {
/// The Sui Address of the validator
sui_address: address,
Expand Down Expand Up @@ -279,10 +274,6 @@ module bridge::committee {
let (_, member) = self.members.get_entry_by_idx_mut(idx);
if (member.sui_address == ctx.sender()) {
member.http_rest_url = new_url;
emit (CommitteeMemberUrlUpdateEvent {
member: member.bridge_pubkey_bytes,
new_url
});
return
};
idx = idx + 1;
Expand Down
3 changes: 1 addition & 2 deletions crates/sui-framework/packages/bridge/sources/message.move
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,7 @@ module bridge::message {
}

public fun extract_blocklist_payload(message: &BridgeMessage): Blocklist {
// blocklist payload should consist of one byte blocklist type, and list of 20 bytes evm addresses
// derived from ECDSA public keys
// blocklist payload should consist of one byte blocklist type, and list of 33 bytes ecdsa pub keys
let mut bcs = bcs::new(message.payload);
let blocklist_type = bcs.peel_u8();
let mut address_count = bcs.peel_u8();
Expand Down
3 changes: 0 additions & 3 deletions crates/sui-framework/published_api.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3883,9 +3883,6 @@ BridgeCommittee
CommitteeUpdateEvent
public struct
0xb::committee
CommitteeMemberUrlUpdateEvent
public struct
0xb::committee
CommitteeMember
public struct
0xb::committee
Expand Down
2 changes: 1 addition & 1 deletion crates/sui-open-rpc/spec/openrpc.json
Original file line number Diff line number Diff line change
Expand Up @@ -1293,7 +1293,7 @@
"name": "Result",
"value": {
"minSupportedProtocolVersion": "1",
"maxSupportedProtocolVersion": "52",
"maxSupportedProtocolVersion": "51",
"protocolVersion": "6",
"featureFlags": {
"accept_zklogin_in_multisig": false,
Expand Down
4 changes: 1 addition & 3 deletions crates/sui-protocol-config/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ use tracing::{info, warn};

/// The minimum and maximum protocol versions supported by this build.
const MIN_PROTOCOL_VERSION: u64 = 1;
const MAX_PROTOCOL_VERSION: u64 = 52;
const MAX_PROTOCOL_VERSION: u64 = 51;

// Record history of protocol version allocations here:
//
Expand Down Expand Up @@ -147,7 +147,6 @@ const MAX_PROTOCOL_VERSION: u64 = 52;
// Prepose consensus commit prologue in checkpoints.
// Set number of leaders per round for Mysticeti commits.
// Version 51: Switch to DKG V1.
// Version 52: Emit `CommitteeMemberUrlUpdateEvent` when updating bridge node url.

#[derive(Copy, Clone, Debug, Hash, Serialize, Deserialize, PartialEq, Eq, PartialOrd, Ord)]
pub struct ProtocolVersion(u64);
Expand Down Expand Up @@ -2420,7 +2419,6 @@ impl ProtocolConfig {
51 => {
cfg.random_beacon_dkg_version = Some(1);
}
52 => {}
// Use this template when making changes:
//
// // modify an existing constant.
Expand Down
Loading

0 comments on commit ddc1d0c

Please sign in to comment.