introduce v9 actors and nv17
This commit is contained in:
@@ -10,6 +10,8 @@ import (
|
||||
"github.com/ipld/go-car"
|
||||
"golang.org/x/xerrors"
|
||||
|
||||
actorstypes "github.com/filecoin-project/go-state-types/actors"
|
||||
|
||||
"github.com/filecoin-project/lotus/blockstore"
|
||||
"github.com/filecoin-project/lotus/build"
|
||||
"github.com/filecoin-project/lotus/chain/actors"
|
||||
@@ -39,10 +41,10 @@ func LoadBundle(ctx context.Context, bs blockstore.Blockstore, r io.Reader) (cid
|
||||
|
||||
// LoadBundles loads the bundles for the specified actor versions into the passed blockstore, if and
|
||||
// only if the bundle's manifest is not already present in the blockstore.
|
||||
func LoadBundles(ctx context.Context, bs blockstore.Blockstore, versions ...actors.Version) error {
|
||||
func LoadBundles(ctx context.Context, bs blockstore.Blockstore, versions ...actorstypes.Version) error {
|
||||
for _, av := range versions {
|
||||
// No bundles before version 8.
|
||||
if av < actors.Version8 {
|
||||
if av < actorstypes.Version8 {
|
||||
continue
|
||||
}
|
||||
|
||||
|
||||
@@ -94,7 +94,7 @@ func run() error {
|
||||
package config
|
||||
|
||||
type DocField struct {
|
||||
Name string
|
||||
Num string
|
||||
Type string
|
||||
Comment string
|
||||
}
|
||||
@@ -109,7 +109,7 @@ var Doc = map[string][]DocField{
|
||||
|
||||
for _, f := range typ {
|
||||
fmt.Println("\t\t{")
|
||||
fmt.Printf("\t\t\tName: \"%s\",\n", f.Name)
|
||||
fmt.Printf("\t\t\tNum: \"%s\",\n", f.Name)
|
||||
fmt.Printf("\t\t\tType: \"%s\",\n\n", f.Type)
|
||||
fmt.Printf("\t\t\tComment: `%s`,\n", f.Comment)
|
||||
fmt.Println("\t\t},")
|
||||
|
||||
@@ -8,11 +8,10 @@ import (
|
||||
"math"
|
||||
"sort"
|
||||
|
||||
abi "github.com/filecoin-project/go-state-types/abi"
|
||||
cid "github.com/ipfs/go-cid"
|
||||
cbg "github.com/whyrusleeping/cbor-gen"
|
||||
xerrors "golang.org/x/xerrors"
|
||||
|
||||
abi "github.com/filecoin-project/go-state-types/abi"
|
||||
)
|
||||
|
||||
var _ = xerrors.Errorf
|
||||
|
||||
@@ -8,6 +8,7 @@ import (
|
||||
|
||||
"github.com/filecoin-project/go-address"
|
||||
"github.com/filecoin-project/go-state-types/abi"
|
||||
actorstypes "github.com/filecoin-project/go-state-types/actors"
|
||||
"github.com/filecoin-project/go-state-types/big"
|
||||
multisig2 "github.com/filecoin-project/specs-actors/v2/actors/builtin/multisig"
|
||||
|
||||
@@ -29,7 +30,7 @@ func (a *MsigAPI) messageBuilder(ctx context.Context, from address.Address) (mul
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
av, err := actors.VersionForNetwork(nver)
|
||||
av, err := actorstypes.VersionForNetwork(nver)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
@@ -16,8 +16,9 @@ import (
|
||||
"github.com/filecoin-project/go-address"
|
||||
"github.com/filecoin-project/go-bitfield"
|
||||
"github.com/filecoin-project/go-state-types/abi"
|
||||
actorstypes "github.com/filecoin-project/go-state-types/actors"
|
||||
"github.com/filecoin-project/go-state-types/big"
|
||||
minertypes "github.com/filecoin-project/go-state-types/builtin/v8/miner"
|
||||
minertypes "github.com/filecoin-project/go-state-types/builtin/v9/miner"
|
||||
"github.com/filecoin-project/go-state-types/cbor"
|
||||
"github.com/filecoin-project/go-state-types/crypto"
|
||||
"github.com/filecoin-project/go-state-types/dline"
|
||||
@@ -1536,7 +1537,7 @@ func (m *StateModule) StateNetworkVersion(ctx context.Context, tsk types.TipSetK
|
||||
}
|
||||
|
||||
func (a *StateAPI) StateActorCodeCIDs(ctx context.Context, nv network.Version) (map[string]cid.Cid, error) {
|
||||
actorVersion, err := actors.VersionForNetwork(nv)
|
||||
actorVersion, err := actorstypes.VersionForNetwork(nv)
|
||||
if err != nil {
|
||||
return nil, xerrors.Errorf("invalid network version %d: %w", nv, err)
|
||||
}
|
||||
@@ -1550,7 +1551,7 @@ func (a *StateAPI) StateActorCodeCIDs(ctx context.Context, nv network.Version) (
|
||||
}
|
||||
|
||||
func (a *StateAPI) StateActorManifestCID(ctx context.Context, nv network.Version) (cid.Cid, error) {
|
||||
actorVersion, err := actors.VersionForNetwork(nv)
|
||||
actorVersion, err := actorstypes.VersionForNetwork(nv)
|
||||
if err != nil {
|
||||
return cid.Undef, xerrors.Errorf("invalid network version")
|
||||
}
|
||||
|
||||
@@ -35,7 +35,7 @@ import (
|
||||
"github.com/filecoin-project/go-state-types/abi"
|
||||
"github.com/filecoin-project/go-state-types/big"
|
||||
builtintypes "github.com/filecoin-project/go-state-types/builtin"
|
||||
minertypes "github.com/filecoin-project/go-state-types/builtin/v8/miner"
|
||||
minertypes "github.com/filecoin-project/go-state-types/builtin/v9/miner"
|
||||
"github.com/filecoin-project/go-state-types/network"
|
||||
|
||||
"github.com/filecoin-project/lotus/api"
|
||||
|
||||
Reference in New Issue
Block a user