aptos-core icon indicating copy to clipboard operation
aptos-core copied to clipboard

[Token] enforce royalty numerator is smaller or equal to denominator

Open areshand opened this issue 2 years ago • 14 comments

Description

no valid usecase for royalty can exceed the txn price

Test Plan

cargo test -p framework


This change is Reviewable

areshand avatar Nov 03 '22 23:11 areshand

@movekevin can we land this first since this PR is strictly an improvement to status quo? As to whether 100% is error, we can discuss separately to add it if there is a consensus

areshand avatar Nov 05 '22 00:11 areshand

@movekevin can we land this first since this PR is strictly an improvement to status quo? As to whether 100% is error, we can discuss separately to add it if there is a consensus

Okay.

movekevin avatar Nov 05 '22 01:11 movekevin

Forge is running suite compat on 2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> 56bd127c4eb521dab79f84c4d9b5f640276f0b35

github-actions[bot] avatar Nov 05 '22 18:11 github-actions[bot]

Forge is running suite land_blocking on 56bd127c4eb521dab79f84c4d9b5f640276f0b35

github-actions[bot] avatar Nov 05 '22 18:11 github-actions[bot]

:white_check_mark: Forge suite land_blocking success on 56bd127c4eb521dab79f84c4d9b5f640276f0b35

performance benchmark with full nodes : 6761 TPS, 5757 ms latency, 12600 ms p99 latency,(!) expired 6705 out of 2893920 txns
Test Ok

github-actions[bot] avatar Nov 05 '22 18:11 github-actions[bot]

:white_check_mark: Forge suite compat success on 2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> 56bd127c4eb521dab79f84c4d9b5f640276f0b35

Compatibility test results for 2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> 56bd127c4eb521dab79f84c4d9b5f640276f0b35 (PR)
1. Check liveness of validators at old version: 2d8b1b57553d869190f61df1aaf7f31a8fc19a7b
compatibility::simple-validator-upgrade::liveness-check : 6902 TPS, 5589 ms latency, 8800 ms p99 latency,no expired txns
2. Upgrading first Validator to new version: 56bd127c4eb521dab79f84c4d9b5f640276f0b35
compatibility::simple-validator-upgrade::single-validator-upgrade : 4242 TPS, 9497 ms latency, 12400 ms p99 latency,no expired txns
3. Upgrading rest of first batch to new version: 56bd127c4eb521dab79f84c4d9b5f640276f0b35
compatibility::simple-validator-upgrade::half-validator-upgrade : 4764 TPS, 8726 ms latency, 10900 ms p99 latency,no expired txns
4. upgrading second batch to new version: 56bd127c4eb521dab79f84c4d9b5f640276f0b35
compatibility::simple-validator-upgrade::rest-validator-upgrade : 6234 TPS, 6429 ms latency, 15000 ms p99 latency,no expired txns
5. check swarm health
Compatibility test for 2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> 56bd127c4eb521dab79f84c4d9b5f640276f0b35 passed
Test Ok

github-actions[bot] avatar Nov 05 '22 18:11 github-actions[bot]

Forge is running suite compat on testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> e421741061b838f683bfc94b332d355ae2855f93

github-actions[bot] avatar Nov 05 '22 23:11 github-actions[bot]

Forge is running suite land_blocking on e421741061b838f683bfc94b332d355ae2855f93

github-actions[bot] avatar Nov 05 '22 23:11 github-actions[bot]

:white_check_mark: Forge suite land_blocking success on e421741061b838f683bfc94b332d355ae2855f93

performance benchmark with full nodes : 6868 TPS, 5770 ms latency, 13200 ms p99 latency,(!) expired 1238 out of 2934180 txns
Test Ok

github-actions[bot] avatar Nov 06 '22 00:11 github-actions[bot]

:white_check_mark: Forge suite compat success on testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> e421741061b838f683bfc94b332d355ae2855f93

Compatibility test results for testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> e421741061b838f683bfc94b332d355ae2855f93 (PR)
1. Check liveness of validators at old version: testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b
compatibility::simple-validator-upgrade::liveness-check : 7591 TPS, 5269 ms latency, 7400 ms p99 latency,no expired txns
2. Upgrading first Validator to new version: e421741061b838f683bfc94b332d355ae2855f93
compatibility::simple-validator-upgrade::single-validator-upgrade : 4762 TPS, 8713 ms latency, 10600 ms p99 latency,no expired txns
3. Upgrading rest of first batch to new version: e421741061b838f683bfc94b332d355ae2855f93
compatibility::simple-validator-upgrade::half-validator-upgrade : 5098 TPS, 8066 ms latency, 10900 ms p99 latency,no expired txns
4. upgrading second batch to new version: e421741061b838f683bfc94b332d355ae2855f93
compatibility::simple-validator-upgrade::rest-validator-upgrade : 6879 TPS, 5594 ms latency, 10100 ms p99 latency,no expired txns
5. check swarm health
Compatibility test for testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> e421741061b838f683bfc94b332d355ae2855f93 passed
Test Ok

github-actions[bot] avatar Nov 06 '22 00:11 github-actions[bot]

Forge is running suite land_blocking on 20e331a021abf61005bdc61fccbde0a4edc73169

github-actions[bot] avatar Nov 08 '22 02:11 github-actions[bot]

Forge is running suite compat on testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> 20e331a021abf61005bdc61fccbde0a4edc73169

github-actions[bot] avatar Nov 08 '22 02:11 github-actions[bot]

:white_check_mark: Forge suite compat success on testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> 20e331a021abf61005bdc61fccbde0a4edc73169

Compatibility test results for testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> 20e331a021abf61005bdc61fccbde0a4edc73169 (PR)
1. Check liveness of validators at old version: testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b
compatibility::simple-validator-upgrade::liveness-check : 7392 TPS, 5201 ms latency, 7100 ms p99 latency,no expired txns
2. Upgrading first Validator to new version: 20e331a021abf61005bdc61fccbde0a4edc73169
compatibility::simple-validator-upgrade::single-validator-upgrade : 4648 TPS, 8679 ms latency, 12100 ms p99 latency,no expired txns
3. Upgrading rest of first batch to new version: 20e331a021abf61005bdc61fccbde0a4edc73169
compatibility::simple-validator-upgrade::half-validator-upgrade : 4966 TPS, 8021 ms latency, 10000 ms p99 latency,no expired txns
4. upgrading second batch to new version: 20e331a021abf61005bdc61fccbde0a4edc73169
compatibility::simple-validator-upgrade::rest-validator-upgrade : 6878 TPS, 5592 ms latency, 10000 ms p99 latency,no expired txns
5. check swarm health
Compatibility test for testnet_2d8b1b57553d869190f61df1aaf7f31a8fc19a7b ==> 20e331a021abf61005bdc61fccbde0a4edc73169 passed
Test Ok

github-actions[bot] avatar Nov 08 '22 02:11 github-actions[bot]

:white_check_mark: Forge suite land_blocking success on 20e331a021abf61005bdc61fccbde0a4edc73169

performance benchmark with full nodes : 6615 TPS, 6033 ms latency, 17000 ms p99 latency,no expired txns
Test Ok

github-actions[bot] avatar Nov 08 '22 02:11 github-actions[bot]