Skip to content
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

[WIP] Lotus nv23 integration and testing #11939

Open
1 of 5 tasks
rjan90 opened this issue Apr 29, 2024 · 4 comments
Open
1 of 5 tasks

[WIP] Lotus nv23 integration and testing #11939

rjan90 opened this issue Apr 29, 2024 · 4 comments

Comments

@rjan90
Copy link
Contributor

rjan90 commented Apr 29, 2024

Starting a WIP-thread for nv23 integration and testing:

Tasks

  1. rjan90
@rjan90 rjan90 changed the title [WIP] Lotus nv22 integration and testing [WIP] Lotus nv23 integration and testing Apr 29, 2024
@aarshkshah1992
Copy link
Contributor

aarshkshah1992 commented Apr 29, 2024

Testplan for #11930

  • Submit a signed legacy ETH transaction to transfer FIL from account A to account B and confirm the transfer on chain
  • Submit a signed legacy ETH transaction to deploy an ERC-20 contract on Filecoin
  • Invoke a signed legacy ETH token transfer transaction on the above contract and ensure the balances are updated on chain
  • Submit a signed legacy ETH transaction to transfer FIL from account A to account B with an incorrect signature and confirm the transfer fails

@rjan90
Copy link
Contributor Author

rjan90 commented May 8, 2024

Testplan for FIP-0085:

  • Migration test in lotus asserting the new state of f090.
  • In a devnet setup f090 with known keys and spend some money before the network upgrade. Demonstrate that this does not work after migration.

Setup devnet with GST: https://github.com/filecoin-project/go-state-types/releases/tag/v0.14.0-dev5, which includes the migration of f090 to a keyless account actor.

  1. Set the RemainderAccount to known keys:
  "RemainderAccount": {
    "Type": "multisig",
    "Balance": "300000000",
    "Meta": {
      "Signers": [
        "t1owsmgkggadc65g2sjavkyu6vdiwnuxmqs5fyqpy",
        "t1zncrhcw6bwllvz2vjehon2vposxd47ycrj6uhvy",
        "t1rldfhzcub6hql4dxe7rv3zzuwvflxtmudwxta2y"
      ],
  1. Inspecting the f090:
lotus msig inspect f090
Balance: 850000000 FIL
Spendable: 850000000 FIL
Threshold: 1 / 3
Signers:
ID      Address
t0102   t1owsmgkggadc65g2sjavkyu6vdiwnuxmqs5fyqpy
t0103   t1zncrhcw6bwllvz2vjehon2vposxd47ycrj6uhvy
t0104   t1rldfhzcub6hql4dxe7rv3zzuwvflxtmudwxta2y
Transactions:  0
  1. Confirming I can spend some $$ before the upgrade and migration by signing with these keys:
lotus msig propose --from=t1owsmgkggadc65g2sjavkyu6vdiwnuxmqs5fyqpy f090 t3uu5mzlnh7v6dh5wugxcp5uccefavldqblhmeyouf5vxattqfcgahp764etfp2zyysy47qd2h7odlid75mjpq 2000000
sent proposal in message:  bafy2bzaceckyqlz6q4k6qogvyw55ghxj2uj6pfhymfqpwosi7obktujx36zoa
Transaction ID: 0
Transaction was executed during propose
Exit Code: 0
Return Value: 
  1. Check that balance of f090 has gone down:
lotus msig inspect f090
Balance: 848000000 FIL
Spendable: 848000000 FIL
Threshold: 1 / 3
Signers:
ID      Address
t0102   t1owsmgkggadc65g2sjavkyu6vdiwnuxmqs5fyqpy
t0103   t1zncrhcw6bwllvz2vjehon2vposxd47ycrj6uhvy
t0104   t1rldfhzcub6hql4dxe7rv3zzuwvflxtmudwxta2y
Transactions:  0
  1. After the network upgrade and migration, check f090 is now a keyless account:
lotus state network-version
Network Version: 23

lotus msig inspect f090
ERROR: actor code is not multisig: account
  1. Confirm that I can´t spend f090´s money:
lotus msig propose --from=t1owsmgkggadc65g2sjavkyu6vdiwnuxmqs5fyqpy f090 t3uu5mzlnh7v6dh5wugxcp5uccefavldqblhmeyouf5vxattqfcgahp764etfp2zyysy47qd2h7odlid75mjpq 2000000
ERROR: actor t090 is not a multisig actor

@rjan90
Copy link
Contributor Author

rjan90 commented May 8, 2024

Testing plan for FIP-0090: Non-Interactive PoRep: filecoin-project/builtin-actors#1534 (comment)

@ZenGround0
Copy link
Contributor

ZenGround0 commented May 14, 2024

Testing plan for FIP-0065

  • itest demonstrating locked supply does not include f05 balance in nv23
  • Devnet test
  1. Setup devnet node to run nv22 and then migrate to nv23
  2. Make some very expensive deals to set the market locked balance high. Check f05 locked balance to get an exact number of locked FIL.
  3. A few epochs before migration record external circulating supply (lotus state circulating-supply) and internal approximate circulating supply (no CLI command need to query API StateVMCirculatingSupplyInternal)
  4. After migration do the same
  5. Compare the circulating supply values and sanity check that they are roughly different by locked market balance. This will only be approximate because circulating supply in devenet is always fluctuating anyway.

Testing steps:

Create some very expensive deals in nv22:

lotus client deal
Data CID (from lotus client import): bafkqas3gmftgu2tpmf3wmcqkmn3wcctgmvqqu5tbmjzge4tbomfge4tbbjrheylcojrheyikmjzgcylcmfzgezlubjzgcytfmjzgczlcojqwkctcojqwk4tcmvqqucq
.. calculating data size
Deal duration (days): 30
Miner Addresses (f0.. f0..), none to find: t01000
.. querying miner asks
-----
Proposing from t3vtkuwlm5zsjd45nwaassuqp2q5zf3wuzvnnkf6offcah3pt5w3qmmbyxkgvbtmxc7g4ydax2kzfxsl2gx3oa
        Balance: 49999999.999651851576283142 FIL

Piece size: 512B (Payload size: 258B)
Duration: 720h0m0s
Total price: ~30899047.8515625 FIL (47.6837158203125 FIL per epoch)
Verified: false

Accept (yes/no): yes
.. executing
Deal (t01000) CID: bafyreibutyrtq673kfwyuumgm5bxhoaj4q6lqsbtbnhqefl2xztke35xze

Check circulating supply:

lotus state  circulating-supply 
Exact circulating supply:  19076763.255135593801150817 FIL
-------
lotus state  circulating-supply --vm-supply
Circulating supply:  0 FIL
Mined:  5425.389686176467615734 FIL
Vested:  10665982.270004977404786226 FIL
Burnt:  0.000344302319213086 FIL
Locked:  30928627.681795243302307352 FIL

After network upgrade to nv23, check circulating supply again:

lotus state  circulating-supply --vm-supply
Circulating supply:  0 FIL
Mined:  18814.41414898577843093 FIL
Vested:  10746774.55432144684694266 FIL
Burnt:  0.000344308303407686 FIL
Locked:  14110.810621475185075461 FIL
-------
lotus state  circulating-supply 
Exact circulating supply:  50004705.416395983109640427 FIL

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants