Skip to content
Merged
Show file tree
Hide file tree
Changes from 31 commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
0705d14
feat(iota-protocol-config): bump version to 4
miker83z Feb 3, 2025
6886b6d
feat(docs/random): update docs realted to randomness (#5388)
Dkwcs Feb 13, 2025
8ac75d6
feat(iota-framework/move-stdlib): Deprecated `fixed_point32` (#5193)
Dkwcs Feb 14, 2025
b5fdf89
fix(iota-framework/packages): optimizes some calls to `is_empty` in l…
Dkwcs Feb 14, 2025
06e3774
updating manifest
Dkwcs Feb 14, 2025
c22a9eb
Merge remote-tracking branch 'origin/vm-lang/upstream-nov-dic-24' int…
Dkwcs Feb 14, 2025
04b2e13
updating manifest
Dkwcs Feb 14, 2025
8272137
Merge branch 'develop' into vm-lang/upstream-nov-dic-24
miker83z Feb 14, 2025
4a851b7
feat(iota-protocol-config): bump version to 5
miker83z Feb 14, 2025
655f062
update framework snapshot
miker83z Feb 14, 2025
1fa0ab1
Update docs
Dkwcs Feb 14, 2025
cae7c65
Merge remote-tracking branch 'origin/vm-lang/upstream-nov-dic-24' int…
Dkwcs Feb 14, 2025
c84dfe8
manifest
Dkwcs Feb 14, 2025
7555360
tests update
Dkwcs Feb 15, 2025
c56bcff
test fix
Dkwcs Feb 15, 2025
2e24f9f
update snapshots
Dkwcs Feb 15, 2025
795636c
snapshot update
Dkwcs Feb 15, 2025
29998cc
snapshot update
Dkwcs Feb 15, 2025
176882a
Update simtest
Dkwcs Feb 16, 2025
191525f
remove snapshots
Dkwcs Feb 16, 2025
11ab407
check simtests
Dkwcs Feb 16, 2025
286680a
simtest fix
Dkwcs Feb 16, 2025
9429298
Fix review commnets
Dkwcs Feb 17, 2025
addbeac
revert external crates changes
Dkwcs Feb 17, 2025
9e5b44e
docs fix
Dkwcs Feb 17, 2025
95dee15
Merge remote-tracking branch 'origin/vm-lang/upstream-nov-dic-24' int…
Dkwcs Feb 18, 2025
9cfaa61
manifest
Dkwcs Feb 18, 2025
d1eb498
fix
Dkwcs Feb 18, 2025
7cbf8e1
fix simtest
Dkwcs Feb 18, 2025
5f477ed
revert snapshot changes
Dkwcs Feb 18, 2025
06951db
Merge remote-tracking branch 'origin/vm-lang/upstream-nov-dic-24' int…
Dkwcs Feb 18, 2025
7f98c02
Merge branch 'vm-lang/upstream-nov-dic-24' into vm-lang/Update-some-c…
miker83z Feb 19, 2025
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
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ task 1, lines 10-23:
//# publish
created: object(1,0)
mutated: object(0,2)
gas summary: computation_cost: 1000000, computation_cost_burned: 1000000, storage_cost: 5684800, storage_rebate: 0, non_refundable_storage_fee: 0
gas summary: computation_cost: 1000000, computation_cost_burned: 1000000, storage_cost: 5570800, storage_rebate: 0, non_refundable_storage_fee: 0

task 2, lines 25-29:
//# programmable --sender A --inputs 100000 @A
Expand Down
3 changes: 1 addition & 2 deletions crates/iota-benchmark/tests/simtest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -659,8 +659,7 @@ mod test {
}

async fn test_protocol_upgrade_compatibility_impl() {
// TODO: Remove the `+ 1` after we have Protocol version 2
let max_ver = ProtocolVersion::MAX.as_u64() + 1;
let max_ver = ProtocolVersion::MAX.as_u64();
let manifest = iota_framework_snapshot::load_bytecode_snapshot_manifest();

let Some((&starting_version, _)) = manifest.range(..max_ver).last() else {
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
2 changes: 1 addition & 1 deletion crates/iota-framework-snapshot/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
]
},
"5": {
"git_revision": "f2d8de9503f1",
"git_revision": "95dee15d0473",
"package_ids": [
"0x0000000000000000000000000000000000000000000000000000000000000001",
"0x0000000000000000000000000000000000000000000000000000000000000002",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ module iota::vec_map {

/// Pop the most recently inserted entry from the map. Aborts if the map is empty.
public fun pop<K: copy, V>(self: &mut VecMap<K,V>): (K, V) {
assert!(!self.contents.is_empty(), EMapEmpty);
assert!(self.contents.length() != 0, EMapEmpty);
let Entry { key, value } = self.contents.pop_back();
(key, value)
}
Expand Down Expand Up @@ -148,7 +148,7 @@ module iota::vec_map {
keys.reverse();
values.reverse();
let mut map = empty();
while (!keys.is_empty()) map.insert(keys.pop_back(), values.pop_back());
while (keys.length() != 0) map.insert(keys.pop_back(), values.pop_back());
keys.destroy_empty();
values.destroy_empty();
map
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ module iota::vec_set {
public fun from_keys<K: copy + drop>(mut keys: vector<K>): VecSet<K> {
keys.reverse();
let mut set = empty();
while (!keys.is_empty()) set.insert(keys.pop_back());
while (keys.length() != 0) set.insert(keys.pop_back());
set
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ module iota_system::voting_power {

/// Update validators with the decided voting power.
fun update_voting_power(validators: &mut vector<ValidatorV1>, mut info_list: vector<VotingPowerInfoV1>) {
while (!info_list.is_empty()) {
while (info_list.length() != 0) {
let VotingPowerInfoV1 {
validator_index,
voting_power,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ module std::vector {
/// Pushes all of the elements of the `other` vector into the `lhs` vector.
public fun append<Element>(lhs: &mut vector<Element>, mut other: vector<Element>) {
other.reverse();
while (!other.is_empty()) lhs.push_back(other.pop_back());
while (other.length() != 0) lhs.push_back(other.pop_back());
other.destroy_empty();
}

Expand Down Expand Up @@ -153,7 +153,7 @@ module std::vector {
/// This is O(1), but does not preserve ordering of elements in the vector.
/// Aborts if `i` is out of bounds.
public fun swap_remove<Element>(v: &mut vector<Element>, i: u64): Element {
assert!(!v.is_empty(), EINDEX_OUT_OF_BOUNDS);
assert!(v.length() != 0, EINDEX_OUT_OF_BOUNDS);
let last_idx = v.length() - 1;
v.swap(i, last_idx);
v.pop_back()
Expand All @@ -173,7 +173,7 @@ module std::vector {
/// Does not preserve the order of elements in the vector (starts from the end of the vector).
public macro fun destroy<$T>($v: vector<$T>, $f: |$T|) {
let mut v = $v;
while (!v.is_empty()) $f(v.pop_back());
while (v.length() != 0) $f(v.pop_back());
v.destroy_empty();
}

Expand All @@ -182,7 +182,7 @@ module std::vector {
public macro fun do<$T>($v: vector<$T>, $f: |$T|) {
let mut v = $v;
v.reverse();
while (!v.is_empty()) $f(v.pop_back());
while (v.length() != 0) $f(v.pop_back());
v.destroy_empty();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ module std::vector_tests {
fun push_back_and_borrow() {
let mut v = vector[];
v.push_back(7);
assert!(!v.is_empty());
assert!(v.length() != 0);
assert!(v.length() == 1);
assert!(v[0] == 7);

Expand Down
Binary file modified crates/iota-framework/packages_compiled/iota-framework
Binary file not shown.
Binary file modified crates/iota-framework/packages_compiled/iota-system
Binary file not shown.
Binary file modified crates/iota-framework/packages_compiled/move-stdlib
Binary file not shown.
1 change: 1 addition & 0 deletions crates/iota-protocol-config/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ use tracing::{info, warn};

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

pub const MAX_PROTOCOL_VERSION: u64 = 5;

// Record history of protocol version allocations here:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ system_state_version: 1
iota_treasury_cap:
inner:
id:
id: "0xb8ea620a4a06f52c7403076ba7e581809e32dfd51485f0ced8d7d3ff5696359c"
id: "0xa5e27e4709c2858a8708a22707d578060e4fee92600fdc32dd5dcd3afa06142c"
total_supply:
value: "751500000000000000"
validators:
Expand Down Expand Up @@ -244,56 +244,56 @@ validators:
next_epoch_primary_address: ~
extra_fields:
id:
id: "0xb27dc294d9f8f1cef32a2db0a9a478a5e659eb749b1296a62116f2ff3d22f5fa"
id: "0x93b3bf927440cf7dddea8b6964baa60e9d99e42404bd38934e6b90f3ead513ab"
size: 0
voting_power: 10000
operation_cap_id: "0xc6286dfa59d06b08cb8e728518a98b1bb13d4b1cd70fae56b172b51604710e94"
operation_cap_id: "0x2c556d2a45d29d6ad5d6053ba32e0337307876edc66d8a662d73b1cf3e3a9ae1"
gas_price: 1000
staking_pool:
id: "0xfeb621a82bd7e078f1bdc92f019a49848239260b95eb72125b77381f4349db04"
id: "0x84f3a58b2b80ed5a9727668a91af70017e9ac21addbd16f9b13dc9309ad60910"
activation_epoch: 0
deactivation_epoch: ~
iota_balance: 1500000000000000
rewards_pool:
value: 0
pool_token_balance: 1500000000000000
exchange_rates:
id: "0xc994262d6e506e14d01d1f8197e7f97d0137b3737a55f083697f45fd865e4cf0"
id: "0x4f7cfbd9e4e3ebfa9f06f0c1e10237aab9f9463e9c9ce2b2b28a6a0a21cefe2f"
size: 1
pending_stake: 0
pending_total_iota_withdraw: 0
pending_pool_token_withdraw: 0
extra_fields:
id:
id: "0x7823d31d6465e6373d4b97ecd77d55bef2ef7018377b2479d8eb47b74849a87c"
id: "0x5d5a34a61bd28f70e6b8bf8d9ef4dbb534b5badac0ea63f53d88c26041be27a6"
size: 0
commission_rate: 200
next_epoch_stake: 1500000000000000
next_epoch_gas_price: 1000
next_epoch_commission_rate: 200
extra_fields:
id:
id: "0x29576ca2df9f06b71370d535167813d4dd72028f49b9d5bf0232ec01dbbf67ef"
id: "0x52a787d1672caf6a2e96c0fe48ab1ad884cd126d10c72f707cd64fa0998926e5"
size: 0
pending_active_validators:
contents:
id: "0xeac23bd9819b924d7d9b0742102e1247f471757e6dec01dd64484707353fcb72"
id: "0xf3ccc402a8c77b2e218c7793b01deec880417562a00fbb6a189232af78963190"
size: 0
pending_removals: []
staking_pool_mappings:
id: "0x004ca17057de6323edbd884409e198d7c8b86eba42ef267300a3d1954af0fa35"
id: "0xb38289807d76358af54dd9914366135feccb6fe03b2d8ec07c2191b7ef7d1cd4"
size: 1
inactive_validators:
id: "0x94b39ded3a3fd075e12efaa98ec0c76c46da9c722b8eab3f7ff943c03be01017"
id: "0x3a44358dca7216e898b0c8e04f5bbc8129c94cfba767aea69d8bdeb05245dd94"
size: 0
validator_candidates:
id: "0x085cc7fb78f3b92ac3192a605c89517ac6ca2cfcbb9c9f5d9614a8e2756760a7"
id: "0x303e30a28299dcf6c6b05edbd435ad613611a8c7f7b1d7cd3f6a16f9f7b9c844"
size: 0
at_risk_validators:
contents: []
extra_fields:
id:
id: "0x7ecf5590013d0a068249a529fe0f0686513eb5161e195c2bcbf3feac9728d423"
id: "0x7e3428aaad09659c12828efc8f064fdc2d1dd1c9bfee89c37dabc6ad9575038a"
size: 0
storage_fund:
total_object_storage_rebates:
Expand All @@ -310,7 +310,7 @@ parameters:
validator_low_stake_grace_period: 7
extra_fields:
id:
id: "0x3089dcf2c62ed1ac421d6c8b7a5cad4b9736c9609d231cdd7201de8a77a2c07a"
id: "0x368bd0f25d1e8664ebee31e74463b5f7e1f07d118f9ae8988be187c0fb2b9736"
size: 0
iota_system_admin_cap:
dummy_field: false
Expand All @@ -327,5 +327,5 @@ safe_mode_non_refundable_storage_fee: 0
epoch_start_timestamp_ms: 10
extra_fields:
id:
id: "0x34709254ed5289c57bff605d86d6eb044156f25a7d9d8d19e1594af5288ea9ee"
id: "0xbc8fa71cc6de6bec594c5d68c47eabb583278f9b2f3fe16f5148cb3da733288e"
size: 0
Loading