-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat!: allow Operator to revoke himself #893
Conversation
👋 Hello ⛽📊 Gas Benchmark ReportDeployment Costs
Runtime CostsUniversalProfile owned by an 🔑 EOA🔀
|
execute scenarios - UP owned by 🔑 EOA |
⛽ Gas Usage |
---|---|
Transfer 1 LYX to an EOA without data | 37572 (0 ) |
Transfer 1 LYX to a UP without data | 46265 (0 ) |
Transfer 1 LYX to an EOA with 256 bytes of data | 42233 (0 ) |
Transfer 1 LYX to a UP with 256 bytes of data | 57174 (-24 📉✅) |
Transfer 0.1 LYX to 3x EOA without data | 70898 (0 ) |
Transfer 0.1 LYX to 3x UP without data | 104489 (0 ) |
Transfer 0.1 LYX to 3x EOA with 256 bytes of data | 84874 (36 📈❌) |
Transfer 0.1 LYX to 3x UPs with 256 bytes of data | 137173 (-108 📉✅) |
🗄️ setData
scenarios
setData scenarios - UP owned by 🔑 EOA |
⛽ Gas Usage |
---|---|
Set a 20 bytes long value | 49921 (0 ) |
Set a 60 bytes long value | 95231 (0 ) |
Set a 160 bytes long value | 164415 (0 ) |
Set a 300 bytes long value | 279284 (0 ) |
Set a 600 bytes long value | 486620 (-48 📉✅) |
Change the value of a data key already set | 32809 (0 ) |
Remove the value of a data key already set | 27283 (0 ) |
Set 2 data keys of 20 bytes long value | 78428 (-12 📉✅) |
Set 2 data keys of 100 bytes long value | 260580 (-24 📉✅) |
Set 3 data keys of 20 bytes long value | 105128 (0 ) |
Change the value of three data keys already set of 20 bytes long value | 45428 (12 📈❌) |
Remove the value of three data keys already set | 41325 (0 ) |
🗄️ Tokens
scenarios
Tokens scenarios - UP owned by 🔑 EOA |
⛽ Gas Usage |
---|---|
Minting a LSP7Token to a UP (No Delegate) from an EOA | 93023 (-91 📉✅) |
Minting a LSP7Token to an EOA from an EOA | 59300 (-90 📉✅) |
Transferring an LSP7Token from a UP to another UP (No Delegate) | 102217 (-150 📉✅) |
Minting a LSP8Token to a UP (No Delegate) from an EOA | 160165 (0 ) |
Minting a LSP8Token to an EOA from an EOA | 126442 (0 ) |
Transferring an LSP8Token from a UP to another UP (No Delegate) | 151088 (-59 📉✅) |
UniversalProfile owned by a 🔒📄 LSP6KeyManager
🔀 execute
scenarios
execute scenarios |
👑 main controller | 🛃 restricted controller |
---|---|---|
LYX transfer --> to an EOA | 64365 (0 ) | 75316 (0 ) |
LYX transfer --> to a UP | 78508 (0 ) | 93410 (0 ) |
LSP7 token transfer --> to an EOA | 116723 (-149 📉✅) | 131473 (-149 📉✅) |
LSP7 token transfer --> to a UP | 250368 (-150 📉✅) | 265118 (-150 📉✅) |
LSP8 NFT transfer --> to an EOA | 180986 (-59 📉✅) | 195736 (-59 📉✅) |
LSP8 NFT transfer --> to a UP | 297834 (-59 📉✅) | 312584 (-59 📉✅) |
🗄️ setData
scenarios
setData scenarios |
👑 main controller | 🛃 restricted controller |
---|---|---|
Update Profile details (LSP3Profile Metadata) | 67264 (0 ) | 77286 (0 ) |
Add a new controller with permission to SET_DATA + 3x allowed data keys: AddressPermissions[] + AddressPermissions[index] + AddressPermissions:Permissions:<controller> + AddressPermissions:AllowedERC725YDataKeys:<controller ) |
209516 (0 ) | 219673 (0 ) |
Update permissions of previous controller. Allow it now to SUPER_SETDATA |
52292 (0 ) | 55298 (0 ) |
Remove a controller: 1. decrease AddressPermissions[] Array length 2. remove the controller address at AddressPermissions[index] 3. set "0x" for the controller permissions under AddressPermissions:Permissions: |
78765 (0 ) | 90064 (0 ) |
Write 5x new LSP12 Issued Assets | 66959 (0 ) | 101586 (0 ) |
Update 3x data keys (first 3) | 125411 (0 ) | 159515 (0 ) |
Update 3x data keys (middle 3) | 105499 (0 ) | 143669 (0 ) |
Update 3x data keys (last 3) | 125411 (0 ) | 169002 (0 ) |
Set 2 x new data keys + add 3x new controllers | 810121 (0 ) | 871921 (0 ) |
Changes to gas cost
🧾 Summary (10% most significant diffs)
Full diff report 👇
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added review comments
contracts/LSP8IdentifiableDigitalAsset/LSP8IdentifiableDigitalAssetCore.sol
Show resolved
Hide resolved
contracts/LSP8IdentifiableDigitalAsset/LSP8IdentifiableDigitalAssetCore.sol
Outdated
Show resolved
Hide resolved
Super! Let's get this new feature in |
* feat!: allow operator to revoke himself * test: add test for operator revoking himself * refactor!: change LSP7 interfaceId * chore: fix parameter and generate natspec * chore: do suggested changes --------- Co-authored-by: Jean Cvllr <[email protected]>
What does this PR introduce?
🚀 Feature
PR Checklist
npm run lint
&&npm run lint:solidity
(solhint)npm run format
(prettier)npm run build
npm run test