From ab24fbb0f5340207ea2a2ce6b6afebdc6c5f2301 Mon Sep 17 00:00:00 2001 From: "terry.hung" Date: Sat, 13 Jul 2024 01:01:21 +0800 Subject: [PATCH 1/3] chore: update lotus version for nv23 --- chain/datasource/datasource.go | 6 +-- extern/filecoin-ffi | 2 +- go.mod | 19 ++++---- go.sum | 33 +++++++------ tasks/fevm/contract/task.go | 8 ++-- tasks/fevm/trace/task.go | 4 +- tasks/fevm/transaction/tasks.go | 47 +++++++++++-------- tasks/periodic_actor_dump/fevm_actor/tasks.go | 10 ++-- .../periodic_actor_dump/miner_actor/tasks.go | 8 ++-- 9 files changed, 77 insertions(+), 60 deletions(-) diff --git a/chain/datasource/datasource.go b/chain/datasource/datasource.go index cd76aac6..da9699a5 100644 --- a/chain/datasource/datasource.go +++ b/chain/datasource/datasource.go @@ -281,12 +281,12 @@ func (t *DataSource) ActorInfo(ctx context.Context, addr address.Address, tsk ty act, err := t.Actor(ctx, addr, tsk) actorInfo := tasks.ActorInfo{} if err == nil { - if act.Address == nil { + if act.DelegatedAddress == nil { robustAddress, err := t.LookupRobustAddress(ctx, addr, tsk) if err == nil { - act.Address = &robustAddress + act.DelegatedAddress = &robustAddress } else { - act.Address = &addr + act.DelegatedAddress = &addr } } actorInfo.Actor = act diff --git a/extern/filecoin-ffi b/extern/filecoin-ffi index 081367ca..e467d299 160000 --- a/extern/filecoin-ffi +++ b/extern/filecoin-ffi @@ -1 +1 @@ -Subproject commit 081367cae7cdfe87d8b7240a9c3767ce86a40b05 +Subproject commit e467d2992e3f9bd09beb71ecf84323b45d2a3511 diff --git a/go.mod b/go.mod index 275ebc64..ad1f0138 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.21 require ( contrib.go.opencensus.io/exporter/prometheus v0.4.2 - github.com/BurntSushi/toml v1.3.0 + github.com/BurntSushi/toml v1.3.2 github.com/OneOfOne/xxhash v1.2.8 // indirect github.com/filecoin-project/go-address v1.1.0 github.com/filecoin-project/go-amt-ipld/v2 v2.1.1-0.20201006184820-924ee87a1349 // indirect @@ -13,8 +13,8 @@ require ( github.com/filecoin-project/go-hamt-ipld/v3 v3.3.1-0.20230511074215-a0b13f309e1b github.com/filecoin-project/go-jsonrpc v0.3.2 github.com/filecoin-project/go-paramfetch v0.0.4 - github.com/filecoin-project/go-state-types v0.14.0-dev - github.com/filecoin-project/lotus v1.27.1 + github.com/filecoin-project/go-state-types v0.14.0-rc5 + github.com/filecoin-project/lotus v1.28.0-rc5 github.com/filecoin-project/specs-actors v0.9.15 github.com/filecoin-project/specs-actors/v2 v2.3.6 github.com/filecoin-project/specs-actors/v3 v3.1.2 @@ -72,7 +72,7 @@ require ( github.com/ipfs/go-ipld-format v0.6.0 github.com/ipld/go-ipld-prime v0.21.0 github.com/jedib0t/go-pretty/v6 v6.2.7 - github.com/libp2p/go-libp2p v0.34.1 + github.com/libp2p/go-libp2p v0.35.0 github.com/multiformats/go-varint v0.0.7 go.opentelemetry.io/otel/trace v1.26.0 go.uber.org/atomic v1.11.0 @@ -83,6 +83,7 @@ require ( github.com/GeertJohan/go.rice v1.0.3 // indirect github.com/Gurpartap/async v0.0.0-20180927173644-4f7f499dd9ee // indirect github.com/Jorropo/jsync v1.0.1 // indirect + github.com/Kubuxu/go-broadcast v0.0.0-20240621161059-1a8c90734cd6 // indirect github.com/Kubuxu/imtui v0.0.0-20210401140320-41663d68d0fa // indirect github.com/StackExchange/wmi v1.2.1 // indirect github.com/acarl005/stripansi v0.0.0-20180116102854-5a71ef0e047d // indirect @@ -97,7 +98,7 @@ require ( github.com/cilium/ebpf v0.9.1 // indirect github.com/containerd/cgroups v1.1.0 // indirect github.com/coreos/go-systemd/v22 v22.5.0 // indirect - github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect + github.com/cpuguy83/go-md2man/v2 v2.0.4 // indirect github.com/crackcomm/go-gitignore v0.0.0-20231225121904-e25f5bc08668 // indirect github.com/cskr/pubsub v1.0.2 // indirect github.com/daaku/go.zipexe v1.0.2 // indirect @@ -111,7 +112,7 @@ require ( github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect github.com/docker/go-units v0.5.0 // indirect github.com/drand/drand v1.5.11 // indirect - github.com/drand/kyber v1.3.0 // indirect + github.com/drand/kyber v1.3.1 // indirect github.com/drand/kyber-bls12381 v0.3.1 // indirect github.com/dustin/go-humanize v1.0.1 // indirect github.com/elastic/go-elasticsearch/v7 v7.14.0 // indirect @@ -119,11 +120,12 @@ require ( github.com/elastic/go-windows v1.0.0 // indirect github.com/elastic/gosigar v0.14.2 // indirect github.com/fatih/color v1.15.0 // indirect - github.com/filecoin-project/filecoin-ffi v0.30.4-0.20220519234331-bfd1f5f9fe38 // indirect + github.com/filecoin-project/filecoin-ffi v1.28.0-rc2 // indirect github.com/filecoin-project/go-cbor-util v0.0.1 // indirect github.com/filecoin-project/go-commp-utils v0.1.3 // indirect github.com/filecoin-project/go-commp-utils/nonffi v0.0.0-20220905160352-62059082a837 // indirect github.com/filecoin-project/go-crypto v0.0.1 // indirect + github.com/filecoin-project/go-f3 v0.0.3-0.20240702063402-d48771055cf4 // indirect github.com/filecoin-project/go-fil-commcid v0.1.0 // indirect github.com/filecoin-project/go-hamt-ipld v0.1.5 // indirect github.com/filecoin-project/go-hamt-ipld/v2 v2.0.0 // indirect @@ -202,6 +204,7 @@ require ( github.com/jessevdk/go-flags v1.4.0 // indirect github.com/jinzhu/inflection v1.0.0 // indirect github.com/joeshaw/multierror v0.0.0-20140124173710-69b34d4ec901 // indirect + github.com/jpillora/backoff v1.0.0 // indirect github.com/kelseyhightower/envconfig v1.4.0 // indirect github.com/kilic/bls12-381 v0.1.0 // indirect github.com/klauspost/compress v1.17.8 // indirect @@ -302,7 +305,7 @@ require ( github.com/whyrusleeping/multiaddr-filter v0.0.0-20160516205228-e903e4adabd7 // indirect github.com/wk8/go-ordered-map/v2 v2.1.8 // indirect github.com/x448/float16 v0.8.4 // indirect - github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect + github.com/xrash/smetrics v0.0.0-20240312152122-5f08fbb34913 // indirect github.com/yugabyte/pgx/v5 v5.5.3-yb-2 // indirect github.com/zondax/hid v0.9.2 // indirect github.com/zondax/ledger-filecoin-go v0.11.1 // indirect diff --git a/go.sum b/go.sum index 0c380e8a..1a0e79ad 100644 --- a/go.sum +++ b/go.sum @@ -44,8 +44,8 @@ github.com/AndreasBriese/bbloom v0.0.0-20180913140656-343706a395b7/go.mod h1:bOv github.com/AndreasBriese/bbloom v0.0.0-20190825152654-46b345b51c96 h1:cTp8I5+VIoKjsnZuH8vjyaysT/ses3EvZeaV/1UkF2M= github.com/AndreasBriese/bbloom v0.0.0-20190825152654-46b345b51c96/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/BurntSushi/toml v1.3.0 h1:Ws8e5YmnrGEHzZEzg0YvK/7COGYtTC5PbaH9oSSbgfA= -github.com/BurntSushi/toml v1.3.0/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= +github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= +github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/DataDog/zstd v1.4.1/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ= @@ -58,6 +58,8 @@ github.com/Gurpartap/async v0.0.0-20180927173644-4f7f499dd9ee h1:8doiS7ib3zi6/K1 github.com/Gurpartap/async v0.0.0-20180927173644-4f7f499dd9ee/go.mod h1:W0GbEAA4uFNYOGG2cJpmFJ04E6SD1NLELPYZB57/7AY= github.com/Jorropo/jsync v1.0.1 h1:6HgRolFZnsdfzRUj+ImB9og1JYOxQoReSywkHOGSaUU= github.com/Jorropo/jsync v1.0.1/go.mod h1:jCOZj3vrBCri3bSU3ErUYvevKlnbssrXeCivybS5ABQ= +github.com/Kubuxu/go-broadcast v0.0.0-20240621161059-1a8c90734cd6 h1:yh2/1fz3ajTaeKskSWxtSBNScdRZfQ/A5nyd9+64T6M= +github.com/Kubuxu/go-broadcast v0.0.0-20240621161059-1a8c90734cd6/go.mod h1:5LOj/fF3Oc/cvJqzDiyfx4XwtBPRWUYEz+V+b13sH5U= github.com/Kubuxu/go-os-helper v0.0.1/go.mod h1:N8B+I7vPCT80IcP58r50u4+gEEcsZETFUpAzWW2ep1Y= github.com/Kubuxu/imtui v0.0.0-20210401140320-41663d68d0fa h1:1PPxEyGdIGVkX/kqMvLJ95a1dGS1Sz7tpNEgehEYYt0= github.com/Kubuxu/imtui v0.0.0-20210401140320-41663d68d0fa/go.mod h1:WUmMvh9wMtqj1Xhf1hf3kp9RvL+y6odtdYxpyZjb90U= @@ -163,8 +165,8 @@ github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSV github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= -github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= -github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/cpuguy83/go-md2man/v2 v2.0.4 h1:wfIWP927BUkWJb2NmU/kNDYIBTh/ziUX91+lVfRxZq4= +github.com/cpuguy83/go-md2man/v2 v2.0.4/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/crackcomm/go-gitignore v0.0.0-20231225121904-e25f5bc08668 h1:ZFUue+PNxmHlu7pYv+IYMtqlaO/0VwaGEqKepZf9JpA= github.com/crackcomm/go-gitignore v0.0.0-20231225121904-e25f5bc08668/go.mod h1:p1d6YEZWvFzEh4KLyvBcVSnrfNDDvK2zfK/4x2v/4pE= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= @@ -206,8 +208,8 @@ github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4 github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/drand/drand v1.5.11 h1:7sskUTCsX2lgFiWdGvPh3/P0ZDQKi1lCtI7RQKK010k= github.com/drand/drand v1.5.11/go.mod h1:TvJjCJ/s4Usn4pKRpDC0N1QaCwSt3YC8fRqhZdpOUU0= -github.com/drand/kyber v1.3.0 h1:TVd7+xoRgKQ4Ck1viNLPFy6IWhuZM36Bq6zDXD8Asls= -github.com/drand/kyber v1.3.0/go.mod h1:f+mNHjiGT++CuueBrpeMhFNdKZAsy0tu03bKq9D5LPA= +github.com/drand/kyber v1.3.1 h1:E0p6M3II+loMVwTlAp5zu4+GGZFNiRfq02qZxzw2T+Y= +github.com/drand/kyber v1.3.1/go.mod h1:f+mNHjiGT++CuueBrpeMhFNdKZAsy0tu03bKq9D5LPA= github.com/drand/kyber-bls12381 v0.3.1 h1:KWb8l/zYTP5yrvKTgvhOrk2eNPscbMiUOIeWBnmUxGo= github.com/drand/kyber-bls12381 v0.3.1/go.mod h1:H4y9bLPu7KZA/1efDg+jtJ7emKx+ro3PU7/jWUVt140= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= @@ -260,6 +262,8 @@ github.com/filecoin-project/go-commp-utils/nonffi v0.0.0-20220905160352-62059082 github.com/filecoin-project/go-crypto v0.0.0-20191218222705-effae4ea9f03/go.mod h1:+viYnvGtUTgJRdy6oaeF4MTFKAfatX071MPDPBL11EQ= github.com/filecoin-project/go-crypto v0.0.1 h1:AcvpSGGCgjaY8y1az6AMfKQWreF/pWO2JJGLl6gCq6o= github.com/filecoin-project/go-crypto v0.0.1/go.mod h1:+viYnvGtUTgJRdy6oaeF4MTFKAfatX071MPDPBL11EQ= +github.com/filecoin-project/go-f3 v0.0.3-0.20240702063402-d48771055cf4 h1:eQW2fyKyMuiweuySEb/zMIc3WLSAnIOY8lpqCVQM7pU= +github.com/filecoin-project/go-f3 v0.0.3-0.20240702063402-d48771055cf4/go.mod h1:Wry0mNa8z767TBHb7N0cVb+9j00KsHbD2pzsC3li4R8= github.com/filecoin-project/go-fil-commcid v0.0.0-20201016201715-d41df56b4f6a/go.mod h1:Eaox7Hvus1JgPrL5+M3+h7aSPHc0cVqpSxA+TxIEpZQ= github.com/filecoin-project/go-fil-commcid v0.1.0 h1:3R4ds1A9r6cr8mvZBfMYxTS88OqLYEo6roi+GiIeOh8= github.com/filecoin-project/go-fil-commcid v0.1.0/go.mod h1:Eaox7Hvus1JgPrL5+M3+h7aSPHc0cVqpSxA+TxIEpZQ= @@ -285,8 +289,8 @@ github.com/filecoin-project/go-state-types v0.1.0/go.mod h1:ezYnPf0bNkTsDibL/psS github.com/filecoin-project/go-state-types v0.1.6/go.mod h1:UwGVoMsULoCK+bWjEdd/xLCvLAQFBC7EDT477SKml+Q= github.com/filecoin-project/go-state-types v0.1.10/go.mod h1:UwGVoMsULoCK+bWjEdd/xLCvLAQFBC7EDT477SKml+Q= github.com/filecoin-project/go-state-types v0.13.1/go.mod h1:cHpOPup9H1g2T29dKHAjC2sc7/Ef5ypjuW9A3I+e9yY= -github.com/filecoin-project/go-state-types v0.14.0-dev h1:bDwq1S28D7EC/uDmKU8vvNcdFw/YDsNq09pe3zeV5h4= -github.com/filecoin-project/go-state-types v0.14.0-dev/go.mod h1:cHpOPup9H1g2T29dKHAjC2sc7/Ef5ypjuW9A3I+e9yY= +github.com/filecoin-project/go-state-types v0.14.0-rc5 h1:c8jo2mRx02u8smiCZsSDt1dsOGSu4gwfvHRqSKAl8Lc= +github.com/filecoin-project/go-state-types v0.14.0-rc5/go.mod h1:cHpOPup9H1g2T29dKHAjC2sc7/Ef5ypjuW9A3I+e9yY= github.com/filecoin-project/go-statemachine v1.0.3 h1:N07o6alys+V1tNoSTi4WuuoeNC4erS/6jE74+NsgQuk= github.com/filecoin-project/go-statemachine v1.0.3/go.mod h1:jZdXXiHa61n4NmgWFG4w8tnqgvZVHYbJ3yW7+y8bF54= github.com/filecoin-project/go-statestore v0.1.0/go.mod h1:LFc9hD+fRxPqiHiaqUEZOinUJB4WARkRfNl10O7kTnI= @@ -294,8 +298,8 @@ github.com/filecoin-project/go-statestore v0.2.0 h1:cRRO0aPLrxKQCZ2UOQbzFGn4WDNd github.com/filecoin-project/go-statestore v0.2.0/go.mod h1:8sjBYbS35HwPzct7iT4lIXjLlYyPor80aU7t7a/Kspo= github.com/filecoin-project/go-storedcounter v0.1.0 h1:Mui6wSUBC+cQGHbDUBcO7rfh5zQkWJM/CpAZa/uOuus= github.com/filecoin-project/go-storedcounter v0.1.0/go.mod h1:4ceukaXi4vFURIoxYMfKzaRF5Xv/Pinh2oTnoxpv+z8= -github.com/filecoin-project/lotus v1.27.1 h1:0Pfu1rGE8BL4ei9r37h8j1JWKCuCp0ZKOjf1u4It/Lo= -github.com/filecoin-project/lotus v1.27.1/go.mod h1:jZI5Wp7+OXouw3TsLp0CXLfWh+vAigNV0bcc8gbg7f4= +github.com/filecoin-project/lotus v1.28.0-rc5 h1:iYHriH32tyLixBIBaGb/UcpyacQbUCWnn5wGlMhPg9w= +github.com/filecoin-project/lotus v1.28.0-rc5/go.mod h1:VnrjAa0NAciJNwhTwOklGXoIP4sRndS892uPe+eT/qk= github.com/filecoin-project/pubsub v1.0.0 h1:ZTmT27U07e54qV1mMiQo4HDr0buo8I1LDHBYLXlsNXM= github.com/filecoin-project/pubsub v1.0.0/go.mod h1:GkpB33CcUtUNrLPhJgfdy4FDx4OMNR9k+46DHx/Lqrg= github.com/filecoin-project/specs-actors v0.9.13/go.mod h1:TS1AW/7LbG+615j4NsjMK1qlpAwaFsG9w0V2tg2gSao= @@ -741,6 +745,7 @@ github.com/joeshaw/multierror v0.0.0-20140124173710-69b34d4ec901/go.mod h1:Z86h9 github.com/jonboulle/clockwork v0.4.0 h1:p4Cf1aMWXnXAUh8lVfewRBx1zaTSYKrKMF2g3ST4RZ4= github.com/jonboulle/clockwork v0.4.0/go.mod h1:xgRqUGwRcjKCO1vbZUEtSLrqKoPSsUpK7fnezOII0kc= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= +github.com/jpillora/backoff v1.0.0 h1:uvFg412JmmHBHw7iwprIxkPMI+sGQ4kzOWsMeHnm2EA= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/jrick/logrotate v1.0.0 h1:lQ1bL/n9mBNeIXoTUoYRlK4dHuNJVofX9oWqBtPnSzI= github.com/jrick/logrotate v1.0.0/go.mod h1:LNinyqDIJnpAur+b8yyulnQw/wDuN1+BYKlTRt3OuAQ= @@ -807,8 +812,8 @@ github.com/libp2p/go-flow-metrics v0.1.0 h1:0iPhMI8PskQwzh57jB9WxIuIOQ0r+15PChFG github.com/libp2p/go-flow-metrics v0.1.0/go.mod h1:4Xi8MX8wj5aWNDAZttg6UPmc0ZrnFNsMtpsYUClFtro= github.com/libp2p/go-libp2p v0.1.0/go.mod h1:6D/2OBauqLUoqcADOJpn9WbKqvaM07tDw68qHM0BxUM= github.com/libp2p/go-libp2p v0.1.1/go.mod h1:I00BRo1UuUSdpuc8Q2mN7yDF/oTUTRAX6JWpTiK9Rp8= -github.com/libp2p/go-libp2p v0.34.1 h1:fxn9vyLo7vJcXQRNvdRbyPjbzuQgi2UiqC8hEbn8a18= -github.com/libp2p/go-libp2p v0.34.1/go.mod h1:snyJQix4ET6Tj+LeI0VPjjxTtdWpeOhYt5lEY0KirkQ= +github.com/libp2p/go-libp2p v0.35.0 h1:1xS1Bkr9X7GtdvV6ntLnDV9xB1kNjHK1lZ0eaO6gnhc= +github.com/libp2p/go-libp2p v0.35.0/go.mod h1:snyJQix4ET6Tj+LeI0VPjjxTtdWpeOhYt5lEY0KirkQ= github.com/libp2p/go-libp2p-asn-util v0.4.1 h1:xqL7++IKD9TBFMgnLPZR6/6iYhawHKHl950SO9L6n94= github.com/libp2p/go-libp2p-asn-util v0.4.1/go.mod h1:d/NI6XZ9qxw67b4e+NgpQexCIiFYJjErASrYW4PFDN8= github.com/libp2p/go-libp2p-autonat v0.1.0/go.mod h1:1tLf2yXxiE/oKGtDwPYWTSYG3PtvYlJmg7NeVtPRqH8= @@ -1338,8 +1343,8 @@ github.com/xorcare/golden v0.6.0/go.mod h1:7T39/ZMvaSEZlBPoYfVFmsBLmUl3uz9IuzWj/ github.com/xorcare/golden v0.6.1-0.20191112154924-b87f686d7542 h1:oWgZJmC1DorFZDpfMfWg7xk29yEOZiXmo/wZl+utTI8= github.com/xorcare/golden v0.6.1-0.20191112154924-b87f686d7542/go.mod h1:7T39/ZMvaSEZlBPoYfVFmsBLmUl3uz9IuzWj/U6FtvQ= github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= -github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRTfdpNzjtPYqr8smhKouy9mxVdGPU= -github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8= +github.com/xrash/smetrics v0.0.0-20240312152122-5f08fbb34913 h1:+qGGcbkzsfDQNPPe9UDgpxAWQrhbbBXOYJFQDq/dtJw= +github.com/xrash/smetrics v0.0.0-20240312152122-5f08fbb34913/go.mod h1:4aEEwZQutDLsQv2Deui4iYQ6DWTxR14g6m8Wv88+Xqk= github.com/yugabyte/pgx/v5 v5.5.3-yb-2 h1:SDk2waZb2o6dSLYqk+vq0Ur2jnIv+X2A+P+QPR1UThU= github.com/yugabyte/pgx/v5 v5.5.3-yb-2/go.mod h1:2SxizGfDY7UDCRTtbI/xd98C/oGN7S/3YoGF8l9gx/c= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= diff --git a/tasks/fevm/contract/task.go b/tasks/fevm/contract/task.go index 10455575..da0d8ef2 100644 --- a/tasks/fevm/contract/task.go +++ b/tasks/fevm/contract/task.go @@ -60,11 +60,11 @@ func (p *Task) ProcessTipSets(ctx context.Context, current *types.TipSet, execut errs := []error{} for _, change := range actorChanges { actor := change.Actor - if actor.Address == nil { + if actor.DelegatedAddress == nil { continue } - if !util.IsEVMAddress(ctx, p.node, *actor.Address, current.Key()) { + if !util.IsEVMAddress(ctx, p.node, *actor.DelegatedAddress, current.Key()) { continue } @@ -75,7 +75,7 @@ func (p *Task) ProcessTipSets(ctx context.Context, current *types.TipSet, execut continue } - ethAddress, err := ethtypes.EthAddressFromFilecoinAddress(*actor.Address) + ethAddress, err := ethtypes.EthAddressFromFilecoinAddress(*actor.DelegatedAddress) if err != nil { log.Errorf("Error at getting eth address: [actor cid: %v] err: %v", actor.Code.String(), err) errs = append(errs, err) @@ -98,7 +98,7 @@ func (p *Task) ProcessTipSets(ctx context.Context, current *types.TipSet, execut out = append(out, &fevm.FEVMContract{ Height: int64(current.Height()), - ActorID: actor.Address.String(), + ActorID: actor.DelegatedAddress.String(), EthAddress: ethAddress.String(), ByteCode: hex.EncodeToString(byteCode), ByteCodeHash: hex.EncodeToString(byteCodeHash[:]), diff --git a/tasks/fevm/trace/task.go b/tasks/fevm/trace/task.go index 32f348a0..90a334a9 100644 --- a/tasks/fevm/trace/task.go +++ b/tasks/fevm/trace/task.go @@ -57,8 +57,8 @@ func getEthAddress(addr address.Address) string { func (t *Task) getActorAddress(ctx context.Context, address address.Address, tsk types.TipSetKey) address.Address { actor, err := t.node.Actor(ctx, address, tsk) - if err == nil && actor != nil && actor.Address != nil { - return *actor.Address + if err == nil && actor != nil && actor.DelegatedAddress != nil { + return *actor.DelegatedAddress } return address } diff --git a/tasks/fevm/transaction/tasks.go b/tasks/fevm/transaction/tasks.go index 73adddd3..bda5d063 100644 --- a/tasks/fevm/transaction/tasks.go +++ b/tasks/fevm/transaction/tasks.go @@ -89,23 +89,32 @@ func (p *Task) ProcessTipSets(ctx context.Context, current *types.TipSet, execut } txnObj := &fevm.FEVMTransaction{ - Height: int64(current.Height()), - Hash: txn.Hash.String(), - ChainID: uint64(txn.ChainID), - Nonce: uint64(txn.Nonce), - From: txn.From.String(), - Value: txn.Value.Int.String(), - Type: uint64(txn.Type), - Input: txn.Input.String(), - Gas: uint64(txn.Gas), - MaxFeePerGas: txn.MaxFeePerGas.Int.String(), - MaxPriorityFeePerGas: txn.MaxPriorityFeePerGas.Int.String(), - V: txn.V.String(), - R: txn.R.String(), - S: txn.S.String(), - FromFilecoinAddress: fromActorInfo.Actor.Address.String(), - FromActorName: fromActorInfo.ActorName, - MessageCid: message.Cid.String(), + Height: int64(current.Height()), + Hash: txn.Hash.String(), + ChainID: uint64(txn.ChainID), + Nonce: uint64(txn.Nonce), + From: txn.From.String(), + Value: txn.Value.Int.String(), + Type: uint64(txn.Type), + Input: txn.Input.String(), + Gas: uint64(txn.Gas), + V: txn.V.String(), + R: txn.R.String(), + S: txn.S.String(), + FromActorName: fromActorInfo.ActorName, + MessageCid: message.Cid.String(), + } + + if fromActorInfo.Actor.DelegatedAddress != nil { + txnObj.FromFilecoinAddress = fromActorInfo.Actor.DelegatedAddress.String() + } + + if txn.MaxFeePerGas != nil { + txnObj.MaxFeePerGas = txn.MaxFeePerGas.Int.String() + } + + if txn.MaxPriorityFeePerGas != nil { + txnObj.MaxPriorityFeePerGas = txn.MaxPriorityFeePerGas.Int.String() } if txn.BlockHash != nil { @@ -124,9 +133,9 @@ func (p *Task) ProcessTipSets(ctx context.Context, current *types.TipSet, execut // Get the Actor from ActorInfo toActorInfo, err := p.node.ActorInfo(ctx, message.Message.To, current.Key()) - if err == nil && toActorInfo.Actor != nil && toActorInfo.Actor.Address != nil { + if err == nil && toActorInfo.Actor != nil && toActorInfo.Actor.DelegatedAddress != nil { txnObj.ToActorName = toActorInfo.ActorName - txnObj.ToFilecoinAddress = toActorInfo.Actor.Address.String() + txnObj.ToFilecoinAddress = toActorInfo.Actor.DelegatedAddress.String() } } diff --git a/tasks/periodic_actor_dump/fevm_actor/tasks.go b/tasks/periodic_actor_dump/fevm_actor/tasks.go index 75f65091..c13db46f 100644 --- a/tasks/periodic_actor_dump/fevm_actor/tasks.go +++ b/tasks/periodic_actor_dump/fevm_actor/tasks.go @@ -54,7 +54,7 @@ func (p *Task) ProcessPeriodicActorDump(ctx context.Context, current *types.TipS out := make(actordumps.FEVMActorDumpList, 0) errs := []error{} for _, actor := range actors[manifest.EvmKey] { - if actor.Address == nil { + if actor.DelegatedAddress == nil { continue } @@ -65,7 +65,7 @@ func (p *Task) ProcessPeriodicActorDump(ctx context.Context, current *types.TipS continue } - ethAddress, err := ethtypes.EthAddressFromFilecoinAddress(*actor.Address) + ethAddress, err := ethtypes.EthAddressFromFilecoinAddress(*actor.DelegatedAddress) if err != nil { log.Errorf("Error at getting eth address: [actor cid: %v] err: %v", actor.Code.String(), err) errs = append(errs, err) @@ -87,7 +87,7 @@ func (p *Task) ProcessPeriodicActorDump(ctx context.Context, current *types.TipS } out = append(out, &actordumps.FEVMActorDump{ Height: int64(current.Height()), - ActorID: actor.Address.String(), + ActorID: actor.DelegatedAddress.String(), ActorName: builtin.ActorNameByCode(actor.Code), EthAddress: ethAddress.String(), ByteCode: hex.EncodeToString(byteCode), @@ -99,7 +99,7 @@ func (p *Task) ProcessPeriodicActorDump(ctx context.Context, current *types.TipS } for _, actor := range append(actors[manifest.EthAccountKey], actors[manifest.PlaceholderKey]...) { - ethAddress, err := ethtypes.EthAddressFromFilecoinAddress(*actor.Address) + ethAddress, err := ethtypes.EthAddressFromFilecoinAddress(*actor.DelegatedAddress) if err != nil { log.Errorf("Error at getting eth address: [actor cid: %v] err: %v", actor.Code.String(), err) errs = append(errs, err) @@ -107,7 +107,7 @@ func (p *Task) ProcessPeriodicActorDump(ctx context.Context, current *types.TipS } out = append(out, &actordumps.FEVMActorDump{ Height: int64(current.Height()), - ActorID: actor.Address.String(), + ActorID: actor.DelegatedAddress.String(), ActorName: builtin.ActorNameByCode(actor.Code), EthAddress: ethAddress.String(), Balance: actor.Balance.String(), diff --git a/tasks/periodic_actor_dump/miner_actor/tasks.go b/tasks/periodic_actor_dump/miner_actor/tasks.go index 5d373ab4..2dc15588 100644 --- a/tasks/periodic_actor_dump/miner_actor/tasks.go +++ b/tasks/periodic_actor_dump/miner_actor/tasks.go @@ -42,7 +42,7 @@ func (p *Task) updateAddressFromID(ctx context.Context, current *types.TipSet, m if err != nil { return err } - minerDumpObj.OwnerAddress = ownerActor.Actor.Address.String() + minerDumpObj.OwnerAddress = ownerActor.Actor.DelegatedAddress.String() // Worker Address workerAddr, err := address.NewFromString(minerDumpObj.WorkerID) @@ -53,7 +53,7 @@ func (p *Task) updateAddressFromID(ctx context.Context, current *types.TipSet, m if err != nil { return err } - minerDumpObj.WorkerAddress = workerActor.Actor.Address.String() + minerDumpObj.WorkerAddress = workerActor.Actor.DelegatedAddress.String() // Beneficiary Address beneficiaryAddr, err := address.NewFromString(minerDumpObj.Beneficiary) @@ -64,7 +64,7 @@ func (p *Task) updateAddressFromID(ctx context.Context, current *types.TipSet, m if err != nil { return err } - minerDumpObj.BeneficiaryAddress = beneficiaryWorkerActor.Actor.Address.String() + minerDumpObj.BeneficiaryAddress = beneficiaryWorkerActor.Actor.DelegatedAddress.String() return nil } @@ -111,7 +111,7 @@ func (p *Task) ProcessPeriodicActorDump(ctx context.Context, current *types.TipS if err != nil { return err } - minerDumpObj.MinerAddress = minerActor.Actor.Address.String() + minerDumpObj.MinerAddress = minerActor.Actor.DelegatedAddress.String() minerState, err := builtinminer.Load(p.node.Store(), minerActor.Actor) if err != nil { From aecce5924273ebbb859b8b7d94558685298916b5 Mon Sep 17 00:00:00 2001 From: "terry.hung" Date: Sat, 13 Jul 2024 01:04:13 +0800 Subject: [PATCH 2/3] update go.sum --- go.sum | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go.sum b/go.sum index 1a0e79ad..f1b2cc5f 100644 --- a/go.sum +++ b/go.sum @@ -288,7 +288,7 @@ github.com/filecoin-project/go-state-types v0.0.0-20201102161440-c8033295a1fc/go github.com/filecoin-project/go-state-types v0.1.0/go.mod h1:ezYnPf0bNkTsDibL/psSz5dy4B5awOJ/E7P2Saeep8g= github.com/filecoin-project/go-state-types v0.1.6/go.mod h1:UwGVoMsULoCK+bWjEdd/xLCvLAQFBC7EDT477SKml+Q= github.com/filecoin-project/go-state-types v0.1.10/go.mod h1:UwGVoMsULoCK+bWjEdd/xLCvLAQFBC7EDT477SKml+Q= -github.com/filecoin-project/go-state-types v0.13.1/go.mod h1:cHpOPup9H1g2T29dKHAjC2sc7/Ef5ypjuW9A3I+e9yY= +github.com/filecoin-project/go-state-types v0.14.0-rc1/go.mod h1:cHpOPup9H1g2T29dKHAjC2sc7/Ef5ypjuW9A3I+e9yY= github.com/filecoin-project/go-state-types v0.14.0-rc5 h1:c8jo2mRx02u8smiCZsSDt1dsOGSu4gwfvHRqSKAl8Lc= github.com/filecoin-project/go-state-types v0.14.0-rc5/go.mod h1:cHpOPup9H1g2T29dKHAjC2sc7/Ef5ypjuW9A3I+e9yY= github.com/filecoin-project/go-statemachine v1.0.3 h1:N07o6alys+V1tNoSTi4WuuoeNC4erS/6jE74+NsgQuk= From bfaadb90cb186fe18cb4977506c6ad4fbcbf4777 Mon Sep 17 00:00:00 2001 From: "terry.hung" Date: Sat, 13 Jul 2024 01:33:57 +0800 Subject: [PATCH 3/3] chore: run actors-gen --- tasks/actorstate/datacap/balance.go | 2 +- tasks/chaineconomics/economics.go | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/tasks/actorstate/datacap/balance.go b/tasks/actorstate/datacap/balance.go index 611b7a85..6d38fcff 100644 --- a/tasks/actorstate/datacap/balance.go +++ b/tasks/actorstate/datacap/balance.go @@ -15,9 +15,9 @@ import ( "github.com/filecoin-project/lily/model" datacapmodel "github.com/filecoin-project/lily/model/actors/datacap" "github.com/filecoin-project/lily/tasks/actorstate" + "github.com/filecoin-project/specs-actors/actors/builtin" "github.com/filecoin-project/lotus/chain/types" - "github.com/filecoin-project/specs-actors/actors/builtin" ) var log = logging.Logger("lily/tasks/datacap") diff --git a/tasks/chaineconomics/economics.go b/tasks/chaineconomics/economics.go index ddff3284..16cfce37 100644 --- a/tasks/chaineconomics/economics.go +++ b/tasks/chaineconomics/economics.go @@ -9,13 +9,12 @@ import ( "go.opentelemetry.io/otel/attribute" "github.com/filecoin-project/go-address" + actorstypes "github.com/filecoin-project/go-state-types/actors" "github.com/filecoin-project/lily/chain/actors/adt" "github.com/filecoin-project/lily/chain/actors/builtin/miner" "github.com/filecoin-project/lily/model" chainmodel "github.com/filecoin-project/lily/model/chain" - actorstypes "github.com/filecoin-project/go-state-types/actors" - "github.com/filecoin-project/lotus/api" "github.com/filecoin-project/lotus/chain/types" )