Fix lotus-soup build

This commit is contained in:
Łukasz Magiera 2021-03-25 15:26:30 +01:00
parent 736c69784a
commit 9223a8e5ff
2 changed files with 5 additions and 7 deletions

View File

@ -10,7 +10,6 @@ import (
"github.com/filecoin-project/go-jsonrpc"
"github.com/filecoin-project/go-jsonrpc/auth"
"github.com/filecoin-project/lotus/api"
"github.com/filecoin-project/lotus/api/apistruct"
"github.com/filecoin-project/lotus/chain/types"
"github.com/filecoin-project/lotus/chain/wallet"
"github.com/filecoin-project/lotus/node"
@ -157,11 +156,11 @@ func (c *LotusClient) RunDefault() error {
return nil
}
func startFullNodeAPIServer(t *TestEnvironment, repo repo.Repo, api api.FullNode) (*http.Server, error) {
func startFullNodeAPIServer(t *TestEnvironment, repo repo.Repo, napi api.FullNode) (*http.Server, error) {
mux := mux.NewRouter()
rpcServer := jsonrpc.NewServer()
rpcServer.Register("Filecoin", api)
rpcServer.Register("Filecoin", napi)
mux.Handle("/rpc/v0", rpcServer)
@ -176,7 +175,7 @@ func startFullNodeAPIServer(t *TestEnvironment, repo repo.Repo, api api.FullNode
ah := &auth.Handler{
Verify: func(ctx context.Context, token string) ([]auth.Permission, error) {
return apistruct.AllPermissions, nil
return api.AllPermissions, nil
},
Next: mux.ServeHTTP,
}

View File

@ -17,7 +17,6 @@ import (
"github.com/filecoin-project/go-state-types/abi"
"github.com/filecoin-project/go-storedcounter"
"github.com/filecoin-project/lotus/api"
"github.com/filecoin-project/lotus/api/apistruct"
"github.com/filecoin-project/lotus/build"
"github.com/filecoin-project/lotus/chain/actors"
genesis_chain "github.com/filecoin-project/lotus/chain/gen/genesis"
@ -321,7 +320,7 @@ func PrepareMiner(t *TestEnvironment) (*LotusMiner, error) {
}
// print out the admin auth token
token, err := n.MinerApi.AuthNew(ctx, apistruct.AllPermissions)
token, err := n.MinerApi.AuthNew(ctx, api.AllPermissions)
if err != nil {
return nil, err
}
@ -615,7 +614,7 @@ func startStorageMinerAPIServer(t *TestEnvironment, repo repo.Repo, minerApi api
ah := &auth.Handler{
Verify: func(ctx context.Context, token string) ([]auth.Permission, error) {
return apistruct.AllPermissions, nil
return api.AllPermissions, nil
},
Next: mux.ServeHTTP,
}