upgrading to upstream v1.28.0-rc1

This commit is contained in:
jonathan@vulcanize.io 2024-07-01 18:48:08 +00:00
commit edcf412c1a
86 changed files with 3625 additions and 2148 deletions

View File

@ -22,13 +22,13 @@ permissions:
pull-requests: write
concurrency:
group: ${{ github.workflow }}-${{ github.event.inputs.pull_number || github.event.workflow_run.pull_requests[0].number }}
cancel-in-progress: true
group: ${{ github.workflow }}-${{ github.event.inputs.pull_number }}-${{ github.event.workflow_run.head_repository.full_name }}-${{ github.event.workflow_run.head_branch }}
cancel-in-progress: false
jobs:
comment:
if: github.event.inputs.pull_number || github.event.workflow_run.event == 'pull_request'
uses: ipdxco/sorted-pr-checks/.github/workflows/comment.yml@v1
uses: ipdxco/sorted-pr-checks/.github/workflows/comment.yml@v2
with:
pull_number: ${{ github.event.inputs.pull_number || github.event.workflow_run.pull_requests[0].number }}
pull_number: ${{ github.event.inputs.pull_number }}
template: unsuccessful_only

View File

@ -61,9 +61,10 @@ jobs:
# to support resource intensive jobs.
runners: |
{
"itest-deals_concurrent": ["self-hosted", "linux", "x64", "4xlarge"],
"itest-niporep_manual": ["self-hosted", "linux", "x64", "4xlarge"],
"itest-sector_pledge": ["self-hosted", "linux", "x64", "4xlarge"],
"itest-worker": ["self-hosted", "linux", "x64", "4xlarge"],
"itest-manual_onboarding": ["self-hosted", "linux", "x64", "4xlarge"],
"itest-gateway": ["self-hosted", "linux", "x64", "2xlarge"],
"itest-sector_import_full": ["self-hosted", "linux", "x64", "2xlarge"],
@ -71,15 +72,8 @@ jobs:
"itest-wdpost": ["self-hosted", "linux", "x64", "2xlarge"],
"unit-storage": ["self-hosted", "linux", "x64", "2xlarge"],
"itest-batch_deal": ["self-hosted", "linux", "x64", "xlarge"],
"itest-cli": ["self-hosted", "linux", "x64", "xlarge"],
"itest-deals_512mb": ["self-hosted", "linux", "x64", "xlarge"],
"itest-deals_anycid": ["self-hosted", "linux", "x64", "xlarge"],
"itest-deals_invalid_utf8_label": ["self-hosted", "linux", "x64", "xlarge"],
"itest-deals_max_staging_deals": ["self-hosted", "linux", "x64", "xlarge"],
"itest-deals_partial_retrieval": ["self-hosted", "linux", "x64", "xlarge"],
"itest-deals_publish": ["self-hosted", "linux", "x64", "xlarge"],
"itest-deals_remote_retrieval": ["self-hosted", "linux", "x64", "xlarge"],
"itest-decode_params": ["self-hosted", "linux", "x64", "xlarge"],
"itest-dup_mpool_messages": ["self-hosted", "linux", "x64", "xlarge"],
"itest-eth_account_abstraction": ["self-hosted", "linux", "x64", "xlarge"],
@ -97,7 +91,6 @@ jobs:
"itest-get_messages_in_ts": ["self-hosted", "linux", "x64", "xlarge"],
"itest-lite_migration": ["self-hosted", "linux", "x64", "xlarge"],
"itest-lookup_robust_address": ["self-hosted", "linux", "x64", "xlarge"],
"itest-manual_onboarding": ["self-hosted", "linux", "x64", "xlarge"],
"itest-mempool": ["self-hosted", "linux", "x64", "xlarge"],
"itest-mpool_msg_uuid": ["self-hosted", "linux", "x64", "xlarge"],
"itest-mpool_push_with_uuid": ["self-hosted", "linux", "x64", "xlarge"],
@ -123,19 +116,13 @@ jobs:
[
"conformance",
"itest-api",
"itest-deals_offline",
"itest-deals_padding",
"itest-deals_partial_retrieval_dm-level",
"itest-deals_pricing",
"itest-deals",
"itest-direct_data_onboard_verified",
"itest-direct_data_onboard",
"itest-manual_onboarding",
"itest-niporep_manual",
"itest-net",
"itest-path_detach_redeclare",
"itest-path_type_filters",
"itest-sealing_resources",
"itest-sector_finalize_early",
"itest-sector_import_full",
"itest-sector_import_simple",
"itest-sector_pledge",
@ -143,12 +130,10 @@ jobs:
"itest-wdpost_no_miner_storage",
"itest-wdpost_worker_config",
"itest-wdpost",
"itest-worker_upgrade",
"itest-worker",
"multicore-sdr",
"unit-cli",
"unit-storage",
"itest-curio"
"unit-storage"
]
run: |
# Create a list of integration test groups
@ -252,7 +237,7 @@ jobs:
test:
needs: [discover, cache]
name: Test (${{ matrix.name }})
runs-on: ${{ github.repository == 'filecoin-project/lotus' && matrix.runner || 'ubuntu-latest' }}
runs-on: ${{ github.repository_owner == 'filecoin-project' && matrix.runner || 'ubuntu-latest' }}
strategy:
fail-fast: false
matrix:

1
.gitignore vendored
View File

@ -7,7 +7,6 @@
/lotus-chainwatch
/lotus-shed
/lotus-sim
/curio
/sptool
/lotus-townhall
/lotus-fountain

View File

@ -2,10 +2,86 @@
# UNRELEASED
## ☢️ Upgrade Warnings ☢️
- This Lotus release includes some correctness improvements to the events subsystem, impacting RPC APIs including `GetActorEventsRaw`, `SubscribeActorEventsRaw`, `eth_getLogs` and the `eth` filter APIs. Part of these improvements involve an events database migration that may take some time to complete on nodes with extensive event databases. See [filecoin-project/lotus#12080](https://github.com/filecoin-project/lotus/pull/12080) for details.
## New features
- feat: Add trace transaction API supporting RPC method `trace_transaction` ([filecoin-project/lotus#12068](https://github.com/filecoin-project/lotus/pull/12068))
## Improvements
# v1.28.0-rc1 / 2024-07-01
This is the first release candidate of the upcoming MANDATORY Lotus v1.28.0 release, which will deliver the Filecoin network version 23, codenamed Waffle 🧇.
**This release canidate does NOT set a calibration network upgrade epoch, it will be added in the second release candidate, expected to be released July 4th. This release candidate does NOT set the mainnet upgrade epoch yet, which will be updated in the final release.**
☢️ Upgrade Warnings ☢️
If you are running the `v1.26.0` or an earlier version of Lotus, please go through the `Upgrade Warnings` section for the `v1.27.*` releases, before upgrading to this RC.
## The Filecoin network version 23 delivers the following FIPs:
- [FIP-0065: Ignore built-in market locked balance in circulating supply calculation](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0065.md)
- [FIP-0079: Add BLS Aggregate Signatures to FVM](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0079.md)
- [FIP-0084: Remove Storage Miner Actor Method ProveCommitSectors](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0084.md)
- [FIP-0085: Convert f090 Mining Reserve Actor to Keyless Account Actor](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0085.md)
- [FIP-0091: Add support for legacy Ethereum transactions](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0091.md)
- [FIP-0092: NI-PoRep](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0092.md)
- [FIP-0086: Fast Finality Soft Launch](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0086.md)
Note that we are only doing a "soft launch"/"passive testing" for F3 (Fast Finality) i.e. FIP-0086 in NV23. Please see [this doc](https://docs.google.com/document/d/14hMFN95_AsByBh7iMc4r_czUgg8tfjHQ1gTsmmHZ8jI/edit#heading=h.dhzqs3lisv24) for more details.
## v14 Builtin Actor Bundle
The actor bundles for the **calibration network** can be checked as follows:
```
lotus state actor-cids --network-version=23
Network Version: 23
Actor Version: 14
Manifest CID: bafy2bzacebq3hncszqpojglh2dkwekybq4zn6qpc4gceqbx36wndps5qehtau
Actor CID
account bafk2bzaced5ecfm56dvtw26q56j4d32yoccyd7ggxn3qdki2enxpqqav45ths
cron bafk2bzacedpbtttpyvtjncqoyobr63mhqqtlrygbnudhxyp2vha56f626dkfs
datacap bafk2bzacecded3lcvo7ndsk66samyecw2trnhrgzi7jxsary3sqgopxlk6rku
eam bafk2bzacecsda4uw7dcu76a27gnrrdcm73tgms7wrte6jbou63vloktkqc5ne
ethaccount bafk2bzacebu2lcxfmohomjj3umslnylwugf5gssywdq3575tjarta7o227dls
evm bafk2bzacea4xnekruhfmdnzvzeo6cbf7jsfgco6x5wje2ckwc2ui2ojzcrlgu
init bafk2bzacedfmsdlewihdcrkdepnfata26nj7akbvexzs3chicujhjf2uxsazc
multisig bafk2bzacedwx4svscsp6wqqu2vlcunjihvvm4u2jnsqjkwutjhir7dwtl7z6m
paymentchannel bafk2bzacedbit7oo6lryhbo64uikvtjtfcth6oxwy3eebxerenu2h7rj44n24
placeholder bafk2bzacedfvut2myeleyq67fljcrw4kkmn5pb5dpyozovj7jpoez5irnc3ro
reward bafk2bzaced5rlycj7fzpscfc7p3wwxarngwqylqshj7te3uffey5tevunz4we
storagemarket bafk2bzaceatwbyrec2nnwggxc2alpqve7rl52fmbhqflebuxmmnvg3qckjb7c
storageminer bafk2bzacecr7ozkdz7l2pq3ig5qxae2ysivbnojhsn4gw3o57ov4mhksma7me
storagepower bafk2bzacedgeolvjtnw7fkji5kqmx322abv6uls2v34fuml6nw36dvfcw4mtu
system bafk2bzacederl6tlpieldsn6mkndqwd4wj5orfoqgab6p2klswfn3cjagxwla
verifiedregistry bafk2bzaceczw2kp6gjjdcjbso7mewp7guik7gr525pal6dotdja2lrct6ok3c
```
## Migration
The NV23 upgrade migration is expected to be extremely light as only FIP-0085 requires a migration. We don't expect null tipsets after the upgrade epoch or heavy block validation times. We will updated this sections once we have run the final benchmarks.
## Dependencies
- github.com/filecoin-project/go-state-types (`v0.14.0-dev` -> `v0.14.0-rc5`)
- github.com/filecoin-project/filecoin-ffi (`v1.27.0-rc2` -> `v1.28.0-rc2`)
- `ref-fvm4` (as part of `filecoin-ffi`) (`4.2.0` -> `4.3.1`)
- A new `github.com/filecoin-project/go-f3` dependency for F3 soft launch (`v0.0.2`)
## Others
- Soft launch of F3 (https://github.com/filecoin-project/lotus/pull/12119)
- NI-PoRep changes (https://github.com/filecoin-project/lotus/pull/12130)
- Fixes for the ETH events API (https://github.com/filecoin-project/lotus/pull/12080)
- Support for legacy Ethereum transactions (https://github.com/filecoin-project/lotus/pull/11969)
- Ignore market balance after nv23 (https://github.com/filecoin-project/lotus/pull/11976)
- Add finality-related params for `eth_getBlockByNumber` (https://github.com/filecoin-project/lotus/pull/12110)
- rename `Actor.Address` to `Actor.DelegatedAddress` and only use it for f4 addresses (https://github.com/filecoin-project/lotus/pull/12155)
# v1.27.1 / 2024-06-24
This release, v1.27.1, is an OPTIONAL lotus release. It is HIGHLY RECOMMENDED for node operators that are building Filecoin index off lotus!
@ -1325,7 +1401,7 @@ Please read carefully through the **upgrade warnings** section if you are upgrad
- Starting from this release, the SplitStore feature is automatically activated on new nodes. However, for existing Lotus users, you need to explicitly configure SplitStore by uncommenting the `EnableSplitstore` option in your `config.toml` file. To enable SplitStore, set `EnableSplitstore=true`, and to disable it, set `EnableSplitstore=false`. **It's important to note that your Lotus node will not start unless this configuration is properly set. Set it to false if you are running a full archival node!**
- This feature release requires a **minimum Go version of v1.19.7 or higher to successfully build Lotus**. Additionally, Go version v1.20 and higher is now also supported.
- **Storage Providers:** The proofs libraries now have CUDA enabled by default, which requires you to install (CUDA)[https://lotus.filecoin.io/tutorials/lotus-miner/cuda/] if you haven't already done so. If you prefer to use OpenCL on your GPUs instead, you can use the `FFI_USE_OPENCL=1` flag when building from source. On the other hand, if you want to disable GPUs altogether, you can use the `FFI_NO_GPU=1` environment variable when building from source.
- **Storage Providers:** The proofs libraries now have CUDA enabled by default, which requires you to install [CUDA](https://lotus.filecoin.io/tutorials/lotus-miner/cuda/) if you haven't already done so. If you prefer to use OpenCL on your GPUs instead, you can use the `FFI_USE_OPENCL=1` flag when building from source. On the other hand, if you want to disable GPUs altogether, you can use the `FFI_NO_GPU=1` environment variable when building from source.
- **Storage Providers:** The `lotus-miner sectors extend` command has been refactored to the functionality of `lotus-miner sectors renew`.
- **Exchanges/Node operators/RPC-providers::** Execution traces (returned from `lotus state exec-trace`, `lotus state replay`, etc.), has changed to account for changes introduced by the by the FVM. **Please make sure to read the `Execution trace format change` section carefully, as these are interface breaking changes**
- **Syncing issues:** If you have been struggling with syncing issues in normal operations you can try to adjust the amount of threads used for more concurrent FMV execution through via the `LOTUS_FVM_CONCURRENCY` enviroment variable. It is set to 4 threads by default. Recommended formula for concurrency == YOUR_RAM/4 , but max during a network upgrade is 24. If you are a Storage Provider and are pushing many messages within a short period of time, exporting `LOTUS_SKIP_APPLY_TS_MESSAGE_CALL_WITH_GAS=1` will also help with keeping in sync.

View File

@ -7,7 +7,6 @@
<h1 align="center">Project Lotus - 莲</h1>
<p align="center">
![example workflow](https://github.com/github/docs/actions/workflows/main.yml/badge.svg)
<a href="https://github.com/filecoin-project/lotus/actions/workflows/build.yml"><img src="https://github.com/filecoin-project/lotus/actions/workflows/build.yml/badge.svg"></a>
<a href="https://github.com/filecoin-project/lotus/actions/workflows/check.yml"><img src="https://github.com/filecoin-project/lotus/actions/workflows/check.yml/badge.svg"></a>
<a href="https://github.com/filecoin-project/lotus/actions/workflows/test.yml"><img src="https://github.com/filecoin-project/lotus/actions/workflows/test.yml/badge.svg"></a>

View File

@ -11,6 +11,7 @@ import (
"github.com/filecoin-project/go-address"
"github.com/filecoin-project/go-bitfield"
"github.com/filecoin-project/go-f3/certs"
"github.com/filecoin-project/go-jsonrpc"
"github.com/filecoin-project/go-state-types/abi"
"github.com/filecoin-project/go-state-types/big"
@ -859,6 +860,18 @@ type FullNode interface {
// Note: this API is only available via websocket connections.
// This is an EXPERIMENTAL API and may be subject to change.
SubscribeActorEventsRaw(ctx context.Context, filter *types.ActorEventFilter) (<-chan *types.ActorEvent, error) //perm:read
// F3Participate should be called by a miner node to participate in signing F3 consensus.
// The address should be of type ID
// The returned channel will never be closed by the F3
// If it is closed without the context being cancelled, the caller should retry.
// The values returned on the channel will inform the caller about participation
// Empty strings will be sent if participation succeeded, non-empty strings explain possible errors.
F3Participate(ctx context.Context, minerID address.Address) (<-chan string, error) //perm:admin
// F3GetCertificate returns a finality certificate at given instance number
F3GetCertificate(ctx context.Context, instance uint64) (*certs.FinalityCertificate, error) //perm:read
// F3GetLatestCertificate returns the latest finality certificate
F3GetLatestCertificate(ctx context.Context) (*certs.FinalityCertificate, error) //perm:read
}
// reverse interface to the client, called after EthSubscribe

View File

@ -25,6 +25,7 @@ import (
"github.com/filecoin-project/go-address"
"github.com/filecoin-project/go-bitfield"
"github.com/filecoin-project/go-f3/certs"
"github.com/filecoin-project/go-jsonrpc/auth"
"github.com/filecoin-project/go-state-types/abi"
"github.com/filecoin-project/go-state-types/builtin/v9/verifreg"
@ -399,6 +400,7 @@ func init() {
FromHeight: epochPtr(1010),
ToHeight: epochPtr(1020),
})
addExample(&certs.FinalityCertificate{})
}
func GetAPIType(name, pkg string) (i interface{}, t reflect.Type, permStruct []reflect.Type) {

View File

@ -21,6 +21,7 @@ import (
address "github.com/filecoin-project/go-address"
bitfield "github.com/filecoin-project/go-bitfield"
certs "github.com/filecoin-project/go-f3/certs"
jsonrpc "github.com/filecoin-project/go-jsonrpc"
auth "github.com/filecoin-project/go-jsonrpc/auth"
abi "github.com/filecoin-project/go-state-types/abi"
@ -1152,6 +1153,51 @@ func (mr *MockFullNodeMockRecorder) EthUnsubscribe(arg0, arg1 interface{}) *gomo
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "EthUnsubscribe", reflect.TypeOf((*MockFullNode)(nil).EthUnsubscribe), arg0, arg1)
}
// F3GetCertificate mocks base method.
func (m *MockFullNode) F3GetCertificate(arg0 context.Context, arg1 uint64) (*certs.FinalityCertificate, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "F3GetCertificate", arg0, arg1)
ret0, _ := ret[0].(*certs.FinalityCertificate)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// F3GetCertificate indicates an expected call of F3GetCertificate.
func (mr *MockFullNodeMockRecorder) F3GetCertificate(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "F3GetCertificate", reflect.TypeOf((*MockFullNode)(nil).F3GetCertificate), arg0, arg1)
}
// F3GetLatestCertificate mocks base method.
func (m *MockFullNode) F3GetLatestCertificate(arg0 context.Context) (*certs.FinalityCertificate, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "F3GetLatestCertificate", arg0)
ret0, _ := ret[0].(*certs.FinalityCertificate)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// F3GetLatestCertificate indicates an expected call of F3GetLatestCertificate.
func (mr *MockFullNodeMockRecorder) F3GetLatestCertificate(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "F3GetLatestCertificate", reflect.TypeOf((*MockFullNode)(nil).F3GetLatestCertificate), arg0)
}
// F3Participate mocks base method.
func (m *MockFullNode) F3Participate(arg0 context.Context, arg1 address.Address) (<-chan string, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "F3Participate", arg0, arg1)
ret0, _ := ret[0].(<-chan string)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// F3Participate indicates an expected call of F3Participate.
func (mr *MockFullNodeMockRecorder) F3Participate(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "F3Participate", reflect.TypeOf((*MockFullNode)(nil).F3Participate), arg0, arg1)
}
// FilecoinAddressToEthAddress mocks base method.
func (m *MockFullNode) FilecoinAddressToEthAddress(arg0 context.Context, arg1 address.Address) (ethtypes.EthAddress, error) {
m.ctrl.T.Helper()

View File

@ -18,6 +18,7 @@ import (
"github.com/filecoin-project/go-address"
"github.com/filecoin-project/go-bitfield"
"github.com/filecoin-project/go-f3/certs"
"github.com/filecoin-project/go-jsonrpc"
"github.com/filecoin-project/go-jsonrpc/auth"
"github.com/filecoin-project/go-state-types/abi"
@ -249,6 +250,12 @@ type FullNodeMethods struct {
EthUnsubscribe func(p0 context.Context, p1 ethtypes.EthSubscriptionID) (bool, error) `perm:"read"`
F3GetCertificate func(p0 context.Context, p1 uint64) (*certs.FinalityCertificate, error) `perm:"read"`
F3GetLatestCertificate func(p0 context.Context) (*certs.FinalityCertificate, error) `perm:"read"`
F3Participate func(p0 context.Context, p1 address.Address) (<-chan string, error) `perm:"admin"`
FilecoinAddressToEthAddress func(p0 context.Context, p1 address.Address) (ethtypes.EthAddress, error) `perm:"read"`
GasEstimateFeeCap func(p0 context.Context, p1 *types.Message, p2 int64, p3 types.TipSetKey) (types.BigInt, error) `perm:"read"`
@ -2063,6 +2070,39 @@ func (s *FullNodeStub) EthUnsubscribe(p0 context.Context, p1 ethtypes.EthSubscri
return false, ErrNotSupported
}
func (s *FullNodeStruct) F3GetCertificate(p0 context.Context, p1 uint64) (*certs.FinalityCertificate, error) {
if s.Internal.F3GetCertificate == nil {
return nil, ErrNotSupported
}
return s.Internal.F3GetCertificate(p0, p1)
}
func (s *FullNodeStub) F3GetCertificate(p0 context.Context, p1 uint64) (*certs.FinalityCertificate, error) {
return nil, ErrNotSupported
}
func (s *FullNodeStruct) F3GetLatestCertificate(p0 context.Context) (*certs.FinalityCertificate, error) {
if s.Internal.F3GetLatestCertificate == nil {
return nil, ErrNotSupported
}
return s.Internal.F3GetLatestCertificate(p0)
}
func (s *FullNodeStub) F3GetLatestCertificate(p0 context.Context) (*certs.FinalityCertificate, error) {
return nil, ErrNotSupported
}
func (s *FullNodeStruct) F3Participate(p0 context.Context, p1 address.Address) (<-chan string, error) {
if s.Internal.F3Participate == nil {
return nil, ErrNotSupported
}
return s.Internal.F3Participate(p0, p1)
}
func (s *FullNodeStub) F3Participate(p0 context.Context, p1 address.Address) (<-chan string, error) {
return nil, ErrNotSupported
}
func (s *FullNodeStruct) FilecoinAddressToEthAddress(p0 context.Context, p1 address.Address) (ethtypes.EthAddress, error) {
if s.Internal.FilecoinAddressToEthAddress == nil {
return *new(ethtypes.EthAddress), ErrNotSupported

View File

@ -191,7 +191,7 @@ type ForkUpgradeParams struct {
UpgradeWatermelonHeight abi.ChainEpoch
UpgradeDragonHeight abi.ChainEpoch
UpgradePhoenixHeight abi.ChainEpoch
UpgradeAussieHeight abi.ChainEpoch
UpgradeWaffleHeight abi.ChainEpoch
}
// ChainExportConfig holds configuration for chain ranged exports.

Binary file not shown.

View File

@ -1,4 +1,4 @@
/dns4/calibration.node.glif.io/tcp/1237/p2p/12D3KooWQPYouEAsUQKzvFUA9sQ8tz4rfpqtTzh2eL6USd9bwg7x
/dns4/bootstrap-calibnet-0.chainsafe-fil.io/tcp/34000/p2p/12D3KooWABQ5gTDHPWyvhJM7jPhtNwNJruzTEo32Lo4gcS5ABAMm
/dns4/bootstrap-calibnet-1.chainsafe-fil.io/tcp/34000/p2p/12D3KooWS3ZRhMYL67b4bD5XQ6fcpTyVQXnDe8H89LvwrDqaSbiT
/dns4/bootstrap-calibnet-2.chainsafe-fil.io/tcp/34000/p2p/12D3KooWEiBN8jBX8EBoM3M47pVRLRWV812gDRUJhMxgyVkUoR48
/dns/calibration.node.glif.io/tcp/1237/p2p/12D3KooWQPYouEAsUQKzvFUA9sQ8tz4rfpqtTzh2eL6USd9bwg7x
/dns/bootstrap-calibnet-0.chainsafe-fil.io/tcp/34000/p2p/12D3KooWABQ5gTDHPWyvhJM7jPhtNwNJruzTEo32Lo4gcS5ABAMm
/dns/bootstrap-calibnet-1.chainsafe-fil.io/tcp/34000/p2p/12D3KooWS3ZRhMYL67b4bD5XQ6fcpTyVQXnDe8H89LvwrDqaSbiT
/dns/bootstrap-calibnet-2.chainsafe-fil.io/tcp/34000/p2p/12D3KooWEiBN8jBX8EBoM3M47pVRLRWV812gDRUJhMxgyVkUoR48

View File

@ -1,6 +1,5 @@
/dns4/node.glif.io/tcp/1235/p2p/12D3KooWBF8cpp65hp2u9LK5mh19x67ftAam84z9LsfaquTDSBpt
/dns4/bootstarp-0.1475.io/tcp/61256/p2p/12D3KooWRzCVDwHUkgdK7eRgnoXbjDAELhxPErjHzbRLguSV1aRt
/dns4/bootstrap-venus.mainnet.filincubator.com/tcp/8888/p2p/QmQu8C6deXwKvJP2D8B6QGyhngc3ZiDnFzEHBDx8yeBXST
/dns4/bootstrap-mainnet-0.chainsafe-fil.io/tcp/34000/p2p/12D3KooWKKkCZbcigsWTEu1cgNetNbZJqeNtysRtFpq7DTqw3eqH
/dns4/bootstrap-mainnet-1.chainsafe-fil.io/tcp/34000/p2p/12D3KooWGnkd9GQKo3apkShQDaq1d6cKJJmsVe6KiQkacUk1T8oZ
/dns4/bootstrap-mainnet-2.chainsafe-fil.io/tcp/34000/p2p/12D3KooWHQRSDFv4FvAjtU32shQ7znz7oRbLBryXzZ9NMK2feyyH
/dns/node.glif.io/tcp/1235/p2p/12D3KooWBF8cpp65hp2u9LK5mh19x67ftAam84z9LsfaquTDSBpt
/dns/bootstrap-venus.mainnet.filincubator.com/tcp/8888/p2p/QmQu8C6deXwKvJP2D8B6QGyhngc3ZiDnFzEHBDx8yeBXST
/dns/bootstrap-mainnet-0.chainsafe-fil.io/tcp/34000/p2p/12D3KooWKKkCZbcigsWTEu1cgNetNbZJqeNtysRtFpq7DTqw3eqH
/dns/bootstrap-mainnet-1.chainsafe-fil.io/tcp/34000/p2p/12D3KooWGnkd9GQKo3apkShQDaq1d6cKJJmsVe6KiQkacUk1T8oZ
/dns/bootstrap-mainnet-2.chainsafe-fil.io/tcp/34000/p2p/12D3KooWHQRSDFv4FvAjtU32shQ7znz7oRbLBryXzZ9NMK2feyyH

View File

@ -143,25 +143,25 @@ var EmbeddedBuiltinActorsMetadata = []*BuiltinActorsMetadata{{
}, {
Network: "butterflynet",
Version: 14,
BundleGitTag: "v13.0.0",
ManifestCid: MustParseCid("bafy2bzacec75zk7ufzwx6tg5avls5fxdjx5asaqmd2bfqdvkqrkzoxgyflosu"),
BundleGitTag: "v14.0.0-rc.1",
ManifestCid: MustParseCid("bafy2bzacecmkqezl3a5klkzz7z4ou4jwqk4zzd3nvz727l4qh44ngsxtxdblu"),
Actors: map[string]cid.Cid{
"account": MustParseCid("bafk2bzacedl533kwbzouqxibejpwp6syfdekvmzy4vmmno6j4iaydbdmv4xek"),
"cron": MustParseCid("bafk2bzacecimv5xnuwyoqgxk26qt4xqpgntleret475pnh35s3vvhqtdct4ow"),
"datacap": MustParseCid("bafk2bzacebpdd4ctavhs7wkcykfahpifct3p4hbptgtf4jfrqcp2trtlygvow"),
"eam": MustParseCid("bafk2bzaceahw5rrgj7prgbnmn237di7ymjz2ssea32wr525jydpfrwpuhs67m"),
"ethaccount": MustParseCid("bafk2bzacebrslcbew5mq3le2zsn36xqxd4gt5hryeoslxnuqwgw3rhuwh6ygu"),
"evm": MustParseCid("bafk2bzaced5smz4lhpem4mbr7igcskv3e5qopbdp7dqshww2qs4ahacgzjzo4"),
"init": MustParseCid("bafk2bzacedgj6hawhdw2ot2ufisci374o2bq6bfkvlvdt6q7s3uoe5ffyv43k"),
"multisig": MustParseCid("bafk2bzacectnnnpwyqiccaymy3h6ghu74ghjrqyhtqv5odfd4opivzebjj6to"),
"paymentchannel": MustParseCid("bafk2bzaceckhx44jawhzhkz6k23gfnv2gcutgb4j4ekhonj2plwaent4b2tpk"),
"account": MustParseCid("bafk2bzaceazutruyfvvqxgp5qoneq36uv6yethps2bonil5psy2vivl5j2hks"),
"cron": MustParseCid("bafk2bzacecsiz2nzjieposnkz2kqvjjnqyu5zwk6ccm4dbptx26v3qirm6zni"),
"datacap": MustParseCid("bafk2bzaceaavii766hmiawhw2fjvtoy5kvbukou3zejf6gtwu7xi4jxt4uidk"),
"eam": MustParseCid("bafk2bzacebkzhnamn5ohtsvn76opprsi3ao3ujgytjr3c6kdcvhmhg4ze5xxm"),
"ethaccount": MustParseCid("bafk2bzacebvvri25rmgt6yy5qtdrikcsestk6z52aebynwd53s2rm2l3ukn7g"),
"evm": MustParseCid("bafk2bzacebta2jkyxknvwnr6ldcimmwpzenhtdwqbuifzk6g2wktzqf3vj33a"),
"init": MustParseCid("bafk2bzaceblybzwnn55uiivbsjae6l7haz5iocexnynfcz2yjg5spciimxdme"),
"multisig": MustParseCid("bafk2bzaceb54rbdcfdcdtzwbohshn64opgsqf5vhqh3xqb37iignsm3plrtpa"),
"paymentchannel": MustParseCid("bafk2bzacebyyn42ie7jekdytacqpqfll7xctsfpza3tb2sonzsjdeltxqgmdo"),
"placeholder": MustParseCid("bafk2bzacedfvut2myeleyq67fljcrw4kkmn5pb5dpyozovj7jpoez5irnc3ro"),
"reward": MustParseCid("bafk2bzacebbs3rlg7y3wbvxrj4wgbsqmasw4ksbbr3lyqbkaxj2t25qz6zzuy"),
"storagemarket": MustParseCid("bafk2bzaced3zmxsmlhp2nsiwkxcp2ugonbsebcd53t7htzo2jcoidvu464xmm"),
"storageminer": MustParseCid("bafk2bzacebedx7iaa2ruspxvghkg46ez7un5b7oiijjtnvddq2aot5wk7p7ry"),
"storagepower": MustParseCid("bafk2bzacebvne7m2l3hxxw4xa6oujol75x35yqpnlqiwx74jilyrop4cs7cse"),
"system": MustParseCid("bafk2bzaceacjmlxrvydlud77ilpzbscez46yedx6zjsj6olxsdeuv6d4x4cwe"),
"verifiedregistry": MustParseCid("bafk2bzacebs5muoq7ft2wgqojhjio7a4vltbyprqkmlr43ojlzbil4nwvj3jg"),
"reward": MustParseCid("bafk2bzaceczaoglexx6w3m744s4emfmjkeizpl4ofdkh4xzhevjtd6zift5iu"),
"storagemarket": MustParseCid("bafk2bzaceceaqmhkxuerleq2dpju35mcsdiklpkisglzlj5xkf32hbyqn7sam"),
"storageminer": MustParseCid("bafk2bzacebkiqu5pclx5zze4ugcsn3lvumihyathpcrjfq36b3hgmd7jqe2bk"),
"storagepower": MustParseCid("bafk2bzacebcxydq2iampltz5zoo3oojka45hjkd62vz46xtpl6qilhkkjdeaq"),
"system": MustParseCid("bafk2bzacebbrs3dzgxwj43ztup7twz25xkbhhtmcbjjbscjvpsrpbwux3b32g"),
"verifiedregistry": MustParseCid("bafk2bzacebj3znhdpxqjgvztrv3petqwdkvrefg4j6lrp3n7wfrkdoan4os42"),
},
}, {
Network: "calibrationnet",
@ -295,25 +295,25 @@ var EmbeddedBuiltinActorsMetadata = []*BuiltinActorsMetadata{{
}, {
Network: "calibrationnet",
Version: 14,
BundleGitTag: "v13.0.0",
ManifestCid: MustParseCid("bafy2bzacect4ktyujrwp6mjlsitnpvuw2pbuppz6w52sfljyo4agjevzm75qs"),
BundleGitTag: "v14.0.0-rc.1",
ManifestCid: MustParseCid("bafy2bzacebq3hncszqpojglh2dkwekybq4zn6qpc4gceqbx36wndps5qehtau"),
Actors: map[string]cid.Cid{
"account": MustParseCid("bafk2bzaceb3j36ri5y5mfklgp5emlvrms6g4733ss2j3l7jismrxq6ng3tcc6"),
"cron": MustParseCid("bafk2bzaceaz6rocamdxehgpwcbku6wlapwpgzyyvkrploj66mlqptsulf52bs"),
"datacap": MustParseCid("bafk2bzacea22nv5g3yngpxvonqfj4r2nkfk64y6yw2malicm7odk77x7zuads"),
"eam": MustParseCid("bafk2bzaceatqtjzj7623i426noaslouvluhz6e3md3vvquqzku5qj3532uaxg"),
"ethaccount": MustParseCid("bafk2bzacean3hs7ga5csw6g3uu7watxfnqv5uvxviebn3ba6vg4sagwdur5pu"),
"evm": MustParseCid("bafk2bzacec5ibmbtzuzjgwjmksm2n6zfq3gkicxqywwu7tsscqgdzajpfctxk"),
"init": MustParseCid("bafk2bzaced5sq72oemz6qwi6yssxwlos2g54zfprslrx5qfhhx2vlgsbvdpcs"),
"multisig": MustParseCid("bafk2bzacedbgei6jkx36fwdgvoohce4aghvpohqdhoco7p4thszgssms7olv2"),
"paymentchannel": MustParseCid("bafk2bzaceasmgmfsi4mjanxlowsub65fmevhzky4toeqbtw4kp6tmu4kxjpgq"),
"account": MustParseCid("bafk2bzaced5ecfm56dvtw26q56j4d32yoccyd7ggxn3qdki2enxpqqav45ths"),
"cron": MustParseCid("bafk2bzacedpbtttpyvtjncqoyobr63mhqqtlrygbnudhxyp2vha56f626dkfs"),
"datacap": MustParseCid("bafk2bzacecded3lcvo7ndsk66samyecw2trnhrgzi7jxsary3sqgopxlk6rku"),
"eam": MustParseCid("bafk2bzacecsda4uw7dcu76a27gnrrdcm73tgms7wrte6jbou63vloktkqc5ne"),
"ethaccount": MustParseCid("bafk2bzacebu2lcxfmohomjj3umslnylwugf5gssywdq3575tjarta7o227dls"),
"evm": MustParseCid("bafk2bzacea4xnekruhfmdnzvzeo6cbf7jsfgco6x5wje2ckwc2ui2ojzcrlgu"),
"init": MustParseCid("bafk2bzacedfmsdlewihdcrkdepnfata26nj7akbvexzs3chicujhjf2uxsazc"),
"multisig": MustParseCid("bafk2bzacedwx4svscsp6wqqu2vlcunjihvvm4u2jnsqjkwutjhir7dwtl7z6m"),
"paymentchannel": MustParseCid("bafk2bzacedbit7oo6lryhbo64uikvtjtfcth6oxwy3eebxerenu2h7rj44n24"),
"placeholder": MustParseCid("bafk2bzacedfvut2myeleyq67fljcrw4kkmn5pb5dpyozovj7jpoez5irnc3ro"),
"reward": MustParseCid("bafk2bzacedjyp6ll5ez27dfgldjj4tntxfvyp4pa5zkk7s5uhipzqjyx2gmuc"),
"storagemarket": MustParseCid("bafk2bzaceabolct6qdnefwcrtati2us3sxtxfghyqk6aamfhl6byyefmtssqi"),
"storageminer": MustParseCid("bafk2bzaceckzw3v7wqliyggvjvihz4wywchnnsie4frfvkm3fm5znb64mofri"),
"storagepower": MustParseCid("bafk2bzacea7t4wynzjajl442mpdqbnh3wusjusqtnzgpvefvweh4n2tgzgqhu"),
"system": MustParseCid("bafk2bzacedjnrb5glewazsxpcx6rwiuhl4kwrfcqolyprn6rrjtlzmthlhdq6"),
"verifiedregistry": MustParseCid("bafk2bzacebj2zdquagzy2xxn7up574oemg3w7ed3fe4aujkyhgdwj57voesn2"),
"reward": MustParseCid("bafk2bzaced5rlycj7fzpscfc7p3wwxarngwqylqshj7te3uffey5tevunz4we"),
"storagemarket": MustParseCid("bafk2bzaceatwbyrec2nnwggxc2alpqve7rl52fmbhqflebuxmmnvg3qckjb7c"),
"storageminer": MustParseCid("bafk2bzacecr7ozkdz7l2pq3ig5qxae2ysivbnojhsn4gw3o57ov4mhksma7me"),
"storagepower": MustParseCid("bafk2bzacedgeolvjtnw7fkji5kqmx322abv6uls2v34fuml6nw36dvfcw4mtu"),
"system": MustParseCid("bafk2bzacederl6tlpieldsn6mkndqwd4wj5orfoqgab6p2klswfn3cjagxwla"),
"verifiedregistry": MustParseCid("bafk2bzaceczw2kp6gjjdcjbso7mewp7guik7gr525pal6dotdja2lrct6ok3c"),
},
}, {
Network: "caterpillarnet",
@ -456,25 +456,25 @@ var EmbeddedBuiltinActorsMetadata = []*BuiltinActorsMetadata{{
}, {
Network: "caterpillarnet",
Version: 14,
BundleGitTag: "v13.0.0",
ManifestCid: MustParseCid("bafy2bzacedu7kk2zngxp7y3lynhtaht6vgadgn5jzkxe5nuowtwzasnogx63w"),
BundleGitTag: "v14.0.0-rc.1",
ManifestCid: MustParseCid("bafy2bzacecr6g2co4zkdvrsbz2z7wh44o6hrl3rpbgnlhe52772hhjs43vxge"),
Actors: map[string]cid.Cid{
"account": MustParseCid("bafk2bzacecro3uo6ypqhfzwdhnamzcole5qmhrbkx7qny6t2qsrcpqxelt6s2"),
"cron": MustParseCid("bafk2bzaceam3kci46y4siltbw7f4itoap34kp7b7pvn2fco5s2bvnotomwdbe"),
"datacap": MustParseCid("bafk2bzacecmtdspcbqmmjtsaz4vucuqoqjqfsgxjonns7tom7eblkngbcm7bw"),
"eam": MustParseCid("bafk2bzaceaudqhrt7djewopqdnryvwxagfufyt7ja4gdvovrxbh6edh6evgrw"),
"ethaccount": MustParseCid("bafk2bzaced676ds3z6xe333wr7frwq3f2iq5kjwp4okl3te6rne3xf7kuqrwm"),
"evm": MustParseCid("bafk2bzacebeih4jt2s6mel6x4hje7xmnugh6twul2a5axx4iczu7fu4wcdi6k"),
"init": MustParseCid("bafk2bzaceba7vvuzzwj5wqnq2bvpbgtxup53mhr3qybezbllftnxvpqbfymxo"),
"multisig": MustParseCid("bafk2bzaceapkajhnqoczrgry5javqbl7uebgmsbpqqfemzc4yb5q2dqia2qog"),
"paymentchannel": MustParseCid("bafk2bzacebg7xq4ca22gafmdbkcq357x7v6slflib4h3fnj4amsovg6ulqg3o"),
"account": MustParseCid("bafk2bzacecaoykugysdikvzptp5jc6qzhfxv3tsy7eggoabfk34jc6ozr3nju"),
"cron": MustParseCid("bafk2bzacede6xljkkb6qww47hdho2dfs75bfxjwmxspldwclekd2ntdvcapj6"),
"datacap": MustParseCid("bafk2bzacedjwq3frxklkkejk4payjpjwgdj352izzcmymtzib6xzgrrtczeuw"),
"eam": MustParseCid("bafk2bzaceana2fkgcjhtr56rrqngvilybjpavfgfwf3kuqed6qxa4lfdjmkac"),
"ethaccount": MustParseCid("bafk2bzacedg7tcqwoykjd57dkettxxato4yufxlyzy6hgsggc7jhf6v7zqgas"),
"evm": MustParseCid("bafk2bzacedwqu6pi4csjod4c5677pgsr6g4ekhqnqgdnsiodyqczmcsj3sspk"),
"init": MustParseCid("bafk2bzaceakukvex4wjcrmwp5msp4d2dhe4qlftqxgolxx5sbtshah3fxoepy"),
"multisig": MustParseCid("bafk2bzaceamp2c2qfgnl7z6vz5majhcm64ml72kbg5kea4xgdnfcyqanynfks"),
"paymentchannel": MustParseCid("bafk2bzacebs44wqfedfx3o23q7tkza5cm3q54gevreqzetsei2bvhsmqdwz3i"),
"placeholder": MustParseCid("bafk2bzacedfvut2myeleyq67fljcrw4kkmn5pb5dpyozovj7jpoez5irnc3ro"),
"reward": MustParseCid("bafk2bzaceajt4idf26ffnyipybcib55fykjxnek7oszkqzi7lu7mbgijmkgos"),
"storagemarket": MustParseCid("bafk2bzaceadfmay7pyl7osjsdmrireafasnjnoziacljy5ewrcsxpp56kzqbw"),
"storageminer": MustParseCid("bafk2bzaceardbn5a7aq5jxl7efr4btmsbl7txnxm4hrrd3llyhujuc2cr5vcs"),
"storagepower": MustParseCid("bafk2bzacear4563jznjqyseoy42xl6kenyqk6umv6xl3bp5bsjb3hbs6sp6bm"),
"system": MustParseCid("bafk2bzacecc5oavxivfnvirx2g7megpdf6lugooyoc2wijloju247xzjcdezy"),
"verifiedregistry": MustParseCid("bafk2bzacebnkdt42mpf5emypo6iroux3hszfh5yt54v2mmnnura3ketholly4"),
"reward": MustParseCid("bafk2bzacedyckhwkkmcoc2n6byzw6vxi3lqyp3zjs3b7flfqj2wybprwxkw2m"),
"storagemarket": MustParseCid("bafk2bzacebx7ky74ry222rvi56wav3dbal4rqooeuafiakg7r6ksxh2uahbju"),
"storageminer": MustParseCid("bafk2bzacecwfsmi6xxbwkddunjt2zs6qn2g4hvrwury7g36vqvafmok7gs642"),
"storagepower": MustParseCid("bafk2bzacecqcvllpsttt3nqcso4ng2z4cjjn5sr36is7yze74ihqnol2dst2u"),
"system": MustParseCid("bafk2bzacea75k6agtdmjxdfnwbctzstc6pozdblpdevc5ixjevvuzcqwwuzrc"),
"verifiedregistry": MustParseCid("bafk2bzacedxwgmgffeapq4nffplapb5mixkrm2vosmc2i3fxcye5dookiqubu"),
},
}, {
Network: "devnet",
@ -608,25 +608,25 @@ var EmbeddedBuiltinActorsMetadata = []*BuiltinActorsMetadata{{
}, {
Network: "devnet",
Version: 14,
BundleGitTag: "v13.0.0",
ManifestCid: MustParseCid("bafy2bzacecn7uxgehrqbcs462ktl2h23u23cmduy2etqj6xrd6tkkja56fna4"),
BundleGitTag: "v14.0.0-rc.1",
ManifestCid: MustParseCid("bafy2bzacebwn7ymtozv5yz3x5hnxl4bds2grlgsk5kncyxjak3hqyhslb534m"),
Actors: map[string]cid.Cid{
"account": MustParseCid("bafk2bzacebev3fu5geeehpx577b3kvza4xsmmggmepjj7rlsnr27hpoq27q2i"),
"cron": MustParseCid("bafk2bzacedalzqahtuz2bmnf7uawbcujfhhe5xzv5ys5ufadu6ggs3tcu6lsy"),
"datacap": MustParseCid("bafk2bzaceb7ou2vn7ac4xidespoowq2q5w7ognr7s4ujy3xzzgiishajpe7le"),
"eam": MustParseCid("bafk2bzacedqic2qskattorj4svf6mbto2k76ej3ll3ugsyorqramrg7rpq3by"),
"ethaccount": MustParseCid("bafk2bzaceaoad7iknpywijigv2h3jyvkijff2oxvohzue533v5hby3iix5vdu"),
"evm": MustParseCid("bafk2bzacecjgiw26gagsn6a7tffkrgoor4zfgzfokp76u6cwervtmvjbopmwg"),
"init": MustParseCid("bafk2bzaced2obubqojxggeddr246cpwtyzi6knnq52jsvsc2fs3tuk2kh6dtg"),
"multisig": MustParseCid("bafk2bzacebquruzb6zho45orbdkku624t6w6jt4tudaqzraz4yh3li3jfstpg"),
"paymentchannel": MustParseCid("bafk2bzaceaydrilyxvflsuzr24hmw32qwz6sy4hgls73bhpveydcsqskdgpca"),
"account": MustParseCid("bafk2bzacecqyi3xhyrze7hlo73zzyzz5jw5e6eqqyesmnbef4xr7br5amqsm2"),
"cron": MustParseCid("bafk2bzacebmeovn3fehscsm2ejcd2vejgqmuqidzx3ytlvp4osa6fes3w73yy"),
"datacap": MustParseCid("bafk2bzaceasqdluegec5qllzjhu66jsyvb74dix6wjztpiaxvha74in7h4eek"),
"eam": MustParseCid("bafk2bzaced4shnjesuxk44ufllcywjbaixerx6hkcyj5rqqopjuic725fymx2"),
"ethaccount": MustParseCid("bafk2bzacebbw6hg766y4ouycqlr3llur7sxkgj7hnu7jq4xlwtycp3ovpqjee"),
"evm": MustParseCid("bafk2bzaceafzevk77d6zhjbrw7grm5p3es2pzuklpvcthedjv6ejh7alvxqoc"),
"init": MustParseCid("bafk2bzacebaywpmwlfhhog6vey3dkz25hjrlwnhacsjryq3ujymyttolglats"),
"multisig": MustParseCid("bafk2bzacedm52r4h7upic7ynukzwjkadefbjeq7w7ozdonsbdumgoabk7xass"),
"paymentchannel": MustParseCid("bafk2bzacecsvfy77loubouoyqwl2ke574zpg3x5f2qon6ougjzfjna6eadwxg"),
"placeholder": MustParseCid("bafk2bzacedfvut2myeleyq67fljcrw4kkmn5pb5dpyozovj7jpoez5irnc3ro"),
"reward": MustParseCid("bafk2bzaceb74owpuzdddqoj2tson6ymbyuguqrnqefyiaxqvwm4ygitpabjrq"),
"storagemarket": MustParseCid("bafk2bzaceaw6dslv6pfqha4ynghq2imij5khnnjrie22kmfgtpie3bvxho6jq"),
"storageminer": MustParseCid("bafk2bzacecsputz6xygjfyrvx2d7bxkpp7b5v4icrmpckec7gnbabx2w377qs"),
"storagepower": MustParseCid("bafk2bzaceceyaa5yjwhxvvcqouob4l746zp5nesivr6enhtpimakdtby6kafi"),
"system": MustParseCid("bafk2bzaceaxg6k5vuozxlemfi5hv663m6jcawzu5puboo4znj73i36e3tsovs"),
"verifiedregistry": MustParseCid("bafk2bzacea2czkb4vt2iiiwdb6e57qfwqse4mk2pcyvwjmdl5ojbnla57oh2u"),
"reward": MustParseCid("bafk2bzacecvc7v5d2krwxqeyklfg2xb5qc3kalu66265smcbmwepjmj643uqu"),
"storagemarket": MustParseCid("bafk2bzacecegzksfqu35xlcc6ymxae3vqpkntbajx4jtahugszvb77fnr37ii"),
"storageminer": MustParseCid("bafk2bzacedoimzimltyfzbabwuam2bqw32nqwo2twjq73q7mklwtvqi2evsw2"),
"storagepower": MustParseCid("bafk2bzacebszcfmepyvssrg2tbbqgpqm2cnrl5ub4n6cfy7eie2wwseyloxvs"),
"system": MustParseCid("bafk2bzacea4rh5i36ucj23zb4mid4tw5ym2wqlfap4ejjaynvobengeuby4ja"),
"verifiedregistry": MustParseCid("bafk2bzaceapbsihfuk3munfpcoevtxlwuenxeiiv7dp7v3t2yjs26hcpypexi"),
},
}, {
Network: "hyperspace",
@ -783,25 +783,25 @@ var EmbeddedBuiltinActorsMetadata = []*BuiltinActorsMetadata{{
}, {
Network: "mainnet",
Version: 14,
BundleGitTag: "v13.0.0",
ManifestCid: MustParseCid("bafy2bzacecdhvfmtirtojwhw2tyciu4jkbpsbk5g53oe24br27oy62sn4dc4e"),
BundleGitTag: "v14.0.0-rc.1",
ManifestCid: MustParseCid("bafy2bzacecbueuzsropvqawsri27owo7isa5gp2qtluhrfsto2qg7wpgxnkba"),
Actors: map[string]cid.Cid{
"account": MustParseCid("bafk2bzacedxnbtlsqdk76fsfmnhyvsblwyfducerwwtp3mqtx2wbrvs5idl52"),
"cron": MustParseCid("bafk2bzacebbopddyn5csb3fsuhh2an4ttd23x6qnwixgohlirj5ahtcudphyc"),
"datacap": MustParseCid("bafk2bzaceah42tfnhd7xnztawgf46gbvc3m2gudoxshlba2ucmmo2vy67t7ci"),
"eam": MustParseCid("bafk2bzaceb23bhvvcjsth7cn7vp3gbaphrutsaz7v6hkls3ogotzs4bnhm4mk"),
"ethaccount": MustParseCid("bafk2bzaceautge6zhuy6jbj3uldwoxwhpywuon6z3xfvmdbzpbdribc6zzmei"),
"evm": MustParseCid("bafk2bzacedq6v2lyuhgywhlllwmudfj2zufzcauxcsvvd34m2ek5xr55mvh2q"),
"init": MustParseCid("bafk2bzacedr4xacm3fts4vilyeiacjr2hpmwzclyzulbdo24lrfxbtau2wbai"),
"multisig": MustParseCid("bafk2bzacecr5zqarfqak42xqcfeulsxlavcltawsx2fvc7zsjtby6ti4b3wqc"),
"paymentchannel": MustParseCid("bafk2bzacebntdhfmyc24e7tm52ggx5tnw4i3hrr3jmllsepv3mibez4hywsa2"),
"account": MustParseCid("bafk2bzacebr7ik7lng7vysm754mu5x7sakphwm4soqi6zwbox4ukpd6ndwvqy"),
"cron": MustParseCid("bafk2bzacecwn6eiwa7ysimmk6i57i5whj4cqzwijx3xdlxwb5canmweaez6xc"),
"datacap": MustParseCid("bafk2bzacecidw7ajvtjhmygqs2yxhmuybyvtwp25dxpblvdxxo7u4gqfzirjg"),
"eam": MustParseCid("bafk2bzaced2cxnfwngpcubg63h7zk4y5hjwwuhfjxrh43xozax2u6u2woweju"),
"ethaccount": MustParseCid("bafk2bzacechu4u7asol5mpcsr6fo6jeaeltvayj5bllupyiux7tcynsxby7ko"),
"evm": MustParseCid("bafk2bzacedupohbgwrcw5ztbbsvrpqyybnokr4ylegmk7hrbt3ueeykua6zxw"),
"init": MustParseCid("bafk2bzacecbbcshenkb6z2v4irsudv7tyklfgphhizhghix6ke5gpl4r5f2b6"),
"multisig": MustParseCid("bafk2bzaceajcmsngu3f2chk2y7nanlen5xlftzatytzm6hxwiiw5i5nz36bfc"),
"paymentchannel": MustParseCid("bafk2bzaceavslp27u3f4zwjq45rlg6assj6cqod7r5f6wfwkptlpi6j4qkmne"),
"placeholder": MustParseCid("bafk2bzacedfvut2myeleyq67fljcrw4kkmn5pb5dpyozovj7jpoez5irnc3ro"),
"reward": MustParseCid("bafk2bzacedq4q2kwkruu4xm7rkyygumlbw2yt4nimna2ivea4qarvtkohnuwu"),
"storagemarket": MustParseCid("bafk2bzacebjtoltdviyznpj34hh5qp6u257jnnbjole5rhqfixm7ug3epvrfu"),
"storageminer": MustParseCid("bafk2bzacebf4rrqyk7gcfggggul6nfpzay7f2ordnkwm7z2wcf4mq6r7i77t2"),
"storagepower": MustParseCid("bafk2bzacecjy4dkulvxppg3ocbmeixe2wgg6yxoyjxrm4ko2fm3uhpvfvam6e"),
"system": MustParseCid("bafk2bzacecyf523quuq2kdjfdvyty446z2ounmamtgtgeqnr3ynlu5cqrlt6e"),
"verifiedregistry": MustParseCid("bafk2bzacedkxehp7y7iyukbcje3wbpqcvufisos6exatkanyrbotoecdkrbta"),
"reward": MustParseCid("bafk2bzacedvfnjittwrkhoar6n5xrykowg2e6rpur4poh2m572f7m7evyx4lc"),
"storagemarket": MustParseCid("bafk2bzaceaju5wobednmornvdqcyi6khkvdttkru4dqduqicrdmohlwfddwhg"),
"storageminer": MustParseCid("bafk2bzacea3f43rxzemmakjpktq2ukayngean3oo2de5cdxlg2wsyn53wmepc"),
"storagepower": MustParseCid("bafk2bzacedo6scxizooytn53wjwg2ooiawnj4fsoylcadnp7mhgzluuckjl42"),
"system": MustParseCid("bafk2bzacecak4ow7tmauku42s3u2yydonk4hx6ov6ov542hy7lcbji3nhrrhs"),
"verifiedregistry": MustParseCid("bafk2bzacebvyzjzmvmjvpypphqsumpy6rzxuugnehgum7grc6sv3yqxzrshb4"),
},
}, {
Network: "testing",
@ -935,25 +935,25 @@ var EmbeddedBuiltinActorsMetadata = []*BuiltinActorsMetadata{{
}, {
Network: "testing",
Version: 14,
BundleGitTag: "v13.0.0",
ManifestCid: MustParseCid("bafy2bzacedg47dqxmtgzjch6i42kth72esd7w23gujyd6c6oppg3n6auag5ou"),
BundleGitTag: "v14.0.0-rc.1",
ManifestCid: MustParseCid("bafy2bzacebgc3zha33w7wggshqjeeomjnxfsqdezpt6e5w4tcqnfp42hvhqyy"),
Actors: map[string]cid.Cid{
"account": MustParseCid("bafk2bzaceb3tncntgeqvzzr5fzhvpsc5ntv3tpqrsh4jst4irfyzpkdyigibc"),
"cron": MustParseCid("bafk2bzacecwwasmhixpgtshczm5cfspwciyawc25mrefknqhlxfrd6m57tqmc"),
"datacap": MustParseCid("bafk2bzaceckj66by6eohjrybazh5cymmovgl5bmikpvzki2q7huwk2fweoef2"),
"eam": MustParseCid("bafk2bzaceafzm65wvnaam3775homn4vzsv7odftn5tkifmn44wd2t6gupy63y"),
"ethaccount": MustParseCid("bafk2bzaced4q7m4mha2dsezhwub3ru64rgimkg52t25ul4gnekax6uq7hbkqu"),
"evm": MustParseCid("bafk2bzaceakpknw5cuizil3552jr5z35rs6ijaignjigciswtok67drhzdss6"),
"init": MustParseCid("bafk2bzacec7mbkemwugyg2p4oy2xgnovykk4dnsu5ym4wkreooujvxfsxbo3i"),
"multisig": MustParseCid("bafk2bzacebmftoql6dcyqf54xznwjg2bfgdsi67spqquwslpvvtvcx6qenhz2"),
"paymentchannel": MustParseCid("bafk2bzaceau57wpiiikea6pu5om4ryyqjrxjzfksfl4reqosnohydzv3pf4qq"),
"account": MustParseCid("bafk2bzacedz5ko33xyknznoj5mcwnijhggapvn7hzmec3ix3vlqjg6uuwownm"),
"cron": MustParseCid("bafk2bzacebifywvakusxpvnzn33qneqm46g3trnqvuvaw5cgslfg5cl7prtwa"),
"datacap": MustParseCid("bafk2bzacedx4zxq5ae6qbucm6elokqhhmlwbtas7mbqm6rnigwkmorrtfzo66"),
"eam": MustParseCid("bafk2bzaceavilsrvq7kdyqelapjabixsgmhf6caufc4hdyviccmerf3sawzdk"),
"ethaccount": MustParseCid("bafk2bzaceavutdrzkspoiz6a5m46m2qzqbsmdb33s62xnkpevuwjrhxm6trn2"),
"evm": MustParseCid("bafk2bzacedovnz466nuqdp5pzs6sztcqofsy5zet7k2gybnbelpwuxpmfphwo"),
"init": MustParseCid("bafk2bzaceajnftptl2tdbrudshriqcg3caw5mqublmd6i5dm3qug3j5qo7g4q"),
"multisig": MustParseCid("bafk2bzacebagezdbubvu4g3norwxaomzpk3mxyzfal3rsvvppdbt46y6h74yc"),
"paymentchannel": MustParseCid("bafk2bzacebmtufrtdxo757c6c5ndmsk3wlnzzuzqp4yzbtltqjutnlgh7awus"),
"placeholder": MustParseCid("bafk2bzacedfvut2myeleyq67fljcrw4kkmn5pb5dpyozovj7jpoez5irnc3ro"),
"reward": MustParseCid("bafk2bzacecvlcdgbqlk3dyfzkcjrywg2th5bmn7ilijifikulpxr4ffcrw23o"),
"storagemarket": MustParseCid("bafk2bzacecgj53dwqla7eiubs2uiza7cgxkxtefxkfpjontj5jxefl3a4i2nq"),
"storageminer": MustParseCid("bafk2bzaceailclue4dba2edjethfjw6ycufcwsx4qjjmgsh77xcyprmogdjvu"),
"storagepower": MustParseCid("bafk2bzaceaqw6dhdjlqovhk3p4lb4sb25i5d6mhln2ir5m7tj6m4fegkgkinw"),
"system": MustParseCid("bafk2bzaceby6aiiosnrtb5kzlmrvd4k3o27oo3idmbd6llydz2uqibbp23pzq"),
"verifiedregistry": MustParseCid("bafk2bzaceadw6mxuyb6ipaq3fhekk7u5osyyiis3c4wbkvysy2ut6qfsua5zs"),
"reward": MustParseCid("bafk2bzacebtnflocubjjrtvzba4tmrn32tlx2klfgmjreqeo234lqdzu4ovna"),
"storagemarket": MustParseCid("bafk2bzacec6tovj5vh6lyor3m67uhahhldrixnqg7e5246pce5gcwkqwmbvxo"),
"storageminer": MustParseCid("bafk2bzacedcwqwswnkbb22eoajke4t72qvxrp3rpqaotymbqsnlqkz5ovde6m"),
"storagepower": MustParseCid("bafk2bzacea4c3h6gnhgfcjf6lxhzcmp5qq7kgrcym7wv4vcnmd4whegpjdwuq"),
"system": MustParseCid("bafk2bzacechwe3ehay6h7x7tecaajgsxrvvmzcdul6omejfvzf4mpbzkuryhm"),
"verifiedregistry": MustParseCid("bafk2bzacec66mmy7sj6qy5urqplwhbem7wbjrzna7mxh6qbdljdawhu3g5rao"),
},
}, {
Network: "testing-fake-proofs",
@ -1087,24 +1087,24 @@ var EmbeddedBuiltinActorsMetadata = []*BuiltinActorsMetadata{{
}, {
Network: "testing-fake-proofs",
Version: 14,
BundleGitTag: "v13.0.0",
ManifestCid: MustParseCid("bafy2bzaceaf7fz33sp2i5ag5xg5ompn3dwppqlbwfacrwuvzaqdbqrtni7m5q"),
BundleGitTag: "v14.0.0-rc.1",
ManifestCid: MustParseCid("bafy2bzacebca2c7r6m47fv5ojbzfgqxw74zxyzphlkxigj75q7vobbe6vm4x4"),
Actors: map[string]cid.Cid{
"account": MustParseCid("bafk2bzaceb3tncntgeqvzzr5fzhvpsc5ntv3tpqrsh4jst4irfyzpkdyigibc"),
"cron": MustParseCid("bafk2bzacecwwasmhixpgtshczm5cfspwciyawc25mrefknqhlxfrd6m57tqmc"),
"datacap": MustParseCid("bafk2bzaceckj66by6eohjrybazh5cymmovgl5bmikpvzki2q7huwk2fweoef2"),
"eam": MustParseCid("bafk2bzaceafzm65wvnaam3775homn4vzsv7odftn5tkifmn44wd2t6gupy63y"),
"ethaccount": MustParseCid("bafk2bzaced4q7m4mha2dsezhwub3ru64rgimkg52t25ul4gnekax6uq7hbkqu"),
"evm": MustParseCid("bafk2bzaceakpknw5cuizil3552jr5z35rs6ijaignjigciswtok67drhzdss6"),
"init": MustParseCid("bafk2bzacec7mbkemwugyg2p4oy2xgnovykk4dnsu5ym4wkreooujvxfsxbo3i"),
"multisig": MustParseCid("bafk2bzacedy4vldq4viv6bzzh4fueip3by3axsbgbh655lashddgumknc6pvs"),
"paymentchannel": MustParseCid("bafk2bzaceau57wpiiikea6pu5om4ryyqjrxjzfksfl4reqosnohydzv3pf4qq"),
"account": MustParseCid("bafk2bzacedz5ko33xyknznoj5mcwnijhggapvn7hzmec3ix3vlqjg6uuwownm"),
"cron": MustParseCid("bafk2bzacebifywvakusxpvnzn33qneqm46g3trnqvuvaw5cgslfg5cl7prtwa"),
"datacap": MustParseCid("bafk2bzacedx4zxq5ae6qbucm6elokqhhmlwbtas7mbqm6rnigwkmorrtfzo66"),
"eam": MustParseCid("bafk2bzaceavilsrvq7kdyqelapjabixsgmhf6caufc4hdyviccmerf3sawzdk"),
"ethaccount": MustParseCid("bafk2bzaceavutdrzkspoiz6a5m46m2qzqbsmdb33s62xnkpevuwjrhxm6trn2"),
"evm": MustParseCid("bafk2bzacedovnz466nuqdp5pzs6sztcqofsy5zet7k2gybnbelpwuxpmfphwo"),
"init": MustParseCid("bafk2bzaceajnftptl2tdbrudshriqcg3caw5mqublmd6i5dm3qug3j5qo7g4q"),
"multisig": MustParseCid("bafk2bzacecaioywepaxgtrpkmr7k2bjlwcpj6mu3r7ctk77a3sqwrb72wn4ra"),
"paymentchannel": MustParseCid("bafk2bzacebmtufrtdxo757c6c5ndmsk3wlnzzuzqp4yzbtltqjutnlgh7awus"),
"placeholder": MustParseCid("bafk2bzacedfvut2myeleyq67fljcrw4kkmn5pb5dpyozovj7jpoez5irnc3ro"),
"reward": MustParseCid("bafk2bzacecvlcdgbqlk3dyfzkcjrywg2th5bmn7ilijifikulpxr4ffcrw23o"),
"storagemarket": MustParseCid("bafk2bzacecgj53dwqla7eiubs2uiza7cgxkxtefxkfpjontj5jxefl3a4i2nq"),
"storageminer": MustParseCid("bafk2bzaceb6atn3k6yhmskgmc3lgfiwpzpfmaxzacohtnb2hivme2oroycqr6"),
"storagepower": MustParseCid("bafk2bzacedameh56mp2g4y7nprhax5sddbzcmpk5p7l523l45rtn2wjc6ah4e"),
"system": MustParseCid("bafk2bzaceby6aiiosnrtb5kzlmrvd4k3o27oo3idmbd6llydz2uqibbp23pzq"),
"verifiedregistry": MustParseCid("bafk2bzaceadw6mxuyb6ipaq3fhekk7u5osyyiis3c4wbkvysy2ut6qfsua5zs"),
"reward": MustParseCid("bafk2bzacebtnflocubjjrtvzba4tmrn32tlx2klfgmjreqeo234lqdzu4ovna"),
"storagemarket": MustParseCid("bafk2bzacec6tovj5vh6lyor3m67uhahhldrixnqg7e5246pce5gcwkqwmbvxo"),
"storageminer": MustParseCid("bafk2bzacecgckzurejgtbw2xfmys5talfq5sloia2mrjcdsl5xolbwkolkrss"),
"storagepower": MustParseCid("bafk2bzacea4c3h6gnhgfcjf6lxhzcmp5qq7kgrcym7wv4vcnmd4whegpjdwuq"),
"system": MustParseCid("bafk2bzacechwe3ehay6h7x7tecaajgsxrvvmzcdul6omejfvzf4mpbzkuryhm"),
"verifiedregistry": MustParseCid("bafk2bzacec66mmy7sj6qy5urqplwhbem7wbjrzna7mxh6qbdljdawhu3g5rao"),
},
}}

File diff suppressed because it is too large Load Diff

View File

@ -2,7 +2,7 @@
"openrpc": "1.2.6",
"info": {
"title": "Lotus RPC API",
"version": "1.27.1"
"version": "1.28.0-rc1"
},
"methods": [
{
@ -242,7 +242,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3771"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3811"
}
},
{
@ -473,7 +473,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3782"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3822"
}
},
{
@ -572,7 +572,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3793"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3833"
}
},
{
@ -604,7 +604,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3804"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3844"
}
},
{
@ -710,7 +710,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3815"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3855"
}
},
{
@ -803,7 +803,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3826"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3866"
}
},
{
@ -887,7 +887,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3837"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3877"
}
},
{
@ -987,7 +987,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3848"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3888"
}
},
{
@ -1043,7 +1043,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3859"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3899"
}
},
{
@ -1116,7 +1116,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3870"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3910"
}
},
{
@ -1189,7 +1189,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3881"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3921"
}
},
{
@ -1236,7 +1236,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3892"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3932"
}
},
{
@ -1268,7 +1268,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3903"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3943"
}
},
{
@ -1305,7 +1305,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3925"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3965"
}
},
{
@ -1352,7 +1352,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3936"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3976"
}
},
{
@ -1392,7 +1392,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3947"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3987"
}
},
{
@ -1439,7 +1439,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3958"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3998"
}
},
{
@ -1494,7 +1494,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3969"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4009"
}
},
{
@ -1523,7 +1523,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3980"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4020"
}
},
{
@ -1660,7 +1660,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3991"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4031"
}
},
{
@ -1689,7 +1689,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4002"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4042"
}
},
{
@ -1743,7 +1743,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4013"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4053"
}
},
{
@ -1834,7 +1834,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4024"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4064"
}
},
{
@ -1862,7 +1862,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4035"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4075"
}
},
{
@ -1952,7 +1952,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4046"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4086"
}
},
{
@ -2208,7 +2208,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4057"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4097"
}
},
{
@ -2453,7 +2453,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4068"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4108"
}
},
{
@ -2509,7 +2509,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4079"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4119"
}
},
{
@ -2556,7 +2556,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4090"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4130"
}
},
{
@ -2654,7 +2654,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4101"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4141"
}
},
{
@ -2720,7 +2720,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4112"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4152"
}
},
{
@ -2786,7 +2786,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4123"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4163"
}
},
{
@ -2895,7 +2895,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4134"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4174"
}
},
{
@ -2953,7 +2953,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4145"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4185"
}
},
{
@ -3075,7 +3075,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4156"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4196"
}
},
{
@ -3267,7 +3267,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4167"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4207"
}
},
{
@ -3476,7 +3476,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4178"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4218"
}
},
{
@ -3567,7 +3567,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4189"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4229"
}
},
{
@ -3625,7 +3625,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4200"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4240"
}
},
{
@ -3883,7 +3883,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4211"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4251"
}
},
{
@ -4158,7 +4158,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4222"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4262"
}
},
{
@ -4186,7 +4186,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4233"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4273"
}
},
{
@ -4224,7 +4224,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4244"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4284"
}
},
{
@ -4332,7 +4332,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4255"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4295"
}
},
{
@ -4370,7 +4370,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4266"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4306"
}
},
{
@ -4399,7 +4399,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4277"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4317"
}
},
{
@ -4462,7 +4462,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4288"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4328"
}
},
{
@ -4525,7 +4525,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4299"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4339"
}
},
{
@ -4570,7 +4570,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4310"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4350"
}
},
{
@ -4692,7 +4692,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4321"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4361"
}
},
{
@ -4847,7 +4847,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4332"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4372"
}
},
{
@ -4969,7 +4969,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4343"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4383"
}
},
{
@ -5023,7 +5023,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4354"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4394"
}
},
{
@ -5077,7 +5077,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4365"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4405"
}
},
{
@ -5132,7 +5132,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4376"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4416"
}
},
{
@ -5234,7 +5234,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4387"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4427"
}
},
{
@ -5457,7 +5457,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4398"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4438"
}
},
{
@ -5640,7 +5640,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4409"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4449"
}
},
{
@ -5834,7 +5834,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4420"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4460"
}
},
{
@ -5880,7 +5880,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4431"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4471"
}
},
{
@ -6030,7 +6030,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4442"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4482"
}
},
{
@ -6167,7 +6167,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4453"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4493"
}
},
{
@ -6235,7 +6235,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4464"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4504"
}
},
{
@ -6352,7 +6352,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4475"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4515"
}
},
{
@ -6443,7 +6443,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4486"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4526"
}
},
{
@ -6529,7 +6529,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4497"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4537"
}
},
{
@ -6556,7 +6556,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4508"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4548"
}
},
{
@ -6583,7 +6583,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4519"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4559"
}
},
{
@ -6651,7 +6651,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4530"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4570"
}
},
{
@ -6830,7 +6830,7 @@
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -6870,7 +6870,7 @@
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -6940,10 +6940,6 @@
"State": {
"additionalProperties": false,
"properties": {
"Address": {
"additionalProperties": false,
"type": "object"
},
"Balance": {
"additionalProperties": false,
"type": "object"
@ -6952,6 +6948,10 @@
"title": "Content Identifier",
"type": "string"
},
"DelegatedAddress": {
"additionalProperties": false,
"type": "object"
},
"Head": {
"title": "Content Identifier",
"type": "string"
@ -7157,7 +7157,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4541"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4581"
}
},
{
@ -7254,7 +7254,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4552"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4592"
}
},
{
@ -7354,7 +7354,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4563"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4603"
}
},
{
@ -7418,15 +7418,11 @@
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
],
"additionalProperties": false,
"properties": {
"Address": {
"additionalProperties": false,
"type": "object"
},
"Balance": {
"additionalProperties": false,
"type": "object"
@ -7435,6 +7431,10 @@
"title": "Content Identifier",
"type": "string"
},
"DelegatedAddress": {
"additionalProperties": false,
"type": "object"
},
"Head": {
"title": "Content Identifier",
"type": "string"
@ -7454,7 +7454,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4574"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4614"
}
},
{
@ -7579,7 +7579,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4585"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4625"
}
},
{
@ -7688,7 +7688,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4596"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4636"
}
},
{
@ -7791,7 +7791,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4607"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4647"
}
},
{
@ -7921,7 +7921,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4618"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4658"
}
},
{
@ -8028,7 +8028,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4629"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4669"
}
},
{
@ -8089,7 +8089,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4640"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4680"
}
},
{
@ -8157,7 +8157,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4651"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4691"
}
},
{
@ -8238,7 +8238,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4662"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4702"
}
},
{
@ -8402,7 +8402,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4673"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4713"
}
},
{
@ -8495,7 +8495,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4684"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4724"
}
},
{
@ -8696,7 +8696,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4695"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4735"
}
},
{
@ -8807,7 +8807,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4706"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4746"
}
},
{
@ -8938,7 +8938,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4717"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4757"
}
},
{
@ -9024,7 +9024,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4728"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4768"
}
},
{
@ -9051,7 +9051,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4739"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4779"
}
},
{
@ -9104,7 +9104,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4750"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4790"
}
},
{
@ -9192,7 +9192,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4761"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4801"
}
},
{
@ -9316,7 +9316,7 @@
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -9356,7 +9356,7 @@
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -9426,10 +9426,6 @@
"State": {
"additionalProperties": false,
"properties": {
"Address": {
"additionalProperties": false,
"type": "object"
},
"Balance": {
"additionalProperties": false,
"type": "object"
@ -9438,6 +9434,10 @@
"title": "Content Identifier",
"type": "string"
},
"DelegatedAddress": {
"additionalProperties": false,
"type": "object"
},
"Head": {
"title": "Content Identifier",
"type": "string"
@ -9643,7 +9643,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4772"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4812"
}
},
{
@ -9810,7 +9810,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4783"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4823"
}
},
{
@ -9983,7 +9983,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4794"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4834"
}
},
{
@ -10051,7 +10051,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4805"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4845"
}
},
{
@ -10119,7 +10119,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4816"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4856"
}
},
{
@ -10280,7 +10280,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4827"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4867"
}
},
{
@ -10325,7 +10325,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4849"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4889"
}
},
{
@ -10370,7 +10370,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4860"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4900"
}
},
{
@ -10397,7 +10397,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4871"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4911"
}
}
]

View File

@ -2,7 +2,7 @@
"openrpc": "1.2.6",
"info": {
"title": "Lotus RPC API",
"version": "1.27.1"
"version": "1.28.0-rc1"
},
"methods": [
{
@ -30,7 +30,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5157"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5197"
}
},
{
@ -109,7 +109,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5168"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5208"
}
},
{
@ -155,7 +155,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5179"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5219"
}
},
{
@ -203,7 +203,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5190"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5230"
}
},
{
@ -251,7 +251,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5201"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5241"
}
},
{
@ -354,7 +354,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5212"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5252"
}
},
{
@ -428,7 +428,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5223"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5263"
}
},
{
@ -591,7 +591,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5234"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5274"
}
},
{
@ -742,7 +742,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5245"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5285"
}
},
{
@ -781,7 +781,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5256"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5296"
}
},
{
@ -913,7 +913,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5267"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5307"
}
},
{
@ -945,7 +945,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5278"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5318"
}
},
{
@ -986,7 +986,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5289"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5329"
}
},
{
@ -1054,7 +1054,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5300"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5340"
}
},
{
@ -1185,7 +1185,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5311"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5351"
}
},
{
@ -1316,7 +1316,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5322"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5362"
}
},
{
@ -1416,7 +1416,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5333"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5373"
}
},
{
@ -1516,7 +1516,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5344"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5384"
}
},
{
@ -1616,7 +1616,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5355"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5395"
}
},
{
@ -1716,7 +1716,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5366"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5406"
}
},
{
@ -1816,7 +1816,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5377"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5417"
}
},
{
@ -1916,7 +1916,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5388"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5428"
}
},
{
@ -2040,7 +2040,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5399"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5439"
}
},
{
@ -2164,7 +2164,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5410"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5450"
}
},
{
@ -2279,7 +2279,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5421"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5461"
}
},
{
@ -2379,7 +2379,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5432"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5472"
}
},
{
@ -2512,7 +2512,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5443"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5483"
}
},
{
@ -2636,7 +2636,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5454"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5494"
}
},
{
@ -2760,7 +2760,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5465"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5505"
}
},
{
@ -2884,7 +2884,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5476"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5516"
}
},
{
@ -3017,7 +3017,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5487"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5527"
}
},
{
@ -3117,7 +3117,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5498"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5538"
}
},
{
@ -3157,7 +3157,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5509"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5549"
}
},
{
@ -3229,7 +3229,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5520"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5560"
}
},
{
@ -3279,7 +3279,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5531"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5571"
}
},
{
@ -3323,7 +3323,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5542"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5582"
}
},
{
@ -3364,7 +3364,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5553"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5593"
}
},
{
@ -3608,7 +3608,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5564"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5604"
}
},
{
@ -3682,7 +3682,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5575"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5615"
}
},
{
@ -3732,7 +3732,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5586"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5626"
}
},
{
@ -3761,7 +3761,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5597"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5637"
}
},
{
@ -3790,7 +3790,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5608"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5648"
}
},
{
@ -3846,7 +3846,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5619"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5659"
}
},
{
@ -3869,7 +3869,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5630"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5670"
}
},
{
@ -3929,7 +3929,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5641"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5681"
}
},
{
@ -3968,7 +3968,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5652"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5692"
}
},
{
@ -4008,7 +4008,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5663"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5703"
}
},
{
@ -4081,7 +4081,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5674"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5714"
}
},
{
@ -4145,7 +4145,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5685"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5725"
}
},
{
@ -4208,7 +4208,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5696"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5736"
}
},
{
@ -4258,7 +4258,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5707"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5747"
}
},
{
@ -4817,7 +4817,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5718"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5758"
}
},
{
@ -4858,7 +4858,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5729"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5769"
}
},
{
@ -4899,7 +4899,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5740"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5780"
}
},
{
@ -4940,7 +4940,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5751"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5791"
}
},
{
@ -4981,7 +4981,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5762"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5802"
}
},
{
@ -5022,7 +5022,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5773"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5813"
}
},
{
@ -5053,7 +5053,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5784"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5824"
}
},
{
@ -5103,7 +5103,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5795"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5835"
}
},
{
@ -5144,7 +5144,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5806"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5846"
}
},
{
@ -5183,7 +5183,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5817"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5857"
}
},
{
@ -5247,7 +5247,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5828"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5868"
}
},
{
@ -5305,7 +5305,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5839"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5879"
}
},
{
@ -5752,7 +5752,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5850"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5890"
}
},
{
@ -5788,7 +5788,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5861"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5901"
}
},
{
@ -5931,7 +5931,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5872"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5912"
}
},
{
@ -5987,7 +5987,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5883"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5923"
}
},
{
@ -6026,7 +6026,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5894"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5934"
}
},
{
@ -6203,7 +6203,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5905"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5945"
}
},
{
@ -6255,7 +6255,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5916"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5956"
}
},
{
@ -6447,7 +6447,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5927"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5967"
}
},
{
@ -6547,7 +6547,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5938"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5978"
}
},
{
@ -6601,7 +6601,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5949"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5989"
}
},
{
@ -6640,7 +6640,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5960"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6000"
}
},
{
@ -6725,7 +6725,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5971"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6011"
}
},
{
@ -6919,7 +6919,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5982"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6022"
}
},
{
@ -7017,7 +7017,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5993"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6033"
}
},
{
@ -7149,7 +7149,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6004"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6044"
}
},
{
@ -7203,7 +7203,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6015"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6055"
}
},
{
@ -7237,7 +7237,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6026"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6066"
}
},
{
@ -7324,7 +7324,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6037"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6077"
}
},
{
@ -7378,7 +7378,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6048"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6088"
}
},
{
@ -7478,7 +7478,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6059"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6099"
}
},
{
@ -7555,7 +7555,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6070"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6110"
}
},
{
@ -7646,7 +7646,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6081"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6121"
}
},
{
@ -7685,7 +7685,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6092"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6132"
}
},
{
@ -7801,7 +7801,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6103"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6143"
}
},
{
@ -9901,7 +9901,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6114"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6154"
}
}
]

View File

@ -2,7 +2,7 @@
"openrpc": "1.2.6",
"info": {
"title": "Lotus RPC API",
"version": "1.27.1"
"version": "1.28.0-rc1"
},
"methods": [
{
@ -161,7 +161,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6202"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6242"
}
},
{
@ -252,7 +252,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6213"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6253"
}
},
{
@ -420,7 +420,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6224"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6264"
}
},
{
@ -447,7 +447,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6235"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6275"
}
},
{
@ -597,7 +597,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6246"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6286"
}
},
{
@ -700,7 +700,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6257"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6297"
}
},
{
@ -803,7 +803,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6268"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6308"
}
},
{
@ -925,7 +925,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6279"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6319"
}
},
{
@ -1135,7 +1135,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6290"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6330"
}
},
{
@ -1306,7 +1306,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6301"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6341"
}
},
{
@ -3350,7 +3350,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6312"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6352"
}
},
{
@ -3470,7 +3470,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6323"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6363"
}
},
{
@ -3531,7 +3531,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6334"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6374"
}
},
{
@ -3569,7 +3569,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6345"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6385"
}
},
{
@ -3729,7 +3729,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6356"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6396"
}
},
{
@ -3913,7 +3913,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6367"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6407"
}
},
{
@ -4054,7 +4054,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6378"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6418"
}
},
{
@ -4107,7 +4107,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6389"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6429"
}
},
{
@ -4250,7 +4250,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6400"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6440"
}
},
{
@ -4474,7 +4474,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6411"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6451"
}
},
{
@ -4601,7 +4601,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6422"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6462"
}
},
{
@ -4768,7 +4768,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6433"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6473"
}
},
{
@ -4895,7 +4895,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6444"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6484"
}
},
{
@ -4933,7 +4933,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6455"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6495"
}
},
{
@ -4972,7 +4972,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6466"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6506"
}
},
{
@ -4995,7 +4995,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6477"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6517"
}
},
{
@ -5034,7 +5034,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6488"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6528"
}
},
{
@ -5057,7 +5057,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6499"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6539"
}
},
{
@ -5096,7 +5096,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6510"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6550"
}
},
{
@ -5130,7 +5130,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6521"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6561"
}
},
{
@ -5184,7 +5184,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6532"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6572"
}
},
{
@ -5223,7 +5223,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6543"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6583"
}
},
{
@ -5262,7 +5262,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6554"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6594"
}
},
{
@ -5297,7 +5297,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6565"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6605"
}
},
{
@ -5477,7 +5477,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6576"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6616"
}
},
{
@ -5506,7 +5506,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6587"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6627"
}
},
{
@ -5529,7 +5529,7 @@
"deprecated": false,
"externalDocs": {
"description": "Github remote link",
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6598"
"url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6638"
}
}
]

View File

@ -71,7 +71,7 @@ var UpgradeDragonHeight = abi.ChainEpoch(-24)
var UpgradePhoenixHeight = abi.ChainEpoch(-25)
var UpgradeAussieHeight = abi.ChainEpoch(200)
var UpgradeWaffleHeight = abi.ChainEpoch(200)
// This fix upgrade only ran on calibrationnet
const UpgradeWatermelonFixHeight = -100
@ -156,7 +156,7 @@ func init() {
UpgradeThunderHeight = getUpgradeHeight("LOTUS_THUNDER_HEIGHT", UpgradeThunderHeight)
UpgradeWatermelonHeight = getUpgradeHeight("LOTUS_WATERMELON_HEIGHT", UpgradeWatermelonHeight)
UpgradeDragonHeight = getUpgradeHeight("LOTUS_DRAGON_HEIGHT", UpgradeDragonHeight)
UpgradeAussieHeight = getUpgradeHeight("LOTUS_AUSSIE_HEIGHT", UpgradeAussieHeight)
UpgradeWaffleHeight = getUpgradeHeight("LOTUS_WAFFLE_HEIGHT", UpgradeWaffleHeight)
UpgradePhoenixHeight = getUpgradeHeight("LOTUS_PHOENIX_HEIGHT", UpgradePhoenixHeight)
DrandSchedule = map[abi.ChainEpoch]DrandEnum{
@ -190,3 +190,6 @@ const BootstrapPeerThreshold = 1
const Eip155ChainId = 31415926
var WhitelistedBlock = cid.Undef
const F3Enabled = true
const F3BootstrapEpoch abi.ChainEpoch = 100

View File

@ -20,7 +20,7 @@ var DrandSchedule = map[abi.ChainEpoch]DrandEnum{
UpgradePhoenixHeight: DrandQuicknet,
}
const GenesisNetworkVersion = network.Version21
const GenesisNetworkVersion = network.Version22
var NetworkBundle = "butterflynet"
var BundleOverrides map[actorstypes.Version]string
@ -59,7 +59,7 @@ const UpgradeWatermelonHeight = -24
const UpgradeDragonHeight = -25
const UpgradePhoenixHeight = -26
const UpgradeAussieHeight = 400
const UpgradeWaffleHeight = 100
// This fix upgrade only ran on calibrationnet
const UpgradeWatermelonFixHeight = -100
@ -106,3 +106,6 @@ const BootstrapPeerThreshold = 2
const Eip155ChainId = 3141592
var WhitelistedBlock = cid.Undef
const F3Enabled = true
const F3BootstrapEpoch abi.ChainEpoch = 200

View File

@ -99,7 +99,7 @@ const UpgradePhoenixHeight = UpgradeDragonHeight + 120
const UpgradeCalibrationDragonFixHeight = 1493854
// ?????
const UpgradeAussieHeight = 999999999999999
const UpgradeWaffleHeight = 999999999999999
var SupportedProofTypes = []abi.RegisteredSealProof{
abi.RegisteredSealProof_StackedDrg32GiBV1,
@ -135,7 +135,6 @@ func init() {
}
BuildType = BuildCalibnet
}
const BlockDelaySecs = uint64(builtin2.EpochDurationSeconds)
@ -152,3 +151,6 @@ const BootstrapPeerThreshold = 4
const Eip155ChainId = 314159
var WhitelistedBlock = cid.Undef
const F3Enabled = false
const F3BootstrapEpoch abi.ChainEpoch = -1

View File

@ -25,7 +25,7 @@ var ActorDebugging = false
const BootstrappersFile = "interopnet.pi"
const GenesisFile = "interopnet.car"
const GenesisNetworkVersion = network.Version16
const GenesisNetworkVersion = network.Version22
var UpgradeBreezeHeight = abi.ChainEpoch(-1)
@ -55,10 +55,9 @@ var UpgradeLightningHeight = abi.ChainEpoch(-22)
var UpgradeThunderHeight = abi.ChainEpoch(-23)
var UpgradeWatermelonHeight = abi.ChainEpoch(-24)
var UpgradeDragonHeight = abi.ChainEpoch(-25)
var UpgradePhoenixHeight = abi.ChainEpoch(-26)
const UpgradeAussieHeight = 50
const UpgradePhoenixHeight = UpgradeDragonHeight + 100
const UpgradeWaffleHeight = 50
// This fix upgrade only ran on calibrationnet
const UpgradeWatermelonFixHeight = -1
@ -146,3 +145,6 @@ const BootstrapPeerThreshold = 2
const Eip155ChainId = 3141592
var WhitelistedBlock = cid.Undef
const F3Enabled = true
const F3BootstrapEpoch abi.ChainEpoch = 1000

View File

@ -107,7 +107,7 @@ const UpgradeDragonHeight = 3855360
const UpgradePhoenixHeight = UpgradeDragonHeight + 120
// ??????
var UpgradeAussieHeight = abi.ChainEpoch(9999999999)
var UpgradeWaffleHeight = abi.ChainEpoch(9999999999)
// This fix upgrade only ran on calibrationnet
const UpgradeWatermelonFixHeight = -1
@ -133,8 +133,8 @@ func init() {
SetAddressNetwork(address.Mainnet)
}
if os.Getenv("LOTUS_DISABLE_AUSSIE") == "1" {
UpgradeAussieHeight = math.MaxInt64 - 1
if os.Getenv("LOTUS_DISABLE_WAFFLE") == "1" {
UpgradeWaffleHeight = math.MaxInt64 - 1
}
// NOTE: DO NOT change this unless you REALLY know what you're doing. This is not consensus critical, however,
@ -168,3 +168,6 @@ const Eip155ChainId = 314
// WhitelistedBlock skips checks on message validity in this block to sidestep the zero-bls signature
var WhitelistedBlock = MustParseCid("bafy2bzaceapyg2uyzk7vueh3xccxkuwbz3nxewjyguoxvhx77malc2lzn2ybi")
const F3Enabled = false
const F3BootstrapEpoch abi.ChainEpoch = -1

View File

@ -115,7 +115,7 @@ var (
UpgradeDragonHeight abi.ChainEpoch = -26
UpgradePhoenixHeight abi.ChainEpoch = -27
UpgradeCalibrationDragonFixHeight abi.ChainEpoch = -28
UpgradeAussieHeight abi.ChainEpoch = -29
UpgradeWaffleHeight abi.ChainEpoch = -29
DrandSchedule = map[abi.ChainEpoch]DrandEnum{
0: DrandMainnet,
@ -133,9 +133,11 @@ var (
Devnet = true
ZeroAddress = MustParseAddress("f3yaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaby2smx7a")
WhitelistedBlock = cid.Undef
BootstrappersFile = ""
GenesisFile = ""
WhitelistedBlock = cid.Undef
BootstrappersFile = ""
GenesisFile = ""
F3Enabled = false
F3BootstrapEpoch abi.ChainEpoch = -1
)
const Finality = policy.ChainFinality

View File

@ -39,7 +39,7 @@ func BuildTypeString() string {
}
// NodeBuildVersion is the local build version of the Lotus daemon
const NodeBuildVersion string = "1.27.1"
const NodeBuildVersion string = "1.28.0-rc1"
func NodeUserVersion() BuildVersion {
if os.Getenv("LOTUS_VERSION_IGNORE_COMMIT") == "1" {
@ -50,7 +50,7 @@ func NodeUserVersion() BuildVersion {
}
// MinerBuildVersion is the local build version of the Lotus miner
const MinerBuildVersion = "1.27.1"
const MinerBuildVersion = "1.28.0-rc1"
func MinerUserVersion() BuildVersion {
if os.Getenv("LOTUS_VERSION_IGNORE_COMMIT") == "1" {

View File

@ -8,7 +8,16 @@ import (
"github.com/filecoin-project/go-state-types/network"
)
type SealProofVariant int
const (
SealProofVariant_Standard SealProofVariant = iota
SealProofVariant_Synthetic
SealProofVariant_NonInteractive
)
var MinSyntheticPoRepVersion = network.Version21
var MinNonInteractivePoRepVersion = network.Version23
func AllPartSectors(mas State, sget func(Partition) (bitfield.BitField, error)) (bitfield.BitField, error) {
var parts []bitfield.BitField
@ -33,7 +42,18 @@ func AllPartSectors(mas State, sget func(Partition) (bitfield.BitField, error))
// SealProofTypeFromSectorSize returns preferred seal proof type for creating
// new miner actors and new sectors
func SealProofTypeFromSectorSize(ssize abi.SectorSize, nv network.Version, synthetic bool) (abi.RegisteredSealProof, error) {
func SealProofTypeFromSectorSize(ssize abi.SectorSize, nv network.Version, variant SealProofVariant) (abi.RegisteredSealProof, error) {
switch variant {
case SealProofVariant_Synthetic:
if nv < MinSyntheticPoRepVersion {
return 0, xerrors.Errorf("synthetic proofs are not supported on network version %d", nv)
}
case SealProofVariant_NonInteractive:
if nv < MinNonInteractivePoRepVersion {
return 0, xerrors.Errorf("non-interactive proofs are not supported on network version %d", nv)
}
}
switch {
case nv < network.Version7:
switch ssize {
@ -67,11 +87,13 @@ func SealProofTypeFromSectorSize(ssize abi.SectorSize, nv network.Version, synth
return 0, xerrors.Errorf("unsupported sector size for miner: %v", ssize)
}
if nv >= MinSyntheticPoRepVersion && synthetic {
switch variant {
case SealProofVariant_Synthetic:
return toSynthetic(v)
} else {
return v, nil
case SealProofVariant_NonInteractive:
return toNonInteractive(v)
}
return v, nil
}
return 0, xerrors.Errorf("unsupported network version")
@ -94,6 +116,23 @@ func toSynthetic(in abi.RegisteredSealProof) (abi.RegisteredSealProof, error) {
}
}
func toNonInteractive(in abi.RegisteredSealProof) (abi.RegisteredSealProof, error) {
switch in {
case abi.RegisteredSealProof_StackedDrg2KiBV1_1:
return abi.RegisteredSealProof_StackedDrg2KiBV1_2_Feat_NiPoRep, nil
case abi.RegisteredSealProof_StackedDrg8MiBV1_1:
return abi.RegisteredSealProof_StackedDrg8MiBV1_2_Feat_NiPoRep, nil
case abi.RegisteredSealProof_StackedDrg512MiBV1_1:
return abi.RegisteredSealProof_StackedDrg512MiBV1_2_Feat_NiPoRep, nil
case abi.RegisteredSealProof_StackedDrg32GiBV1_1:
return abi.RegisteredSealProof_StackedDrg32GiBV1_2_Feat_NiPoRep, nil
case abi.RegisteredSealProof_StackedDrg64GiBV1_1:
return abi.RegisteredSealProof_StackedDrg64GiBV1_2_Feat_NiPoRep, nil
default:
return 0, xerrors.Errorf("unsupported conversion to non-interactive: %v", in)
}
}
// WindowPoStProofTypeFromSectorSize returns preferred post proof type for creating
// new miner actors and new sectors
func WindowPoStProofTypeFromSectorSize(ssize abi.SectorSize, nv network.Version) (abi.RegisteredPoStProof, error) {

View File

@ -168,12 +168,12 @@ func IsValidForSending(nv network.Version, act *types.Actor) bool {
// Allow placeholder actors with a delegated address and nonce 0 to send a message.
// These will be converted to an EthAccount actor on first send.
if !builtin.IsPlaceholderActor(act.Code) || act.Nonce != 0 || act.Address == nil || act.Address.Protocol() != address.Delegated {
if !builtin.IsPlaceholderActor(act.Code) || act.Nonce != 0 || act.DelegatedAddress == nil || act.DelegatedAddress.Protocol() != address.Delegated {
return false
}
// Only allow such actors to send if their delegated address is in the EAM's namespace.
id, _, err := varint.FromUvarint(act.Address.Payload())
id, _, err := varint.FromUvarint(act.DelegatedAddress.Payload())
return err == nil && id == builtintypes.EthereumAddressManagerActorID
}

View File

@ -304,7 +304,7 @@ func DefaultUpgradeSchedule() stmgr.UpgradeSchedule {
Network: network.Version22,
Migration: upgradeActorsV13VerifregFix(calibnetv13BuggyVerifregCID1, calibnetv13CorrectManifestCID1),
}, {
Height: build.UpgradeAussieHeight,
Height: build.UpgradeWaffleHeight,
Network: network.Version23,
Migration: UpgradeActorsV14,
PreMigrations: []stmgr.PreMigration{{
@ -2115,11 +2115,11 @@ func buildUpgradeActorsV12MinerFix(oldBuggyMinerCID, newManifestCID cid.Cid) fun
}
return actorsOut.SetActor(a, &types.ActorV5{
Code: newCid,
Head: actor.Head,
Nonce: actor.Nonce,
Balance: actor.Balance,
Address: actor.Address,
Code: newCid,
Head: actor.Head,
Nonce: actor.Nonce,
Balance: actor.Balance,
DelegatedAddress: actor.DelegatedAddress,
})
})
if err != nil {
@ -2153,8 +2153,8 @@ func buildUpgradeActorsV12MinerFix(oldBuggyMinerCID, newManifestCID cid.Cid) fun
return xerrors.Errorf("mismatched balance for actor %s: %d != %d", a, inActor.Balance, outActor.Balance)
}
if inActor.Address != outActor.Address && inActor.Address.String() != outActor.Address.String() {
return xerrors.Errorf("mismatched address for actor %s: %s != %s", a, inActor.Address, outActor.Address)
if inActor.DelegatedAddress != outActor.DelegatedAddress && inActor.DelegatedAddress.String() != outActor.DelegatedAddress.String() {
return xerrors.Errorf("mismatched address for actor %s: %s != %s", a, inActor.DelegatedAddress, outActor.DelegatedAddress)
}
if inActor.Head != outActor.Head && a != builtin.SystemActorAddr {
@ -2413,11 +2413,11 @@ func upgradeActorsV13VerifregFix(oldBuggyVerifregCID, newManifestCID cid.Cid) fu
}
return actorsOut.SetActor(a, &types.ActorV5{
Code: newCid,
Head: actor.Head,
Nonce: actor.Nonce,
Balance: actor.Balance,
Address: actor.Address,
Code: newCid,
Head: actor.Head,
Nonce: actor.Nonce,
Balance: actor.Balance,
DelegatedAddress: actor.DelegatedAddress,
})
})
if err != nil {
@ -2451,8 +2451,8 @@ func upgradeActorsV13VerifregFix(oldBuggyVerifregCID, newManifestCID cid.Cid) fu
return xerrors.Errorf("mismatched balance for actor %s: %d != %d", a, inActor.Balance, outActor.Balance)
}
if inActor.Address != outActor.Address && inActor.Address.String() != outActor.Address.String() {
return xerrors.Errorf("mismatched address for actor %s: %s != %s", a, inActor.Address, outActor.Address)
if inActor.DelegatedAddress != outActor.DelegatedAddress && inActor.DelegatedAddress.String() != outActor.DelegatedAddress.String() {
return xerrors.Errorf("mismatched address for actor %s: %s != %s", a, inActor.DelegatedAddress, outActor.DelegatedAddress)
}
if inActor.Head != outActor.Head && a != builtin.SystemActorAddr {

View File

@ -7,6 +7,7 @@ import (
"fmt"
"sort"
"strings"
"sync"
"time"
"github.com/ipfs/go-cid"
@ -62,9 +63,13 @@ var ddls = []string{
value BLOB NOT NULL
)`,
createTableEventsSeen,
createIndexEventEntryIndexedKey,
createIndexEventEntryCodecValue,
createIndexEventEntryEventId,
createIndexEventsSeenHeight,
createIndexEventsSeenTipsetKeyCid,
// metadata containing version of schema
`CREATE TABLE IF NOT EXISTS _meta (
@ -76,6 +81,7 @@ var ddls = []string{
`INSERT OR IGNORE INTO _meta (version) VALUES (3)`,
`INSERT OR IGNORE INTO _meta (version) VALUES (4)`,
`INSERT OR IGNORE INTO _meta (version) VALUES (5)`,
`INSERT OR IGNORE INTO _meta (version) VALUES (6)`,
}
var (
@ -83,13 +89,19 @@ var (
)
const (
schemaVersion = 5
schemaVersion = 6
eventExists = `SELECT MAX(id) FROM event WHERE height=? AND tipset_key=? AND tipset_key_cid=? AND emitter_addr=? AND event_index=? AND message_cid=? AND message_index=?`
insertEvent = `INSERT OR IGNORE INTO event(height, tipset_key, tipset_key_cid, emitter_addr, event_index, message_cid, message_index, reverted) VALUES(?, ?, ?, ?, ?, ?, ?, ?)`
insertEntry = `INSERT OR IGNORE INTO event_entry(event_id, indexed, flags, key, codec, value) VALUES(?, ?, ?, ?, ?, ?)`
revertEventsInTipset = `UPDATE event SET reverted=true WHERE height=? AND tipset_key=?`
restoreEvent = `UPDATE event SET reverted=false WHERE height=? AND tipset_key=? AND tipset_key_cid=? AND emitter_addr=? AND event_index=? AND message_cid=? AND message_index=?`
revertEventSeen = `UPDATE events_seen SET reverted=true WHERE height=? AND tipset_key_cid=?`
restoreEventSeen = `UPDATE events_seen SET reverted=false WHERE height=? AND tipset_key_cid=?`
upsertEventsSeen = `INSERT INTO events_seen(height, tipset_key_cid, reverted) VALUES(?, ?, false) ON CONFLICT(height, tipset_key_cid) DO UPDATE SET reverted=false`
isTipsetProcessed = `SELECT COUNT(*) > 0 FROM events_seen WHERE tipset_key_cid=?`
getMaxHeightInIndex = `SELECT MAX(height) FROM events_seen`
isHeightProcessed = `SELECT COUNT(*) > 0 FROM events_seen WHERE height=?`
createIndexEventEmitterAddr = `CREATE INDEX IF NOT EXISTS event_emitter_addr ON event (emitter_addr)`
createIndexEventTipsetKeyCid = `CREATE INDEX IF NOT EXISTS event_tipset_key_cid ON event (tipset_key_cid);`
@ -99,6 +111,17 @@ const (
createIndexEventEntryIndexedKey = `CREATE INDEX IF NOT EXISTS event_entry_indexed_key ON event_entry (indexed, key);`
createIndexEventEntryCodecValue = `CREATE INDEX IF NOT EXISTS event_entry_codec_value ON event_entry (codec, value);`
createIndexEventEntryEventId = `CREATE INDEX IF NOT EXISTS event_entry_event_id ON event_entry(event_id);`
createTableEventsSeen = `CREATE TABLE IF NOT EXISTS events_seen (
id INTEGER PRIMARY KEY,
height INTEGER NOT NULL,
tipset_key_cid BLOB NOT NULL,
reverted INTEGER NOT NULL,
UNIQUE(height, tipset_key_cid)
)`
createIndexEventsSeenHeight = `CREATE INDEX IF NOT EXISTS events_seen_height ON events_seen (height);`
createIndexEventsSeenTipsetKeyCid = `CREATE INDEX IF NOT EXISTS events_seen_tipset_key_cid ON events_seen (tipset_key_cid);`
)
type EventIndex struct {
@ -109,8 +132,27 @@ type EventIndex struct {
stmtInsertEntry *sql.Stmt
stmtRevertEventsInTipset *sql.Stmt
stmtRestoreEvent *sql.Stmt
stmtUpsertEventsSeen *sql.Stmt
stmtRevertEventSeen *sql.Stmt
stmtRestoreEventSeen *sql.Stmt
stmtIsTipsetProcessed *sql.Stmt
stmtGetMaxHeightInIndex *sql.Stmt
stmtIsHeightProcessed *sql.Stmt
mu sync.Mutex
subIdCounter uint64
updateSubs map[uint64]*updateSub
}
type updateSub struct {
ctx context.Context
ch chan EventIndexUpdated
cancel context.CancelFunc
}
type EventIndexUpdated struct{}
func (ei *EventIndex) initStatements() (err error) {
ei.stmtEventExists, err = ei.db.Prepare(eventExists)
if err != nil {
@ -137,6 +179,36 @@ func (ei *EventIndex) initStatements() (err error) {
return xerrors.Errorf("prepare stmtRestoreEvent: %w", err)
}
ei.stmtUpsertEventsSeen, err = ei.db.Prepare(upsertEventsSeen)
if err != nil {
return xerrors.Errorf("prepare stmtUpsertEventsSeen: %w", err)
}
ei.stmtRevertEventSeen, err = ei.db.Prepare(revertEventSeen)
if err != nil {
return xerrors.Errorf("prepare stmtRevertEventSeen: %w", err)
}
ei.stmtRestoreEventSeen, err = ei.db.Prepare(restoreEventSeen)
if err != nil {
return xerrors.Errorf("prepare stmtRestoreEventSeen: %w", err)
}
ei.stmtIsTipsetProcessed, err = ei.db.Prepare(isTipsetProcessed)
if err != nil {
return xerrors.Errorf("prepare isTipsetProcessed: %w", err)
}
ei.stmtGetMaxHeightInIndex, err = ei.db.Prepare(getMaxHeightInIndex)
if err != nil {
return xerrors.Errorf("prepare getMaxHeightInIndex: %w", err)
}
ei.stmtIsHeightProcessed, err = ei.db.Prepare(isHeightProcessed)
if err != nil {
return xerrors.Errorf("prepare isHeightProcessed: %w", err)
}
return nil
}
@ -402,9 +474,59 @@ func (ei *EventIndex) migrateToVersion5(ctx context.Context) error {
return xerrors.Errorf("commit transaction: %w", err)
}
log.Infof("Successfully migrated event index from version 4 to version 5 in %s", time.Since(now))
return nil
}
func (ei *EventIndex) migrateToVersion6(ctx context.Context) error {
now := time.Now()
tx, err := ei.db.BeginTx(ctx, nil)
if err != nil {
return xerrors.Errorf("begin transaction: %w", err)
}
defer func() { _ = tx.Rollback() }()
stmtCreateTableEventsSeen, err := tx.PrepareContext(ctx, createTableEventsSeen)
if err != nil {
return xerrors.Errorf("prepare stmtCreateTableEventsSeen: %w", err)
}
_, err = stmtCreateTableEventsSeen.ExecContext(ctx)
if err != nil {
return xerrors.Errorf("create table events_seen: %w", err)
}
_, err = tx.ExecContext(ctx, createIndexEventsSeenHeight)
if err != nil {
return xerrors.Errorf("create index events_seen_height: %w", err)
}
_, err = tx.ExecContext(ctx, createIndexEventsSeenTipsetKeyCid)
if err != nil {
return xerrors.Errorf("create index events_seen_tipset_key_cid: %w", err)
}
// INSERT an entry in the events_seen table for all epochs we do have events for in our DB
_, err = tx.ExecContext(ctx, `
INSERT OR IGNORE INTO events_seen (height, tipset_key_cid, reverted)
SELECT DISTINCT height, tipset_key_cid, reverted FROM event
`)
if err != nil {
return xerrors.Errorf("insert events into events_seen: %w", err)
}
_, err = tx.ExecContext(ctx, "INSERT OR IGNORE INTO _meta (version) VALUES (6)")
if err != nil {
return xerrors.Errorf("increment _meta version: %w", err)
}
err = tx.Commit()
if err != nil {
return xerrors.Errorf("commit transaction: %w", err)
}
ei.vacuumDBAndCheckpointWAL(ctx)
log.Infof("Successfully migrated event index from version 4 to version 5 in %s", time.Since(now))
log.Infof("Successfully migrated event index from version 5 to version 6 in %s", time.Since(now))
return nil
}
@ -502,6 +624,16 @@ func NewEventIndex(ctx context.Context, path string, chainStore *store.ChainStor
version = 5
}
if version == 5 {
log.Infof("Upgrading event index from version 5 to version 6")
err = eventIndex.migrateToVersion6(ctx)
if err != nil {
_ = db.Close()
return nil, xerrors.Errorf("could not migrate event index schema from version 5 to version 6: %w", err)
}
version = 6
}
if version != schemaVersion {
_ = db.Close()
return nil, xerrors.Errorf("invalid database version: got %d, expected %d", version, schemaVersion)
@ -514,6 +646,8 @@ func NewEventIndex(ctx context.Context, path string, chainStore *store.ChainStor
return nil, xerrors.Errorf("error preparing eventIndex database statements: %w", err)
}
eventIndex.updateSubs = make(map[uint64]*updateSub)
return &eventIndex, nil
}
@ -524,6 +658,60 @@ func (ei *EventIndex) Close() error {
return ei.db.Close()
}
func (ei *EventIndex) SubscribeUpdates() (chan EventIndexUpdated, func()) {
subCtx, subCancel := context.WithCancel(context.Background())
ch := make(chan EventIndexUpdated)
tSub := &updateSub{
ctx: subCtx,
cancel: subCancel,
ch: ch,
}
ei.mu.Lock()
subId := ei.subIdCounter
ei.subIdCounter++
ei.updateSubs[subId] = tSub
ei.mu.Unlock()
unSubscribeF := func() {
ei.mu.Lock()
tSub, ok := ei.updateSubs[subId]
if !ok {
ei.mu.Unlock()
return
}
delete(ei.updateSubs, subId)
ei.mu.Unlock()
// cancel the subscription
tSub.cancel()
}
return tSub.ch, unSubscribeF
}
func (ei *EventIndex) GetMaxHeightInIndex(ctx context.Context) (uint64, error) {
row := ei.stmtGetMaxHeightInIndex.QueryRowContext(ctx)
var maxHeight uint64
err := row.Scan(&maxHeight)
return maxHeight, err
}
func (ei *EventIndex) IsHeightProcessed(ctx context.Context, height uint64) (bool, error) {
row := ei.stmtIsHeightProcessed.QueryRowContext(ctx, height)
var exists bool
err := row.Scan(&exists)
return exists, err
}
func (ei *EventIndex) IsTipsetProcessed(ctx context.Context, tipsetKeyCid []byte) (bool, error) {
row := ei.stmtIsTipsetProcessed.QueryRowContext(ctx, tipsetKeyCid)
var exists bool
err := row.Scan(&exists)
return exists, err
}
func (ei *EventIndex) CollectEvents(ctx context.Context, te *TipSetEvents, revert bool, resolver func(ctx context.Context, emitter abi.ActorID, ts *types.TipSet) (address.Address, bool)) error {
tx, err := ei.db.BeginTx(ctx, nil)
if err != nil {
@ -532,6 +720,11 @@ func (ei *EventIndex) CollectEvents(ctx context.Context, te *TipSetEvents, rever
// rollback the transaction (a no-op if the transaction was already committed)
defer func() { _ = tx.Rollback() }()
tsKeyCid, err := te.msgTs.Key().Cid()
if err != nil {
return xerrors.Errorf("tipset key cid: %w", err)
}
// lets handle the revert case first, since its simpler and we can simply mark all events in this tipset as reverted and return
if revert {
_, err = tx.Stmt(ei.stmtRevertEventsInTipset).Exec(te.msgTs.Height(), te.msgTs.Key().Bytes())
@ -539,11 +732,34 @@ func (ei *EventIndex) CollectEvents(ctx context.Context, te *TipSetEvents, rever
return xerrors.Errorf("revert event: %w", err)
}
_, err = tx.Stmt(ei.stmtRevertEventSeen).Exec(te.msgTs.Height(), tsKeyCid.Bytes())
if err != nil {
return xerrors.Errorf("revert event seen: %w", err)
}
err = tx.Commit()
if err != nil {
return xerrors.Errorf("commit transaction: %w", err)
}
ei.mu.Lock()
tSubs := make([]*updateSub, 0, len(ei.updateSubs))
for _, tSub := range ei.updateSubs {
tSubs = append(tSubs, tSub)
}
ei.mu.Unlock()
for _, tSub := range tSubs {
tSub := tSub
select {
case tSub.ch <- EventIndexUpdated{}:
case <-tSub.ctx.Done():
// subscription was cancelled, ignore
case <-ctx.Done():
return ctx.Err()
}
}
return nil
}
@ -571,11 +787,6 @@ func (ei *EventIndex) CollectEvents(ctx context.Context, te *TipSetEvents, rever
addressLookups[ev.Emitter] = addr
}
tsKeyCid, err := te.msgTs.Key().Cid()
if err != nil {
return xerrors.Errorf("tipset key cid: %w", err)
}
// check if this event already exists in the database
var entryID sql.NullInt64
err = tx.Stmt(ei.stmtEventExists).QueryRow(
@ -655,11 +866,39 @@ func (ei *EventIndex) CollectEvents(ctx context.Context, te *TipSetEvents, rever
}
}
// this statement will mark the tipset as processed and will insert a new row if it doesn't exist
// or update the reverted field to false if it does
_, err = tx.Stmt(ei.stmtUpsertEventsSeen).Exec(
te.msgTs.Height(),
tsKeyCid.Bytes(),
)
if err != nil {
return xerrors.Errorf("exec upsert events seen: %w", err)
}
err = tx.Commit()
if err != nil {
return xerrors.Errorf("commit transaction: %w", err)
}
ei.mu.Lock()
tSubs := make([]*updateSub, 0, len(ei.updateSubs))
for _, tSub := range ei.updateSubs {
tSubs = append(tSubs, tSub)
}
ei.mu.Unlock()
for _, tSub := range tSubs {
tSub := tSub
select {
case tSub.ch <- EventIndexUpdated{}:
case <-tSub.ctx.Done():
// subscription was cancelled, ignore
case <-ctx.Done():
return ctx.Err()
}
}
return nil
}

View File

@ -76,10 +76,50 @@ func TestEventIndexPrefillFilter(t *testing.T) {
ei, err := NewEventIndex(context.Background(), dbPath, nil)
require.NoError(t, err, "create event index")
subCh, unSubscribe := ei.SubscribeUpdates()
defer unSubscribe()
out := make(chan EventIndexUpdated, 1)
go func() {
tu := <-subCh
out <- tu
}()
if err := ei.CollectEvents(context.Background(), events14000, false, addrMap.ResolveAddress); err != nil {
require.NoError(t, err, "collect events")
}
mh, err := ei.GetMaxHeightInIndex(context.Background())
require.NoError(t, err)
require.Equal(t, uint64(14000), mh)
b, err := ei.IsHeightProcessed(context.Background(), 14000)
require.NoError(t, err)
require.True(t, b)
b, err = ei.IsHeightProcessed(context.Background(), 14001)
require.NoError(t, err)
require.False(t, b)
b, err = ei.IsHeightProcessed(context.Background(), 13000)
require.NoError(t, err)
require.False(t, b)
tsKey := events14000.msgTs.Key()
tsKeyCid, err := tsKey.Cid()
require.NoError(t, err, "tipset key cid")
seen, err := ei.IsTipsetProcessed(context.Background(), tsKeyCid.Bytes())
require.NoError(t, err)
require.True(t, seen, "tipset key should be seen")
seen, err = ei.IsTipsetProcessed(context.Background(), []byte{1})
require.NoError(t, err)
require.False(t, seen, "tipset key should not be seen")
_ = <-out
testCases := []struct {
name string
filter *eventFilter
@ -397,6 +437,22 @@ func TestEventIndexPrefillFilterExcludeReverted(t *testing.T) {
ei, err := NewEventIndex(context.Background(), dbPath, nil)
require.NoError(t, err, "create event index")
tCh := make(chan EventIndexUpdated, 3)
subCh, unSubscribe := ei.SubscribeUpdates()
defer unSubscribe()
go func() {
cnt := 0
for tu := range subCh {
tCh <- tu
cnt++
if cnt == 3 {
close(tCh)
return
}
}
}()
if err := ei.CollectEvents(context.Background(), revertedEvents14000, false, addrMap.ResolveAddress); err != nil {
require.NoError(t, err, "collect reverted events")
}
@ -407,6 +463,10 @@ func TestEventIndexPrefillFilterExcludeReverted(t *testing.T) {
require.NoError(t, err, "collect events")
}
_ = <-tCh
_ = <-tCh
_ = <-tCh
inclusiveTestCases := []struct {
name string
filter *eventFilter

View File

@ -378,11 +378,16 @@ func MakeAccountActor(ctx context.Context, cst cbor.IpldStore, av actorstypes.Ve
return nil, xerrors.Errorf("failed to get account actor code ID for actors version %d", av)
}
var delegatedAddr *address.Address
if addr.Protocol() == address.Delegated {
delegatedAddr = &addr
}
act := &types.Actor{
Code: actcid,
Head: statecid,
Balance: bal,
Address: &addr,
Code: actcid,
Head: statecid,
Balance: bal,
DelegatedAddress: delegatedAddr,
}
return act, nil

View File

@ -48,7 +48,6 @@ func SetupEAM(_ context.Context, nst *state.StateTree, nv network.Version) error
Code: codecid,
Head: vm.EmptyObjectCid,
Balance: big.Zero(),
Address: &builtin.EthereumAddressManagerActorAddr, // so that it can create ETH0
}
return nst.SetActor(builtin.EthereumAddressManagerActorAddr, header)
}
@ -60,12 +59,16 @@ func MakeEthNullAddressActor(av actorstypes.Version, addr address.Address) (*typ
return nil, xerrors.Errorf("failed to get EthAccount actor code ID for actors version %d", av)
}
if addr.Protocol() != address.Delegated {
return nil, xerrors.Errorf("eth accounts must have f4 addresses, %s is not an f4 address", addr)
}
act := &types.Actor{
Code: actcid,
Head: vm.EmptyObjectCid,
Nonce: 0,
Balance: big.Zero(),
Address: &addr,
Code: actcid,
Head: vm.EmptyObjectCid,
Nonce: 0,
Balance: big.Zero(),
DelegatedAddress: &addr,
}
return act, nil

View File

@ -18,6 +18,7 @@ import (
"github.com/filecoin-project/go-state-types/big"
builtintypes "github.com/filecoin-project/go-state-types/builtin"
power11 "github.com/filecoin-project/go-state-types/builtin/v11/power"
miner14 "github.com/filecoin-project/go-state-types/builtin/v14/miner"
minertypes "github.com/filecoin-project/go-state-types/builtin/v8/miner"
markettypes "github.com/filecoin-project/go-state-types/builtin/v9/market"
miner9 "github.com/filecoin-project/go-state-types/builtin/v9/miner"
@ -41,6 +42,7 @@ import (
"github.com/filecoin-project/lotus/chain/actors/builtin/miner"
"github.com/filecoin-project/lotus/chain/actors/builtin/power"
"github.com/filecoin-project/lotus/chain/actors/builtin/reward"
"github.com/filecoin-project/lotus/chain/actors/builtin/system"
"github.com/filecoin-project/lotus/chain/actors/policy"
"github.com/filecoin-project/lotus/chain/consensus"
lrand "github.com/filecoin-project/lotus/chain/rand"
@ -136,7 +138,11 @@ func SetupStorageMiners(ctx context.Context, cs *store.ChainStore, sys vm.Syscal
i := i
m := m
spt, err := miner.SealProofTypeFromSectorSize(m.SectorSize, nv, synthetic)
variant := miner.SealProofVariant_Standard
if synthetic {
variant = miner.SealProofVariant_Synthetic
}
spt, err := miner.SealProofTypeFromSectorSize(m.SectorSize, nv, variant)
if err != nil {
return cid.Undef, err
}
@ -491,7 +497,12 @@ func SetupStorageMiners(ctx context.Context, cs *store.ChainStore, sys vm.Syscal
// Commit one-by-one, otherwise pledge math tends to explode
var paramBytes []byte
if av >= actorstypes.Version6 {
if av >= actorstypes.Version14 {
confirmParams := &miner14.InternalSectorSetupForPresealParams{
Sectors: []abi.SectorNumber{preseal.SectorID},
}
paramBytes = mustEnc(confirmParams)
} else if av >= actorstypes.Version6 {
// TODO: fixup
confirmParams := &builtin6.ConfirmSectorProofsParams{
Sectors: []abi.SectorNumber{preseal.SectorID},
@ -506,9 +517,17 @@ func SetupStorageMiners(ctx context.Context, cs *store.ChainStore, sys vm.Syscal
paramBytes = mustEnc(confirmParams)
}
_, err = doExecValue(ctx, genesisVm, minerInfos[i].maddr, power.Address, big.Zero(), builtintypes.MethodsMiner.ConfirmSectorProofsValid, paramBytes)
if err != nil {
return cid.Undef, xerrors.Errorf("failed to confirm presealed sectors: %w", err)
var csErr error
if nv >= network.Version23 {
_, csErr = doExecValue(ctx, genesisVm, minerInfos[i].maddr, system.Address, big.Zero(), builtintypes.MethodsMiner.InternalSectorSetupForPreseal,
paramBytes)
} else {
_, csErr = doExecValue(ctx, genesisVm, minerInfos[i].maddr, power.Address, big.Zero(), builtintypes.MethodsMiner.InternalSectorSetupForPreseal,
paramBytes)
}
if csErr != nil {
return cid.Undef, xerrors.Errorf("failed to confirm presealed sectors: %w", csErr)
}
if av >= actorstypes.Version2 {

213
chain/lf3/ec.go Normal file
View File

@ -0,0 +1,213 @@
package lf3
import (
"context"
"sort"
"time"
"golang.org/x/xerrors"
"github.com/filecoin-project/go-address"
"github.com/filecoin-project/go-f3"
"github.com/filecoin-project/go-f3/gpbft"
"github.com/filecoin-project/go-state-types/abi"
"github.com/filecoin-project/lotus/chain/actors/builtin/miner"
"github.com/filecoin-project/lotus/chain/actors/builtin/power"
"github.com/filecoin-project/lotus/chain/stmgr"
"github.com/filecoin-project/lotus/chain/store"
"github.com/filecoin-project/lotus/chain/types"
"github.com/filecoin-project/lotus/chain/vm"
)
type ecWrapper struct {
ChainStore *store.ChainStore
StateManager *stmgr.StateManager
Manifest f3.Manifest
}
type f3TipSet types.TipSet
func (ts *f3TipSet) cast() *types.TipSet {
return (*types.TipSet)(ts)
}
func (ts *f3TipSet) Key() gpbft.TipSetKey {
return ts.cast().Key().Bytes()
}
func (ts *f3TipSet) Beacon() []byte {
entries := ts.cast().Blocks()[0].BeaconEntries
if len(entries) == 0 {
// Set beacon to a non-nil slice to force the message builder to generate a
// ticket. Otherwise, messages that require ticket, i.e. CONVERGE will fail
// validation due to the absence of ticket. This is a convoluted way of doing it.
// TODO: Rework the F3 message builder APIs to include ticket when needed instead
// of relying on the nil check of beacon.
return []byte{}
}
return entries[len(entries)-1].Data
}
func (ts *f3TipSet) Epoch() int64 {
return int64(ts.cast().Height())
}
func (ts *f3TipSet) Timestamp() time.Time {
return time.Unix(int64(ts.cast().Blocks()[0].Timestamp), 0)
}
func wrapTS(ts *types.TipSet) f3.TipSet {
if ts == nil {
return nil
}
return (*f3TipSet)(ts)
}
// GetTipsetByEpoch should return a tipset before the one requested if the requested
// tipset does not exist due to null epochs
func (ec *ecWrapper) GetTipsetByEpoch(ctx context.Context, epoch int64) (f3.TipSet, error) {
ts, err := ec.ChainStore.GetTipsetByHeight(ctx, abi.ChainEpoch(epoch), nil, true)
if err != nil {
return nil, xerrors.Errorf("getting tipset by height: %w", err)
}
return wrapTS(ts), nil
}
func (ec *ecWrapper) GetTipset(ctx context.Context, tsk gpbft.TipSetKey) (f3.TipSet, error) {
tskLotus, err := types.TipSetKeyFromBytes(tsk)
if err != nil {
return nil, xerrors.Errorf("decoding tsk: %w", err)
}
ts, err := ec.ChainStore.GetTipSetFromKey(ctx, tskLotus)
if err != nil {
return nil, xerrors.Errorf("getting tipset by key: %w", err)
}
return wrapTS(ts), nil
}
func (ec *ecWrapper) GetHead(_ context.Context) (f3.TipSet, error) {
return wrapTS(ec.ChainStore.GetHeaviestTipSet()), nil
}
func (ec *ecWrapper) GetParent(ctx context.Context, tsF3 f3.TipSet) (f3.TipSet, error) {
var ts *types.TipSet
if tsW, ok := tsF3.(*f3TipSet); ok {
ts = tsW.cast()
} else {
// There are only two implementations of F3.TipSet: f3TipSet, and one in fake EC
// backend.
//
// TODO: Revisit the type check here and remove as needed once testing
// is over and fake EC backend goes away.
tskLotus, err := types.TipSetKeyFromBytes(tsF3.Key())
if err != nil {
return nil, xerrors.Errorf("decoding tsk: %w", err)
}
ts, err = ec.ChainStore.GetTipSetFromKey(ctx, tskLotus)
if err != nil {
return nil, xerrors.Errorf("getting tipset by key for get parent: %w", err)
}
}
parentTs, err := ec.ChainStore.GetTipSetFromKey(ctx, ts.Parents())
if err != nil {
return nil, xerrors.Errorf("getting parent tipset: %w", err)
}
return wrapTS(parentTs), nil
}
func (ec *ecWrapper) GetPowerTable(ctx context.Context, tskF3 gpbft.TipSetKey) (gpbft.PowerEntries, error) {
tskLotus, err := types.TipSetKeyFromBytes(tskF3)
if err != nil {
return nil, xerrors.Errorf("decoding tsk: %w", err)
}
ts, err := ec.ChainStore.GetTipSetFromKey(ctx, tskLotus)
if err != nil {
return nil, xerrors.Errorf("getting tipset by key for get parent: %w", err)
}
state, err := ec.StateManager.ParentState(ts)
if err != nil {
return nil, xerrors.Errorf("loading the state tree: %w", err)
}
powerAct, err := state.GetActor(power.Address)
if err != nil {
return nil, xerrors.Errorf("getting the power actor: %w", err)
}
powerState, err := power.Load(ec.ChainStore.ActorStore(ctx), powerAct)
if err != nil {
return nil, xerrors.Errorf("loading power actor state: %w", err)
}
var powerEntries gpbft.PowerEntries
err = powerState.ForEachClaim(func(minerAddr address.Address, claim power.Claim) error {
if claim.QualityAdjPower.Sign() <= 0 {
return nil
}
// TODO: optimize
ok, err := powerState.MinerNominalPowerMeetsConsensusMinimum(minerAddr)
if err != nil {
return xerrors.Errorf("checking consensus minimums: %w", err)
}
if !ok {
return nil
}
id, err := address.IDFromAddress(minerAddr)
if err != nil {
return xerrors.Errorf("transforming address to ID: %w", err)
}
pe := gpbft.PowerEntry{
ID: gpbft.ActorID(id),
Power: claim.QualityAdjPower.Int,
}
act, err := state.GetActor(minerAddr)
if err != nil {
return xerrors.Errorf("(get sset) failed to load miner actor: %w", err)
}
mstate, err := miner.Load(ec.ChainStore.ActorStore(ctx), act)
if err != nil {
return xerrors.Errorf("(get sset) failed to load miner actor state: %w", err)
}
info, err := mstate.Info()
if err != nil {
return xerrors.Errorf("failed to load actor info: %w", err)
}
// check fee debt
if debt, err := mstate.FeeDebt(); err != nil {
return err
} else if !debt.IsZero() {
// fee debt don't add the miner to power table
return nil
}
// check consensus faults
if ts.Height() <= info.ConsensusFaultElapsed {
return nil
}
waddr, err := vm.ResolveToDeterministicAddr(state, ec.ChainStore.ActorStore(ctx), info.Worker)
if err != nil {
return xerrors.Errorf("resolve miner worker address: %w", err)
}
if waddr.Protocol() != address.BLS {
return xerrors.Errorf("wrong type of worker address")
}
pe.PubKey = gpbft.PubKey(waddr.Payload())
powerEntries = append(powerEntries, pe)
return nil
})
if err != nil {
return nil, xerrors.Errorf("collecting the power table: %w", err)
}
sort.Sort(powerEntries)
return powerEntries, nil
}

158
chain/lf3/f3.go Normal file
View File

@ -0,0 +1,158 @@
package lf3
import (
"context"
"errors"
"time"
"github.com/ipfs/go-datastore"
"github.com/ipfs/go-datastore/namespace"
logging "github.com/ipfs/go-log/v2"
pubsub "github.com/libp2p/go-libp2p-pubsub"
"github.com/libp2p/go-libp2p/core/host"
"go.uber.org/fx"
"golang.org/x/xerrors"
"github.com/filecoin-project/go-f3"
"github.com/filecoin-project/go-f3/blssig"
"github.com/filecoin-project/go-f3/certs"
"github.com/filecoin-project/go-f3/gpbft"
"github.com/filecoin-project/lotus/api"
"github.com/filecoin-project/lotus/build"
"github.com/filecoin-project/lotus/chain/stmgr"
"github.com/filecoin-project/lotus/chain/store"
"github.com/filecoin-project/lotus/node/modules/dtypes"
"github.com/filecoin-project/lotus/node/modules/helpers"
)
type F3 struct {
inner *f3.F3
signer gpbft.Signer
}
type F3Params struct {
fx.In
NetworkName dtypes.NetworkName
PubSub *pubsub.PubSub
Host host.Host
ChainStore *store.ChainStore
StateManager *stmgr.StateManager
Datastore dtypes.MetadataDS
Wallet api.Wallet
}
var log = logging.Logger("f3")
func New(mctx helpers.MetricsCtx, lc fx.Lifecycle, params F3Params) (*F3, error) {
manifest := f3.LocalnetManifest()
manifest.NetworkName = gpbft.NetworkName(params.NetworkName)
manifest.ECDelay = 2 * time.Duration(build.BlockDelaySecs) * time.Second
manifest.ECPeriod = manifest.ECDelay
manifest.BootstrapEpoch = int64(build.F3BootstrapEpoch)
manifest.ECFinality = int64(build.Finality)
ds := namespace.Wrap(params.Datastore, datastore.NewKey("/f3"))
ec := &ecWrapper{
ChainStore: params.ChainStore,
StateManager: params.StateManager,
Manifest: manifest,
}
verif := blssig.VerifierWithKeyOnG1()
module, err := f3.New(mctx, manifest, ds,
params.Host, params.PubSub, verif, ec, log, nil)
if err != nil {
return nil, xerrors.Errorf("creating F3: %w", err)
}
fff := &F3{
inner: module,
signer: &signer{params.Wallet},
}
lCtx, cancel := context.WithCancel(mctx)
lc.Append(fx.StartStopHook(
func() {
go func() {
err := fff.inner.Run(lCtx)
if err != nil {
log.Errorf("running f3: %+v", err)
}
}()
}, cancel))
return fff, nil
}
// Participate runs the participation loop for givine minerID
// It is blocking
func (fff *F3) Participate(ctx context.Context, minerIDAddress uint64, errCh chan<- string) {
defer close(errCh)
for ctx.Err() == nil {
// create channel for some buffer so we don't get dropped under high load
msgCh := make(chan *gpbft.MessageBuilder, 4)
// SubscribeForMessagesToSign will close the channel if it fills up
// so using the closer is not necessary, we can just drop it on the floor
_ = fff.inner.SubscribeForMessagesToSign(msgCh)
participateOnce := func(mb *gpbft.MessageBuilder) error {
signatureBuilder, err := mb.PrepareSigningInputs(gpbft.ActorID(minerIDAddress))
if errors.Is(err, gpbft.ErrNoPower) {
// we don't have any power in F3, continue
log.Debug("no power to participate in F3: %+v", err)
return nil
}
if err != nil {
log.Errorf("preparing signing inputs: %+v", err)
return err
}
// if worker keys were stored not in the node, the signatureBuilder can be send there
// the sign can be called where the keys are stored and then
// {signatureBuilder, payloadSig, vrfSig} can be sent back to lotus for broadcast
payloadSig, vrfSig, err := signatureBuilder.Sign(fff.signer)
if err != nil {
log.Errorf("signing message: %+v", err)
return err
}
log.Infof("miner with id %d is sending message in F3", minerIDAddress)
fff.inner.Broadcast(ctx, signatureBuilder, payloadSig, vrfSig)
return nil
}
inner:
for ctx.Err() == nil {
select {
case mb, ok := <-msgCh:
if !ok {
// the broadcast bus kicked us out
log.Warnf("lost message bus subscription, retrying")
break inner
}
err := participateOnce(mb)
if err != nil {
errCh <- err.Error()
} else {
errCh <- ""
}
case <-ctx.Done():
return
}
}
}
}
func (fff *F3) GetCert(ctx context.Context, instance uint64) (*certs.FinalityCertificate, error) {
return fff.inner.GetCert(ctx, instance)
}
func (fff *F3) GetLatestCert(ctx context.Context) (*certs.FinalityCertificate, error) {
return fff.inner.GetLatestCert(ctx)
}

38
chain/lf3/signer.go Normal file
View File

@ -0,0 +1,38 @@
package lf3
import (
"context"
"golang.org/x/xerrors"
"github.com/filecoin-project/go-address"
"github.com/filecoin-project/go-f3/gpbft"
"github.com/filecoin-project/lotus/api"
)
type signer struct {
wallet api.Wallet
}
// Sign signs a message with the private key corresponding to a public key.
// The the key must be known by the wallet and be of BLS type.
func (s *signer) Sign(sender gpbft.PubKey, msg []byte) ([]byte, error) {
addr, err := address.NewBLSAddress(sender)
if err != nil {
return nil, xerrors.Errorf("converting pubkey to address: %w", err)
}
sig, err := s.wallet.WalletSign(context.TODO(), addr, msg, api.MsgMeta{Type: api.MTUnknown})
if err != nil {
return nil, xerrors.Errorf("error while signing: %w", err)
}
return sig.Data, nil
}
// MarshalPayloadForSigning marshals the given payload into the bytes that should be signed.
// This should usually call `Payload.MarshalForSigning(NetworkName)` except when testing as
// that method is slow (computes a merkle tree that's necessary for testing).
// Implementations must be safe for concurrent use.
func (s *signer) MarshalPayloadForSigning(nn gpbft.NetworkName, p *gpbft.Payload) []byte {
return p.MarshalForSigning(nn)
}

View File

@ -26,8 +26,8 @@ type ActorV5 struct {
Head cid.Cid
Nonce uint64
Balance BigInt
// Deterministic Address.
Address *address.Address
// The f4 address of the actor, if any.
DelegatedAddress *address.Address
}
type Actor = ActorV5

View File

@ -1232,8 +1232,8 @@ func (t *ActorV5) MarshalCBOR(w io.Writer) error {
return err
}
// t.Address (address.Address) (struct)
if err := t.Address.MarshalCBOR(cw); err != nil {
// t.DelegatedAddress (address.Address) (struct)
if err := t.DelegatedAddress.MarshalCBOR(cw); err != nil {
return err
}
return nil
@ -1309,7 +1309,7 @@ func (t *ActorV5) UnmarshalCBOR(r io.Reader) (err error) {
}
}
// t.Address (address.Address) (struct)
// t.DelegatedAddress (address.Address) (struct)
{
@ -1321,9 +1321,9 @@ func (t *ActorV5) UnmarshalCBOR(r io.Reader) (err error) {
if err := cr.UnreadByte(); err != nil {
return err
}
t.Address = new(address.Address)
if err := t.Address.UnmarshalCBOR(cr); err != nil {
return xerrors.Errorf("unmarshaling t.Address pointer: %w", err)
t.DelegatedAddress = new(address.Address)
if err := t.DelegatedAddress.UnmarshalCBOR(cr); err != nil {
return xerrors.Errorf("unmarshaling t.DelegatedAddress pointer: %w", err)
}
}

View File

@ -28,6 +28,12 @@ import (
var ErrInvalidAddress = errors.New("invalid Filecoin Eth address")
// Research into Filecoin chain behaviour suggests that probabilistic finality
// generally approaches the intended stability guarantee at, or near, 30 epochs.
// Although a strictly "finalized" safe recommendation remains 900 epochs.
// See https://github.com/filecoin-project/FIPs/blob/master/FRCs/frc-0089.md
const SafeEpochDelay = abi.ChainEpoch(30)
type EthUint64 uint64
func (e EthUint64) MarshalJSON() ([]byte, error) {

View File

@ -89,7 +89,7 @@ func TryCreateAccountActor(rt *Runtime, addr address.Address) (*types.Actor, add
func makeAccountActor(ver actorstypes.Version, addr address.Address) (*types.Actor, aerrors.ActorError) {
switch addr.Protocol() {
case address.BLS, address.SECP256K1:
return newAccountActor(ver, addr), nil
return newAccountActor(ver), nil
case address.ID:
return nil, aerrors.Newf(exitcode.SysErrInvalidReceiver, "no actor with given ID: %s", addr)
case address.Actor:
@ -99,7 +99,7 @@ func makeAccountActor(ver actorstypes.Version, addr address.Address) (*types.Act
}
}
func newAccountActor(ver actorstypes.Version, addr address.Address) *types.Actor {
func newAccountActor(ver actorstypes.Version) *types.Actor {
// TODO: ActorsUpgrade use a global actor registry?
var code cid.Cid
switch ver {
@ -124,7 +124,6 @@ func newAccountActor(ver actorstypes.Version, addr address.Address) *types.Actor
Code: code,
Balance: types.NewInt(0),
Head: EmptyObjectCid,
Address: &addr,
}
return nact

View File

@ -59,9 +59,9 @@ func ResolveToDeterministicAddr(state types.StateTree, cst cbor.IpldStore, addr
}
if state.Version() >= types.StateTreeVersion5 {
if act.Address != nil {
if act.DelegatedAddress != nil {
// If there _is_ an f4 address, return it as "key" address
return *act.Address, nil
return *act.DelegatedAddress, nil
}
}

View File

@ -471,8 +471,8 @@ func ethAddrFromFilecoinAddress(ctx context.Context, addr address.Address, fnapi
if err != nil {
return ethtypes.EthAddress{}, addr, err
}
if fAct.Address != nil && (*fAct.Address).Protocol() == address.Delegated {
faddr = *fAct.Address
if fAct.DelegatedAddress != nil && (*fAct.DelegatedAddress).Protocol() == address.Delegated {
faddr = *fAct.DelegatedAddress
}
case address.Delegated:
faddr = addr

View File

@ -633,8 +633,8 @@ var StateGetActorCmd = &cli.Command{
fmt.Printf("Nonce:\t\t%d\n", a.Nonce)
fmt.Printf("Code:\t\t%s (%s)\n", a.Code, strtype)
fmt.Printf("Head:\t\t%s\n", a.Head)
if a.Address != nil {
fmt.Printf("Delegated address:\t\t%s\n", a.Address)
if a.DelegatedAddress != nil {
fmt.Printf("Delegated address:\t\t%s\n", a.DelegatedAddress)
}
return nil

View File

@ -0,0 +1,89 @@
#!/usr/bin/env bash
# This is an example of how a full sector lifecycle can be benchmarked using `lotus-bench`. The
# script generates an unsealed sector, runs PC1, PC2, C1, and C2, and prints the duration of each
# step. The script also prints the proof length and total duration of the lifecycle.
#
# Change `flags` to `--non-interactive` to run NI-PoRep, and switch `sector_size` to the desired
# sector size. The script assumes that the `lotus-bench` binary is in the same directory as the
# script.
#
# Note that for larger sector sizes, /tmp may not have enough space for the full lifecycle.
set -e
set -o pipefail
tmpdir=/tmp
flags=""
# flags="--non-interactive"
sector_size=2KiB
# sector_size=8MiB
# sector_size=512MiB
# sector_size=32GiB
# sector_size=64GiB
unsealed_file=${tmpdir}/unsealed${sector_size}
sealed_file=${tmpdir}/sealed${sector_size}
cache_dir=${tmpdir}/cache${sector_size}
c1_file=${tmpdir}/c1_${sector_size}.json
proof_out=${tmpdir}/proof_${sector_size}.hex
rm -rf $unsealed_file $sealed_file $cache_dir $c1_file
echo "Generating unsealed sector ..."
read -r unsealed_cid unsealed_size <<< $(./lotus-bench simple addpiece --sector-size $sector_size /dev/zero $unsealed_file | tail -1)
if [ $? -ne 0 ]; then exit 1; fi
echo "Unsealed CID: $unsealed_cid"
echo "Unsealed Size: $unsealed_size"
start_total=$(date +%s%3N)
echo "Running PC1 ..."
echo "./lotus-bench simple precommit1 --sector-size $sector_size $flags $unsealed_file $sealed_file $cache_dir $unsealed_cid $unsealed_size"
start_pc1=$(date +%s%3N)
pc1_output=$(./lotus-bench simple precommit1 --sector-size $sector_size $flags $unsealed_file $sealed_file $cache_dir $unsealed_cid $unsealed_size | tail -1)
if [ $? -ne 0 ]; then exit 1; fi
end_pc1=$(date +%s%3N)
pc1_duration=$((end_pc1 - start_pc1))
echo "Running PC2 ..."
echo "./lotus-bench simple precommit2 --sector-size $sector_size $flags $sealed_file $cache_dir $pc1_output"
start_pc2=$(date +%s%3N)
read -r commd commr <<< $(./lotus-bench simple precommit2 --sector-size $sector_size $flags $sealed_file $cache_dir $pc1_output | tail -1 | sed -E 's/[dr]://g')
if [ $? -ne 0 ]; then exit 1; fi
end_pc2=$(date +%s%3N)
pc2_duration=$((end_pc2 - start_pc2))
echo "CommD CID: $commd"
echo "CommR CID: $commr"
echo "Running C1 ..."
echo "./lotus-bench simple commit1 --sector-size $sector_size $flags $sealed_file $cache_dir ${commd} ${commr} $c1_file"
start_c1=$(date +%s%3N)
./lotus-bench simple commit1 --sector-size $sector_size $flags $sealed_file $cache_dir ${commd} ${commr} $c1_file
end_c1=$(date +%s%3N)
c1_duration=$((end_c1 - start_c1))
echo "Running C2 ..."
echo "./lotus-bench simple commit2 $flags $c1_file"
start_c2=$(date +%s%3N)
proof=$(./lotus-bench simple commit2 $flags $c1_file | tail -1 | sed 's/^proof: //')
if [ $? -ne 0 ]; then exit 1; fi
end_c2=$(date +%s%3N)
c2_duration=$((end_c2 - start_c2))
echo $proof > $proof_out
echo "Wrote proof to $proof_out"
# $proof is hex, calculate the length of it in bytes
proof_len=$(echo "scale=0; ${#proof}/2" | bc)
echo "Proof length: $proof_len"
end_total=$(date +%s%3N)
total_duration=$((end_total - start_total))
echo "PC1 duration: $((pc1_duration / 1000)).$((pc1_duration % 1000)) seconds"
echo "PC2 duration: $((pc2_duration / 1000)).$((pc2_duration % 1000)) seconds"
echo "C1 duration: $((c1_duration / 1000)).$((c1_duration % 1000)) seconds"
echo "C2 duration: $((c2_duration / 1000)).$((c2_duration % 1000)) seconds"
echo "Total duration: $((total_duration / 1000)).$((total_duration % 1000)) seconds"

View File

@ -338,7 +338,7 @@ var sealBenchCmd = &cli.Command{
if !skipc2 {
log.Info("generating winning post candidates")
wipt, err := spt(sectorSize, false).RegisteredWinningPoStProof()
wipt, err := spt(sectorSize, miner.SealProofVariant_Standard).RegisteredWinningPoStProof()
if err != nil {
return err
}
@ -556,7 +556,7 @@ func runSeals(sb *ffiwrapper.Sealer, sbfs *basicfs.Provider, numSectors int, par
Miner: mid,
Number: i,
},
ProofType: spt(sectorSize, false),
ProofType: spt(sectorSize, miner.SealProofVariant_Standard),
}
start := time.Now()
@ -586,7 +586,7 @@ func runSeals(sb *ffiwrapper.Sealer, sbfs *basicfs.Provider, numSectors int, par
Miner: mid,
Number: i,
},
ProofType: spt(sectorSize, false),
ProofType: spt(sectorSize, miner.SealProofVariant_Standard),
}
start := time.Now()
@ -797,7 +797,7 @@ var proveCmd = &cli.Command{
Miner: abi.ActorID(mid),
Number: abi.SectorNumber(c2in.SectorNum),
},
ProofType: spt(abi.SectorSize(c2in.SectorSize), false),
ProofType: spt(abi.SectorSize(c2in.SectorSize), miner.SealProofVariant_Standard),
}
fmt.Printf("----\nstart proof computation\n")
@ -828,8 +828,8 @@ func bps(sectorSize abi.SectorSize, sectorNum int, d time.Duration) string {
return types.SizeStr(types.BigInt{Int: bps}) + "/s"
}
func spt(ssize abi.SectorSize, synth bool) abi.RegisteredSealProof {
spt, err := miner.SealProofTypeFromSectorSize(ssize, build.TestNetworkVersion, synth)
func spt(ssize abi.SectorSize, variant miner.SealProofVariant) abi.RegisteredSealProof {
spt, err := miner.SealProofTypeFromSectorSize(ssize, build.TestNetworkVersion, variant)
if err != nil {
panic(err)
}

View File

@ -21,6 +21,7 @@ import (
prf "github.com/filecoin-project/specs-actors/actors/runtime/proof"
"github.com/filecoin-project/lotus/build"
"github.com/filecoin-project/lotus/chain/actors/builtin/miner"
lcli "github.com/filecoin-project/lotus/cli"
"github.com/filecoin-project/lotus/storage/sealer/ffiwrapper"
"github.com/filecoin-project/lotus/storage/sealer/storiface"
@ -186,7 +187,7 @@ var simpleAddPiece = &cli.Command{
Miner: mid,
Number: 1,
},
ProofType: spt(sectorSize, false),
ProofType: spt(sectorSize, miner.SealProofVariant_Standard),
}
data, err := os.Open(cctx.Args().First())
@ -201,7 +202,7 @@ var simpleAddPiece = &cli.Command{
return xerrors.Errorf("add piece: %w", err)
}
took := time.Now().Sub(start)
took := time.Since(start)
fmt.Printf("AddPiece %s (%s)\n", took, bps(abi.SectorSize(pi.Size), 1, took))
fmt.Printf("%s %d\n", pi.PieceCID, pi.Size)
@ -227,6 +228,10 @@ var simplePreCommit1 = &cli.Command{
Name: "synthetic",
Usage: "generate synthetic PoRep proofs",
},
&cli.BoolFlag{
Name: "non-interactive",
Usage: "generate NI-PoRep proofs",
},
},
ArgsUsage: "[unsealed] [sealed] [cache] [[piece cid] [piece size]]...",
Action: func(cctx *cli.Context) error {
@ -258,12 +263,17 @@ var simplePreCommit1 = &cli.Command{
return err
}
variant, err := variantFromArgs(cctx)
if err != nil {
return err
}
sr := storiface.SectorRef{
ID: abi.SectorID{
Miner: mid,
Number: 1,
},
ProofType: spt(sectorSize, cctx.Bool("synthetic")),
ProofType: spt(sectorSize, variant),
}
ticket := [32]byte{}
@ -283,7 +293,7 @@ var simplePreCommit1 = &cli.Command{
return xerrors.Errorf("precommit1: %w", err)
}
took := time.Now().Sub(start)
took := time.Since(start)
fmt.Printf("PreCommit1 %s (%s)\n", took, bps(sectorSize, 1, took))
fmt.Println(base64.StdEncoding.EncodeToString(p1o))
@ -308,6 +318,10 @@ var simplePreCommit2 = &cli.Command{
Name: "synthetic",
Usage: "generate synthetic PoRep proofs",
},
&cli.BoolFlag{
Name: "non-interactive",
Usage: "generate NI-PoRep proofs",
},
&cli.StringFlag{
Name: "external-pc2",
Usage: "command for computing PC2 externally",
@ -383,12 +397,17 @@ Example invocation of lotus-bench as external executor:
return err
}
variant, err := variantFromArgs(cctx)
if err != nil {
return err
}
sr := storiface.SectorRef{
ID: abi.SectorID{
Miner: mid,
Number: 1,
},
ProofType: spt(sectorSize, cctx.Bool("synthetic")),
ProofType: spt(sectorSize, variant),
}
start := time.Now()
@ -398,7 +417,7 @@ Example invocation of lotus-bench as external executor:
return xerrors.Errorf("precommit2: %w", err)
}
took := time.Now().Sub(start)
took := time.Since(start)
fmt.Printf("PreCommit2 %s (%s)\n", took, bps(sectorSize, 1, took))
fmt.Printf("d:%s r:%s\n", p2o.Unsealed, p2o.Sealed)
@ -423,6 +442,10 @@ var simpleCommit1 = &cli.Command{
Name: "synthetic",
Usage: "generate synthetic PoRep proofs",
},
&cli.BoolFlag{
Name: "non-interactive",
Usage: "generate NI-PoRep proofs",
},
},
ArgsUsage: "[sealed] [cache] [comm D] [comm R] [c1out.json]",
Action: func(cctx *cli.Context) error {
@ -453,12 +476,17 @@ var simpleCommit1 = &cli.Command{
return err
}
variant, err := variantFromArgs(cctx)
if err != nil {
return err
}
sr := storiface.SectorRef{
ID: abi.SectorID{
Miner: mid,
Number: 1,
},
ProofType: spt(sectorSize, cctx.Bool("synthetic")),
ProofType: spt(sectorSize, variant),
}
start := time.Now()
@ -493,7 +521,7 @@ var simpleCommit1 = &cli.Command{
return xerrors.Errorf("commit1: %w", err)
}
took := time.Now().Sub(start)
took := time.Since(start)
fmt.Printf("Commit1 %s (%s)\n", took, bps(sectorSize, 1, took))
@ -533,6 +561,10 @@ var simpleCommit2 = &cli.Command{
Name: "synthetic",
Usage: "generate synthetic PoRep proofs",
},
&cli.BoolFlag{
Name: "non-interactive",
Usage: "generate NI-PoRep proofs",
},
},
Action: func(c *cli.Context) error {
if c.Bool("no-gpu") {
@ -574,12 +606,17 @@ var simpleCommit2 = &cli.Command{
return err
}
variant, err := variantFromArgs(c)
if err != nil {
return err
}
ref := storiface.SectorRef{
ID: abi.SectorID{
Miner: abi.ActorID(mid),
Number: abi.SectorNumber(c2in.SectorNum),
},
ProofType: spt(abi.SectorSize(c2in.SectorSize), c.Bool("synthetic")),
ProofType: spt(abi.SectorSize(c2in.SectorSize), variant),
}
start := time.Now()
@ -637,7 +674,7 @@ var simpleWindowPost = &cli.Command{
return xerrors.Errorf("parse commr: %w", err)
}
wpt, err := spt(sectorSize, false).RegisteredWindowPoStProof()
wpt, err := spt(sectorSize, miner.SealProofVariant_Standard).RegisteredWindowPoStProof()
if err != nil {
return err
}
@ -657,7 +694,7 @@ var simpleWindowPost = &cli.Command{
vp, err := ffi.GenerateSingleVanillaProof(ffi.PrivateSectorInfo{
SectorInfo: prf.SectorInfo{
SealProof: spt(sectorSize, false),
SealProof: spt(sectorSize, miner.SealProofVariant_Standard),
SectorNumber: sn,
SealedCID: commr,
},
@ -728,7 +765,7 @@ var simpleWinningPost = &cli.Command{
return xerrors.Errorf("parse commr: %w", err)
}
wpt, err := spt(sectorSize, false).RegisteredWinningPoStProof()
wpt, err := spt(sectorSize, miner.SealProofVariant_Standard).RegisteredWinningPoStProof()
if err != nil {
return err
}
@ -748,7 +785,7 @@ var simpleWinningPost = &cli.Command{
vp, err := ffi.GenerateSingleVanillaProof(ffi.PrivateSectorInfo{
SectorInfo: prf.SectorInfo{
SealProof: spt(sectorSize, false),
SealProof: spt(sectorSize, miner.SealProofVariant_Standard),
SectorNumber: sn,
SealedCID: commr,
},
@ -842,7 +879,7 @@ var simpleReplicaUpdate = &cli.Command{
Miner: mid,
Number: 1,
},
ProofType: spt(sectorSize, false),
ProofType: spt(sectorSize, miner.SealProofVariant_Standard),
}
start := time.Now()
@ -852,7 +889,7 @@ var simpleReplicaUpdate = &cli.Command{
return xerrors.Errorf("replica update: %w", err)
}
took := time.Now().Sub(start)
took := time.Since(start)
fmt.Printf("ReplicaUpdate %s (%s)\n", took, bps(sectorSize, 1, took))
fmt.Printf("d:%s r:%s\n", ruo.NewUnsealed, ruo.NewSealed)
@ -910,7 +947,7 @@ var simpleProveReplicaUpdate1 = &cli.Command{
Miner: mid,
Number: 1,
},
ProofType: spt(sectorSize, false),
ProofType: spt(sectorSize, miner.SealProofVariant_Standard),
}
start := time.Now()
@ -935,7 +972,7 @@ var simpleProveReplicaUpdate1 = &cli.Command{
return xerrors.Errorf("replica update: %w", err)
}
took := time.Now().Sub(start)
took := time.Since(start)
fmt.Printf("ProveReplicaUpdate1 %s (%s)\n", took, bps(sectorSize, 1, took))
@ -997,7 +1034,7 @@ var simpleProveReplicaUpdate2 = &cli.Command{
Miner: mid,
Number: 1,
},
ProofType: spt(sectorSize, false),
ProofType: spt(sectorSize, miner.SealProofVariant_Standard),
}
start := time.Now()
@ -1032,7 +1069,7 @@ var simpleProveReplicaUpdate2 = &cli.Command{
return xerrors.Errorf("prove replica update2: %w", err)
}
took := time.Now().Sub(start)
took := time.Since(start)
fmt.Printf("ProveReplicaUpdate2 %s (%s)\n", took, bps(sectorSize, 1, took))
fmt.Println("p:", base64.StdEncoding.EncodeToString(p))
@ -1071,3 +1108,16 @@ func ParsePieceInfos(cctx *cli.Context, firstArg int) ([]abi.PieceInfo, error) {
return out, nil
}
func variantFromArgs(cctx *cli.Context) (miner.SealProofVariant, error) {
variant := miner.SealProofVariant_Standard
if cctx.Bool("synthetic") {
if cctx.Bool("non-interactive") {
return variant, xerrors.Errorf("can't use both synthetic and non-interactive")
}
variant = miner.SealProofVariant_Synthetic
} else if cctx.Bool("non-interactive") {
variant = miner.SealProofVariant_NonInteractive
}
return variant, nil
}

View File

@ -137,9 +137,8 @@ var preSealCmd = &cli.Command{
nv = network.Version(c.Uint64("network-version"))
}
var synthetic = false // there's little reason to have this for a seed.
spt, err := miner.SealProofTypeFromSectorSize(sectorSize, nv, synthetic)
var variant = miner.SealProofVariant_Standard // there's little reason to have this for a seed.
spt, err := miner.SealProofTypeFromSectorSize(sectorSize, nv, variant)
if err != nil {
return err
}

View File

@ -146,11 +146,11 @@ var backfillEventsCmd = &cli.Command{
}
actor, err := api.StateGetActor(ctx, idAddr, ts.Key())
if err != nil || actor.Address == nil {
if err != nil || actor.DelegatedAddress == nil {
return idAddr, true
}
return *actor.Address, true
return *actor.DelegatedAddress, true
}
isIndexedValue := func(b uint8) bool {

View File

@ -3819,7 +3819,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -3859,7 +3859,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -3911,7 +3911,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
}
```
@ -4081,7 +4081,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -4121,7 +4121,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -4232,7 +4232,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
```
@ -4483,7 +4483,7 @@ Response:
"UpgradeWatermelonHeight": 10101,
"UpgradeDragonHeight": 10101,
"UpgradePhoenixHeight": 10101,
"UpgradeAussieHeight": 10101
"UpgradeWaffleHeight": 10101
},
"Eip155ChainID": 123
}
@ -5550,7 +5550,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -5590,7 +5590,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [

View File

@ -80,6 +80,10 @@
* [EthTraceTransaction](#EthTraceTransaction)
* [EthUninstallFilter](#EthUninstallFilter)
* [EthUnsubscribe](#EthUnsubscribe)
* [F3](#F3)
* [F3GetCertificate](#F3GetCertificate)
* [F3GetLatestCertificate](#F3GetLatestCertificate)
* [F3Participate](#F3Participate)
* [Filecoin](#Filecoin)
* [FilecoinAddressToEthAddress](#FilecoinAddressToEthAddress)
* [Gas](#Gas)
@ -2162,6 +2166,150 @@ Inputs:
Response: `true`
## F3
### F3GetCertificate
F3GetCertificate returns a finality certificate at given instance number
Perms: read
Inputs:
```json
[
42
]
```
Response:
```json
{
"GPBFTInstance": 0,
"ECChain": null,
"SupplementalData": {
"Commitments": [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
],
"PowerTable": null
},
"Signers": [
0
],
"Signature": null,
"PowerTableDelta": null
}
```
### F3GetLatestCertificate
F3GetLatestCertificate returns the latest finality certificate
Perms: read
Inputs: `null`
Response:
```json
{
"GPBFTInstance": 0,
"ECChain": null,
"SupplementalData": {
"Commitments": [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
],
"PowerTable": null
},
"Signers": [
0
],
"Signature": null,
"PowerTableDelta": null
}
```
### F3Participate
F3Participate should be called by a miner node to participate in signing F3 consensus.
The address should be of type ID
The returned channel will never be closed by the F3
If it is closed without the context being cancelled, the caller should retry.
The values returned on the channel will inform the caller about participation
Empty strings will be sent if participation succeeded, non-empty strings explain possible errors.
Perms: admin
Inputs:
```json
[
"f01234"
]
```
Response: `"string value"`
## Filecoin
@ -5423,7 +5571,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -5463,7 +5611,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -5515,7 +5663,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
}
```
@ -5685,7 +5833,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -5725,7 +5873,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -5887,7 +6035,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
```
@ -6185,7 +6333,7 @@ Response:
"UpgradeWatermelonHeight": 10101,
"UpgradeDragonHeight": 10101,
"UpgradePhoenixHeight": 10101,
"UpgradeAussieHeight": 10101
"UpgradeWaffleHeight": 10101
},
"Eip155ChainID": 123
}
@ -7306,7 +7454,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [
@ -7346,7 +7494,7 @@ Response:
},
"Nonce": 42,
"Balance": "0",
"Address": "f01234"
"DelegatedAddress": "f01234"
}
},
"GasCharges": [

View File

@ -7,7 +7,7 @@ USAGE:
lotus-miner [global options] command [command options] [arguments...]
VERSION:
1.27.1
1.28.0-rc1
COMMANDS:
init Initialize a lotus miner repo

View File

@ -7,7 +7,7 @@ USAGE:
lotus-worker [global options] command [command options] [arguments...]
VERSION:
1.27.1
1.28.0-rc1
COMMANDS:
run Start lotus worker

View File

@ -7,7 +7,7 @@ USAGE:
lotus [global options] command [command options] [arguments...]
VERSION:
1.27.1
1.28.0-rc1
COMMANDS:
daemon Start a lotus daemon process

View File

@ -2,10 +2,11 @@
This guide will walk you through the process of creating a skeleton for a network upgrade in Lotus. The process involves making changes in multiple repositories in the following order:
1. [`ref-fvm`](#ref-fvm-checklist)
2. [`filecoin-ffi`](#filecoin-ffi-checklist)
3. [`go-state-types`](#go-state-types-checklist)
4. [`lotus`](#lotus-checklist)
- [Setup](#setup)
- [Ref-FVM Checklist](#ref-fvm-checklist)
- [Filecoin-FFI Checklist](#filecoin-ffi-checklist)
- [Go-State-Types Checklist](#go-state-types-checklist)
- [Lotus Checklist](#lotus-checklist)
Each repository has its own set of steps that need to be followed. This guide will provide detailed instructions for each repository.
@ -60,8 +61,24 @@ You can take a look at this [Filecoin-FFI PR as a reference](https://github.com/
1. Follow the [go-state-types actor version checklist](https://github.com/filecoin-project/go-state-types/blob/master/actors_version_checklist.md):
- Copy `go-state-types/builtin/vX` to `go-state-types/builtin/v(X+1)`.
- Change all references from vX to v(X+1) in the new files.
- Setup
```bash
# export these environment variables so they can read in the commands below
export CURRENT_VERSION=vXX # e.g., v14
export NEW_VERSION=vXX+1 # e.g., v15
```
- Copy `go-state-types/builtin/vXX` to `go-state-types/builtin/v(XX+1)`.
```bash
cp -r builtin/$CURRENT_VERSION builtin/$NEW_VERSION
```
- Make a commit with this change. That way the followup commit(s) will be separated out from the copy/paste change for easier reviewing.
- Change all references from vXX to v(XX+1) in the new files.
```bash
# Find all the files that have a reference to vXX
# Update them to vXX+1
# "sed -i=''" is done for macOS compatibility per https://stackoverflow.com/questions/12272065/sed-undefined-label-on-macos
find builtin/$NEW_VERSION -type f -exec sh -c 'grep -q "builtin/$CURRENT_VERSION" "$1" && sed -i='' "s/builtin\/$CURRENT_VERSION/builtin\/$NEW_VERSION/g" "$1" && echo "$1"' _ {} \;
```
- Add new network version to `network/version.go`.
- Add new actors version to `actors/version.go`.
- Add `Version(XX+1) Version = XX+1` as a constant.
@ -73,14 +90,14 @@ You can take a look at this [Filecoin-FFI PR as a reference](https://github.com/
- Commit the above changes with a `Delete migration specific for nvXX` message so its easier to review.
- Check your `/builtin/vXX+1/check.go` file, and see if there is any Invariant TODOs that stems from the previous migration that needs to be cleaned up.
You can take a look at this [Go-State-Types PR as a reference](https://github.com/filecoin-project/go-state-types/pull/257), which added the skeleton for network version 23.
👉 You can take a look at this [Go-State-Types PR as a reference](https://github.com/filecoin-project/go-state-types/pull/257), which added the skeleton for network version 23.
2. In a second PR based off your first PR, add a simple migration for the network upgrade:
1. In a second PR based off your first PR, add a simple migration for the network upgrade:
- Copy the system.go template [^1], and add it to your `/builtin/vXX+1/migration` folder.
- Copy the top.go template [^2], and add it to your `/builtin/vXX+1/migration` folder.
You can take a look at this [Go-State-Types PR as a reference](https://github.com/filecoin-project/go-state-types/pull/258), which added added a simple migration for network version 23.
👉 You can take a look at this [Go-State-Types PR as a reference](https://github.com/filecoin-project/go-state-types/pull/258), which added added a simple migration for network version 23.
## Lotus Checklist
@ -96,27 +113,27 @@ You can take a look at this [Go-State-Types PR as a reference](https://github.co
- Update the following files:
- `params_2k.go`
- Set previous `UpgradeXxxxxHeight = abi.ChainEpoch(-xx-1)`
- Add `var UpgradeXxxxxHeight = abi.ChainEpoch(200)`
- Add `UpgradeXxxxxHeight = getUpgradeHeight("LOTUS_XXXXX_HEIGHT", UpgradeXXXXHeight)`
- Set previous `UpgradeXxHeight = abi.ChainEpoch(-xx-1)`
- Add `var UpgradeXxHeight = abi.ChainEpoch(200)`
- Add `UpgradeXxHeight = getUpgradeHeight("LOTUS_XX_HEIGHT", UpgradeXXHeight)`
- Set `const GenesisNetworkVersion = network.VersionXX` where XX is the network version you are upgrading from.
- `params_butterfly.go`
- set previous upgrade to `var UpgradeXxxxxHeigh = abi.ChainEpoch(-xx-1)`
- set previous upgrade to `var UpgradeXxHeigh = abi.ChainEpoch(-xx-1)`
- Add comment with ?????? signaling that the new upgrade date is unkown
- Add `const UpgradeXxxxxHeight = 999999999999999`
- Add `const UpgradeXxHeight = 999999999999999`
- `params_calibnet.go`
- Add comment with `??????` signaling that the new upgrade date is unkown
- Add `const UpgradeXxxxxHeight = 999999999999999`
- Add `const UpgradeXxHeight = 999999999999999`
- `params_interop.go`
- set previous upgrade to `var UpgradeXxxxxHeigh = abi.ChainEpoch(-xx-1)`
- Add `const UpgradeXxxxxHeight = 50`
- set previous upgrade to `var UpgradeXxHeigh = abi.ChainEpoch(-xx-1)`
- Add `const UpgradeXxHeight = 50`
- `params_mainnet.go`
- Set previous upgrade to `const UpgradeXxxxxHeight = XX`
- Set previous upgrade to `const UpgradeXxHeight = XX`
- Add comment with ???? signaling that the new upgrade date is unkown
- Add `var UpgradeXxxxxxHeight = abi.ChainEpoch(9999999999)`
- Change the `LOTUS_DISABLE_XXXX` env variable to the new network name
- Add `var UpgradeXxHeight = abi.ChainEpoch(9999999999)`
- Change the `LOTUS_DISABLE_XX` env variable to the new network name
- `params_testground.go`
- Add `UpgradeXxxxxHeight abi.ChainEpoch = (-xx-1)`
- Add `UpgradeXxHeight abi.ChainEpoch = (-xx-1)`
3. Generate adapters:
@ -135,10 +152,10 @@ You can take a look at this [Go-State-Types PR as a reference](https://github.co
- Add `inv.Register(actorstypes.Version(XX+1), vm.ActorsVersionPredicate(actorstypes.Version(XX+1)), builtin.MakeRegistry(actorstypes.Version(XX+1))`.
6. Add upgrade field to `api/types.go/ForkUpgradeParams`.
- Add `UpgradeXxxxxHeight abi.ChainEpoch` to `ForkUpgradeParams` struct.
- Add `UpgradeXxHeight abi.ChainEpoch` to `ForkUpgradeParams` struct.
7. Add upgrade to `node/impl/full/state.go`.
- Add `UpgradeXxxxxHeight: build.UpgradeXxxxxHeight,`.
- Add `UpgradeXxHeight: build.UpgradeXxHeight,`.
8. Add network version to `chain/state/statetree.go`.
- Add `network.VersionXX+1` to `VersionForNetwork` function.
@ -155,7 +172,7 @@ And you're done! These are all the steps necessary to create a network upgrade s
- Complete the migration at upgrade epoch, with a succesful upgrade.
- Sync the new network version with the mock actor bundle, and be able to see that you are on a new network version with `lotus state network-version`
You can take a look at this [Lotus PR as a reference](https://github.com/filecoin-project/lotus/pull/11897), which added the skeleton for network version 23.
You can take a look at this [Lotus PR as a reference](https://github.com/filecoin-project/lotus/pull/11964), which added the skeleton for network version 23.
[^1]: Here is system.go template for a simple migration:
@ -315,7 +332,7 @@ You can take a look at this [Lotus PR as a reference](https://github.com/filecoi
```go
{
Height: build.UpgradeXxxxHeight,
Height: build.UpgradeXxHeight,
Network: network.Version(XX+1),
Migration: UpgradeActorsV(XX+1),
PreMigrations: []stmgr.PreMigration{{

2
extern/filecoin-ffi vendored

@ -1 +1 @@
Subproject commit 081367cae7cdfe87d8b7240a9c3767ce86a40b05
Subproject commit e467d2992e3f9bd09beb71ecf84323b45d2a3511

View File

@ -17,6 +17,7 @@ import (
"github.com/filecoin-project/go-state-types/big"
"github.com/filecoin-project/lotus/api"
"github.com/filecoin-project/lotus/build"
"github.com/filecoin-project/lotus/chain/events/filter"
"github.com/filecoin-project/lotus/chain/types"
"github.com/filecoin-project/lotus/chain/types/ethtypes"
@ -142,6 +143,10 @@ func (gw *Node) checkBlkParam(ctx context.Context, blkParam string, lookback eth
break
}
num = ethtypes.EthUint64(head.Height()) - lookback
case "safe":
num = ethtypes.EthUint64(head.Height()) - lookback - ethtypes.EthUint64(ethtypes.SafeEpochDelay)
case "finalized":
num = ethtypes.EthUint64(head.Height()) - lookback - ethtypes.EthUint64(build.Finality)
default:
if err := num.UnmarshalJSON([]byte(`"` + blkParam + `"`)); err != nil {
return fmt.Errorf("cannot parse block number: %v", err)

View File

@ -18,7 +18,7 @@ import (
"github.com/ipfs/go-cid"
)
var EmbeddedBuiltinActorsMetadata []*BuiltinActorsMetadata = []*BuiltinActorsMetadata{
var EmbeddedBuiltinActorsMetadata = []*BuiltinActorsMetadata{
{{- range . }} {
Network: {{printf "%q" .Network}},
Version: {{.Version}},

29
go.mod
View File

@ -6,9 +6,13 @@ retract v1.14.0 // Accidentally force-pushed tag, use v1.14.1+ instead.
retract v1.20.2 // Wrongfully cherry picked PR, use v1.20.2+ instead.
replace github.com/filecoin-project/test-vectors => ./extern/test-vectors // provided via a git submodule
replace github.com/filecoin-project/filecoin-ffi => ./extern/filecoin-ffi // provided via a git submodule
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/DataDog/zstd v1.4.5
github.com/GeertJohan/go.rice v1.0.3
github.com/Gurpartap/async v0.0.0-20180927173644-4f7f499dd9ee
@ -22,14 +26,14 @@ require (
github.com/dgraph-io/badger/v2 v2.2007.4
github.com/docker/go-units v0.5.0
github.com/drand/drand v1.5.11
github.com/drand/kyber v1.3.0
github.com/drand/kyber v1.3.1
github.com/dustin/go-humanize v1.0.1
github.com/elastic/go-elasticsearch/v7 v7.14.0
github.com/elastic/go-sysinfo v1.7.0
github.com/elastic/gosigar v0.14.2
github.com/etclabscore/go-openrpc-reflect v0.0.36
github.com/fatih/color v1.15.0
github.com/filecoin-project/filecoin-ffi v0.30.4-0.20220519234331-bfd1f5f9fe38
github.com/filecoin-project/filecoin-ffi v1.28.0-rc2
github.com/filecoin-project/go-address v1.1.0
github.com/filecoin-project/go-amt-ipld/v4 v4.3.0
github.com/filecoin-project/go-bitfield v0.2.4
@ -37,12 +41,13 @@ require (
github.com/filecoin-project/go-commp-utils v0.1.3
github.com/filecoin-project/go-commp-utils/nonffi v0.0.0-20220905160352-62059082a837
github.com/filecoin-project/go-crypto v0.0.1
github.com/filecoin-project/go-f3 v0.0.2
github.com/filecoin-project/go-fil-commcid v0.1.0
github.com/filecoin-project/go-hamt-ipld/v3 v3.1.0
github.com/filecoin-project/go-jsonrpc v0.3.2
github.com/filecoin-project/go-padreader v0.0.1
github.com/filecoin-project/go-paramfetch v0.0.4
github.com/filecoin-project/go-state-types v0.14.0-dev
github.com/filecoin-project/go-state-types v0.14.0-rc5
github.com/filecoin-project/go-statemachine v1.0.3
github.com/filecoin-project/go-statestore v0.2.0
github.com/filecoin-project/go-storedcounter v0.1.0
@ -94,11 +99,12 @@ require (
github.com/ipld/go-ipld-prime v0.21.0
github.com/ipni/go-libipni v0.0.8
github.com/jackc/pgerrcode v0.0.0-20240316143900-6e2875d9b438
github.com/jpillora/backoff v1.0.0
github.com/kelseyhightower/envconfig v1.4.0
github.com/klauspost/compress v1.17.8
github.com/koalacxr/quantile v0.0.1
github.com/libp2p/go-buffer-pool v0.1.0
github.com/libp2p/go-libp2p v0.34.1
github.com/libp2p/go-libp2p v0.35.0
github.com/libp2p/go-libp2p-kad-dht v0.25.2
github.com/libp2p/go-libp2p-pubsub v0.11.0
github.com/libp2p/go-libp2p-record v0.2.0
@ -159,6 +165,7 @@ require (
require (
github.com/GeertJohan/go.incremental v1.0.0 // indirect
github.com/Jorropo/jsync v1.0.1 // indirect
github.com/Kubuxu/go-broadcast v0.0.0-20240621161059-1a8c90734cd6 // indirect
github.com/PuerkitoBio/purell v1.1.1 // indirect
github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 // indirect
github.com/StackExchange/wmi v1.2.1 // indirect
@ -170,7 +177,7 @@ require (
github.com/cespare/xxhash v1.1.0 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/cilium/ebpf v0.9.1 // 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
@ -307,7 +314,7 @@ require (
github.com/wk8/go-ordered-map/v2 v2.1.8 // indirect
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f // indirect
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect
github.com/xrash/smetrics v0.0.0-20240312152122-5f08fbb34913 // indirect
github.com/zondax/hid v0.9.2 // indirect
github.com/zondax/ledger-go v0.14.3 // indirect
go.opentelemetry.io/otel/metric v1.26.0 // indirect
@ -328,11 +335,3 @@ require (
howett.net/plist v0.0.0-20181124034731-591f970eefbb // indirect
lukechampine.com/blake3 v1.3.0 // indirect
)
// https://github.com/magik6k/reflink/commit/cff5a40f3eeca17f44fc95a57ff3878e5ac761dc
// https://github.com/KarpelesLab/reflink/pull/2
replace github.com/KarpelesLab/reflink => github.com/magik6k/reflink v1.0.2-patch1
replace github.com/filecoin-project/filecoin-ffi => ./extern/filecoin-ffi
replace github.com/filecoin-project/test-vectors => ./extern/test-vectors

31
go.sum
View File

@ -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=
@ -171,8 +173,8 @@ github.com/corpix/uarand v0.1.1/go.mod h1:SFKZvkcRoLqVRFZ4u25xPmp6m9ktANfbpXZ7SJ
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=
@ -212,8 +214,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=
@ -268,6 +270,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.2 h1:bzw/GndxntJnUYA+WCaXwHE2qwGRwrFVo9umz3unTUs=
github.com/filecoin-project/go-f3 v0.0.2/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=
@ -291,9 +295,9 @@ 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-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-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=
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=
@ -749,6 +753,7 @@ github.com/jonboulle/clockwork v0.4.0 h1:p4Cf1aMWXnXAUh8lVfewRBx1zaTSYKrKMF2g3ST
github.com/jonboulle/clockwork v0.4.0/go.mod h1:xgRqUGwRcjKCO1vbZUEtSLrqKoPSsUpK7fnezOII0kc=
github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY=
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=
@ -820,8 +825,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=
@ -1347,8 +1352,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=

View File

@ -124,3 +124,39 @@ func TestNetVersion(t *testing.T) {
require.NoError(t, err)
require.Equal(t, strconv.Itoa(build.Eip155ChainId), version)
}
func TestEthBlockNumberAliases(t *testing.T) {
blockTime := 2 * time.Millisecond
kit.QuietMiningLogs()
client, _, ens := kit.EnsembleMinimal(t, kit.MockProofs(), kit.ThroughRPC())
ens.InterconnectAll().BeginMining(blockTime)
ens.Start()
build.Clock.Sleep(time.Second)
ctx, cancel := context.WithTimeout(context.Background(), time.Minute)
defer cancel()
head := client.WaitTillChain(ctx, kit.HeightAtLeast(build.Finality+100))
// latest should be head-1 (parents)
latestEthBlk, err := client.EVM().EthGetBlockByNumber(ctx, "latest", true)
require.NoError(t, err)
diff := int64(latestEthBlk.Number) - int64(head.Height()-1)
require.GreaterOrEqual(t, diff, int64(0))
require.LessOrEqual(t, diff, int64(2))
// safe should be latest-30
safeEthBlk, err := client.EVM().EthGetBlockByNumber(ctx, "safe", true)
require.NoError(t, err)
diff = int64(latestEthBlk.Number-30) - int64(safeEthBlk.Number)
require.GreaterOrEqual(t, diff, int64(0))
require.LessOrEqual(t, diff, int64(2))
// finalized should be Finality blocks behind latest
finalityEthBlk, err := client.EVM().EthGetBlockByNumber(ctx, "finalized", true)
require.NoError(t, err)
diff = int64(latestEthBlk.Number) - int64(build.Finality) - int64(finalityEthBlk.Number)
require.GreaterOrEqual(t, diff, int64(0))
require.LessOrEqual(t, diff, int64(2))
}

View File

@ -1154,8 +1154,8 @@ func getEthAddress(ctx context.Context, t *testing.T, client *kit.TestFullNode,
actor, err := client.StateGetActor(ctx, addr, head.Key())
require.NoError(t, err)
require.NotNil(t, actor.Address)
ethContractAddr, err := ethtypes.EthAddressFromFilecoinAddress(*actor.Address)
require.NotNil(t, actor.DelegatedAddress)
ethContractAddr, err := ethtypes.EthAddressFromFilecoinAddress(*actor.DelegatedAddress)
require.NoError(t, err)
return ethContractAddr
}

View File

@ -51,50 +51,13 @@ func decodeOutputToUint64(output []byte) (uint64, error) {
err := binary.Read(buf, binary.BigEndian, &result)
return result, err
}
func buildInputFromuint64(number uint64) []byte {
func buildInputFromUint64(number uint64) []byte {
// Convert the number to a binary uint64 array
binaryNumber := make([]byte, 8)
binary.BigEndian.PutUint64(binaryNumber, number)
return inputDataFromArray(binaryNumber)
}
// recursive delegate calls that fail due to gas limits are currently getting to 229 iterations
// before running out of gas
func recursiveDelegatecallFail(ctx context.Context, t *testing.T, client *kit.TestFullNode, filename string, count uint64) {
expectedIterationsBeforeFailing := int(220)
fromAddr, idAddr := client.EVM().DeployContractFromFilename(ctx, filename)
t.Log("recursion count - ", count)
inputData := buildInputFromuint64(count)
_, _, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "recursiveCall(uint256)", inputData)
require.NoError(t, err)
result, _, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "totalCalls()", []byte{})
require.NoError(t, err)
resultUint, err := decodeOutputToUint64(result)
require.NoError(t, err)
require.NotEqual(t, int(resultUint), int(count))
require.Equal(t, expectedIterationsBeforeFailing, int(resultUint))
}
func recursiveDelegatecallSuccess(ctx context.Context, t *testing.T, client *kit.TestFullNode, filename string, count uint64) {
t.Log("Count - ", count)
fromAddr, idAddr := client.EVM().DeployContractFromFilename(ctx, filename)
inputData := buildInputFromuint64(count)
_, _, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "recursiveCall(uint256)", inputData)
require.NoError(t, err)
result, _, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "totalCalls()", []byte{})
require.NoError(t, err)
resultUint, err := decodeOutputToUint64(result)
require.NoError(t, err)
require.Equal(t, int(count), int(resultUint))
}
// TestFEVMRecursive does a basic fevm contract installation and invocation
func TestFEVMRecursive(t *testing.T) {
callCounts := []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 100, 230, 330}
@ -107,7 +70,7 @@ func TestFEVMRecursive(t *testing.T) {
for _, callCount := range callCounts {
callCount := callCount // linter unhappy unless callCount is local to loop
t.Run(fmt.Sprintf("TestFEVMRecursive%d", callCount), func(t *testing.T) {
_, _, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "recursiveCall(uint256)", buildInputFromuint64(callCount))
_, _, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "recursiveCall(uint256)", buildInputFromUint64(callCount))
require.NoError(t, err)
})
}
@ -125,7 +88,7 @@ func TestFEVMRecursiveFail(t *testing.T) {
for _, failCallCount := range failCallCounts {
failCallCount := failCallCount // linter unhappy unless callCount is local to loop
t.Run(fmt.Sprintf("TestFEVMRecursiveFail%d", failCallCount), func(t *testing.T) {
_, wait, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "recursiveCall(uint256)", buildInputFromuint64(failCallCount))
_, wait, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "recursiveCall(uint256)", buildInputFromUint64(failCallCount))
require.Error(t, err)
require.Equal(t, exitcode.ExitCode(37), wait.Receipt.ExitCode)
})
@ -156,23 +119,51 @@ func TestFEVMRecursive2(t *testing.T) {
// TestFEVMRecursiveDelegatecallCount tests the maximum delegatecall recursion depth.
func TestFEVMRecursiveDelegatecallCount(t *testing.T) {
ctx, cancel, client := kit.SetupFEVMTest(t)
defer cancel()
highestSuccessCount := uint64(226)
// these depend on the actors bundle, may need to be adjusted with a network upgrade
const highestSuccessCount = 228
const expectedIterationsBeforeFailing = 222
filename := "contracts/RecursiveDelegeatecall.hex"
recursiveDelegatecallSuccess(ctx, t, client, filename, uint64(1))
recursiveDelegatecallSuccess(ctx, t, client, filename, uint64(2))
recursiveDelegatecallSuccess(ctx, t, client, filename, uint64(10))
recursiveDelegatecallSuccess(ctx, t, client, filename, uint64(100))
recursiveDelegatecallSuccess(ctx, t, client, filename, highestSuccessCount)
recursiveDelegatecallFail(ctx, t, client, filename, highestSuccessCount+1)
recursiveDelegatecallFail(ctx, t, client, filename, uint64(1000))
recursiveDelegatecallFail(ctx, t, client, filename, uint64(10000000))
testCases := []struct {
recursionCount uint64
expectSuccess bool
}{
// success
{1, true},
{2, true},
{10, true},
{100, true},
{highestSuccessCount, true},
// failure
{highestSuccessCount + 1, false},
{1000, false},
{10000000, false},
}
for _, tc := range testCases {
t.Run(fmt.Sprintf("recursionCount=%d,expectSuccess=%t", tc.recursionCount, tc.expectSuccess), func(t *testing.T) {
fromAddr, idAddr := client.EVM().DeployContractFromFilename(ctx, filename)
inputData := buildInputFromUint64(tc.recursionCount)
_, _, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "recursiveCall(uint256)", inputData)
require.NoError(t, err)
result, _, err := client.EVM().InvokeContractByFuncName(ctx, fromAddr, idAddr, "totalCalls()", []byte{})
require.NoError(t, err)
resultUint, err := decodeOutputToUint64(result)
require.NoError(t, err)
if tc.expectSuccess {
require.Equal(t, int(tc.recursionCount), int(resultUint))
} else {
require.NotEqual(t, int(resultUint), int(tc.recursionCount), "unexpected recursion count, if the actors bundle has changed, this test may need to be adjusted")
require.Equal(t, int(expectedIterationsBeforeFailing), int(resultUint))
}
})
}
}
// TestFEVMBasic does a basic fevm contract installation and invocation
@ -224,7 +215,7 @@ func TestFEVMETH0(t *testing.T) {
eth0Addr, err := address.NewDelegatedAddress(builtintypes.EthereumAddressManagerActorID, make([]byte, 20))
require.NoError(t, err)
require.Equal(t, *act.Address, eth0Addr)
require.Equal(t, *act.DelegatedAddress, eth0Addr)
}
// TestFEVMDelegateCall deploys two contracts and makes a delegate call transaction
@ -585,44 +576,52 @@ func TestFEVMRecursiveActorCall(t *testing.T) {
filenameActor := "contracts/RecCall.hex"
fromAddr, actorAddr := client.EVM().DeployContractFromFilename(ctx, filenameActor)
testN := func(n, r int, ex exitcode.ExitCode) func(t *testing.T) {
return func(t *testing.T) {
inputData := make([]byte, 32*3)
binary.BigEndian.PutUint64(inputData[24:], uint64(n))
binary.BigEndian.PutUint64(inputData[32+24:], uint64(n))
binary.BigEndian.PutUint64(inputData[32+32+24:], uint64(r))
exitCodeStackOverflow := exitcode.ExitCode(37)
exitCodeTransactionReverted := exitcode.ExitCode(33)
client.EVM().InvokeContractByFuncNameExpectExit(ctx, fromAddr, actorAddr, "exec1(uint256,uint256,uint256)", inputData, ex)
}
testCases := []struct {
stackDepth int
recursionLimit int
exitCode exitcode.ExitCode
}{
{0, 1, exitcode.Ok},
{1, 1, exitcode.Ok},
{20, 1, exitcode.Ok},
{200, 1, exitcode.Ok},
{251, 1, exitcode.Ok},
{252, 1, exitCodeStackOverflow},
{0, 10, exitcode.Ok},
{1, 10, exitcode.Ok},
{20, 10, exitcode.Ok},
{200, 10, exitcode.Ok},
{251, 10, exitcode.Ok},
{252, 10, exitCodeStackOverflow},
{0, 32, exitcode.Ok},
{1, 32, exitcode.Ok},
{20, 32, exitcode.Ok},
{200, 32, exitcode.Ok},
{251, 32, exitcode.Ok},
{252, 32, exitCodeStackOverflow},
// the following are actors bundle dependent and may need to be tweaked with a network upgrade
{0, 255, exitcode.Ok},
{251, 164, exitcode.Ok},
{0, 261, exitCodeTransactionReverted},
{251, 173, exitCodeTransactionReverted},
}
for _, tc := range testCases {
var fail string
if tc.exitCode != exitcode.Ok {
fail = "-fails"
}
t.Run(fmt.Sprintf("stackDepth=%d,recursionLimit=%d%s", tc.stackDepth, tc.recursionLimit, fail), func(t *testing.T) {
inputData := make([]byte, 32*3)
binary.BigEndian.PutUint64(inputData[24:], uint64(tc.stackDepth))
binary.BigEndian.PutUint64(inputData[32+24:], uint64(tc.stackDepth))
binary.BigEndian.PutUint64(inputData[32+32+24:], uint64(tc.recursionLimit))
t.Run("n=0,r=1", testN(0, 1, exitcode.Ok))
t.Run("n=1,r=1", testN(1, 1, exitcode.Ok))
t.Run("n=20,r=1", testN(20, 1, exitcode.Ok))
t.Run("n=200,r=1", testN(200, 1, exitcode.Ok))
t.Run("n=251,r=1", testN(251, 1, exitcode.Ok))
t.Run("n=252,r=1-fails", testN(252, 1, exitcode.ExitCode(37))) // 37 means stack overflow
t.Run("n=0,r=10", testN(0, 10, exitcode.Ok))
t.Run("n=1,r=10", testN(1, 10, exitcode.Ok))
t.Run("n=20,r=10", testN(20, 10, exitcode.Ok))
t.Run("n=200,r=10", testN(200, 10, exitcode.Ok))
t.Run("n=251,r=10", testN(251, 10, exitcode.Ok))
t.Run("n=252,r=10-fails", testN(252, 10, exitcode.ExitCode(37)))
t.Run("n=0,r=32", testN(0, 32, exitcode.Ok))
t.Run("n=1,r=32", testN(1, 32, exitcode.Ok))
t.Run("n=20,r=32", testN(20, 32, exitcode.Ok))
t.Run("n=200,r=32", testN(200, 32, exitcode.Ok))
t.Run("n=251,r=32", testN(251, 32, exitcode.Ok))
t.Run("n=0,r=252", testN(0, 252, exitcode.Ok))
t.Run("n=251,r=164", testN(251, 164, exitcode.Ok))
t.Run("n=0,r=255-fails", testN(0, 255, exitcode.ExitCode(33))) // 33 means transaction reverted
t.Run("n=251,r=167-fails", testN(251, 167, exitcode.ExitCode(33)))
client.EVM().InvokeContractByFuncNameExpectExit(ctx, fromAddr, actorAddr, "exec1(uint256,uint256,uint256)", inputData, tc.exitCode)
})
}
}
// TestFEVMRecursiveActorCallEstimate

View File

@ -100,6 +100,7 @@ func newPartitionTracker(ctx context.Context, t *testing.T, client v1api.FullNod
parts, err := client.StateMinerPartitions(ctx, minerAddr, dlIdx, types.EmptyTSK)
require.NoError(t, err)
return &partitionTracker{
minerAddr: minerAddr,
partitions: parts,
@ -245,7 +246,9 @@ func (bm *BlockMiner) MineBlocksMustPost(ctx context.Context, blocktime time.Dur
dlinfo, err := bm.miner.FullNode.StateMinerProvingDeadline(ctx, minerAddr, ts.Key())
require.NoError(bm.t, err)
require.NotNil(bm.t, dlinfo, "no deadline info for miner %s", minerAddr)
impendingDeadlines = append(impendingDeadlines, minerDeadline{addr: minerAddr, deadline: *dlinfo})
if dlinfo.Open < dlinfo.CurrentEpoch {
impendingDeadlines = append(impendingDeadlines, minerDeadline{addr: minerAddr, deadline: *dlinfo})
} // else this is probably a new miner, not starting in this proving period
}
bm.postWatchMinersLk.Unlock()
impendingDeadlines = impendingDeadlines.FilterByLast(ts.Height() + 5 + abi.ChainEpoch(nulls))

View File

@ -260,7 +260,7 @@ func (n *Ensemble) MinerEnroll(minerNode *TestMiner, full *TestFullNode, opts ..
)
// Will use 2KiB sectors by default (default value of sectorSize).
proofType, err := miner.SealProofTypeFromSectorSize(options.sectorSize, n.genesis.version, false)
proofType, err := miner.SealProofTypeFromSectorSize(options.sectorSize, n.genesis.version, miner.SealProofVariant_Standard)
require.NoError(n.t, err)
// Create the preseal commitment.
@ -327,7 +327,7 @@ func (n *Ensemble) UnmanagedMiner(full *TestFullNode, opts ...NodeOpt) (*TestUnm
actorAddr, err := address.NewIDAddress(genesis2.MinerStart + n.minerCount())
require.NoError(n.t, err)
minerNode := NewTestUnmanagedMiner(n.t, full, actorAddr, opts...)
minerNode := NewTestUnmanagedMiner(n.t, full, actorAddr, n.options.mockProofs, opts...)
n.AddInactiveUnmanagedMiner(minerNode)
return minerNode, n
}

View File

@ -25,6 +25,7 @@ import (
const DefaultPresealsPerBootstrapMiner = 2
const TestSpt = abi.RegisteredSealProof_StackedDrg2KiBV1_1
const TestSptNi = abi.RegisteredSealProof_StackedDrg2KiBV1_2_Feat_NiPoRep
// nodeOpts is an options accumulating struct, where functional options are
// merged into.

View File

@ -6,6 +6,7 @@ import (
"crypto/rand"
"fmt"
"io"
"math"
"os"
"path/filepath"
"testing"
@ -34,8 +35,9 @@ import (
// TestUnmanagedMiner is a miner that's not managed by the storage/infrastructure, all tasks must be manually executed, managed and scheduled by the test or test kit.
// Note: `TestUnmanagedMiner` is not thread safe and assumes linear access of it's methods
type TestUnmanagedMiner struct {
t *testing.T
options nodeOpts
t *testing.T
options nodeOpts
mockProofs bool
cacheDir string
unsealedSectorDir string
@ -65,7 +67,7 @@ type WindowPostResp struct {
Error error
}
func NewTestUnmanagedMiner(t *testing.T, full *TestFullNode, actorAddr address.Address, opts ...NodeOpt) *TestUnmanagedMiner {
func NewTestUnmanagedMiner(t *testing.T, full *TestFullNode, actorAddr address.Address, mockProofs bool, opts ...NodeOpt) *TestUnmanagedMiner {
require.NotNil(t, full, "full node required when instantiating miner")
options := DefaultNodeOpts
@ -94,6 +96,7 @@ func NewTestUnmanagedMiner(t *testing.T, full *TestFullNode, actorAddr address.A
tm := TestUnmanagedMiner{
t: t,
options: options,
mockProofs: mockProofs,
cacheDir: cacheDir,
unsealedSectorDir: unsealedSectorDir,
sealedSectorDir: sealedSectorDir,
@ -222,137 +225,6 @@ func (tm *TestUnmanagedMiner) makeAndSaveCCSector(_ context.Context, sectorNumbe
tm.cacheDirPaths[sectorNumber] = cacheDirPath
}
func (tm *TestUnmanagedMiner) OnboardSectorWithPiecesAndRealProofs(ctx context.Context, proofType abi.RegisteredSealProof) (abi.SectorNumber, chan WindowPostResp,
context.CancelFunc) {
req := require.New(tm.t)
sectorNumber := tm.currentSectorNum
tm.currentSectorNum++
// Step 1: Wait for the pre-commitseal randomness to be available (we can only draw seal randomness from tipsets that have already achieved finality)
preCommitSealRand := tm.waitPreCommitSealRandomness(ctx, sectorNumber)
// Step 2: Build a sector with non 0 Pieces that we want to onboard
pieces := tm.mkAndSavePiecesToOnboard(ctx, sectorNumber, proofType)
// Step 3: Generate a Pre-Commit for the CC sector -> this persists the proof on the `TestUnmanagedMiner` Miner State
tm.generatePreCommit(ctx, sectorNumber, preCommitSealRand, proofType, pieces)
// Step 4 : Submit the Pre-Commit to the network
unsealedCid := tm.unsealedCids[sectorNumber]
r, err := tm.submitMessage(ctx, &miner14.PreCommitSectorBatchParams2{
Sectors: []miner14.SectorPreCommitInfo{{
Expiration: 2880 * 300,
SectorNumber: sectorNumber,
SealProof: TestSpt,
SealedCID: tm.sealedCids[sectorNumber],
SealRandEpoch: preCommitSealRand,
UnsealedCid: &unsealedCid,
}},
}, 1, builtin.MethodsMiner.PreCommitSectorBatch2)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
// Step 5: Generate a ProveCommit for the CC sector
waitSeedRandomness := tm.proveCommitWaitSeed(ctx, sectorNumber)
proveCommit := tm.generateProveCommit(ctx, sectorNumber, proofType, waitSeedRandomness, pieces)
// Step 6: Submit the ProveCommit to the network
tm.t.Log("Submitting ProveCommitSector ...")
var manifest []miner14.PieceActivationManifest
for _, piece := range pieces {
manifest = append(manifest, miner14.PieceActivationManifest{
CID: piece.PieceCID,
Size: piece.Size,
})
}
r, err = tm.submitMessage(ctx, &miner14.ProveCommitSectors3Params{
SectorActivations: []miner14.SectorActivationManifest{{SectorNumber: sectorNumber, Pieces: manifest}},
SectorProofs: [][]byte{proveCommit},
RequireActivationSuccess: true,
}, 1, builtin.MethodsMiner.ProveCommitSectors3)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
tm.proofType[sectorNumber] = proofType
respCh := make(chan WindowPostResp, 1)
wdCtx, cancelF := context.WithCancel(ctx)
go tm.wdPostLoop(wdCtx, sectorNumber, respCh, false, tm.sealedCids[sectorNumber], tm.sealedSectorPaths[sectorNumber], tm.cacheDirPaths[sectorNumber])
return sectorNumber, respCh, cancelF
}
func (tm *TestUnmanagedMiner) OnboardSectorWithPiecesAndMockProofs(ctx context.Context, proofType abi.RegisteredSealProof) (abi.SectorNumber, chan WindowPostResp,
context.CancelFunc) {
req := require.New(tm.t)
sectorNumber := tm.currentSectorNum
tm.currentSectorNum++
// Step 1: Wait for the pre-commitseal randomness to be available (we can only draw seal randomness from tipsets that have already achieved finality)
preCommitSealRand := tm.waitPreCommitSealRandomness(ctx, sectorNumber)
// Step 2: Build a sector with non 0 Pieces that we want to onboard
pieces := []abi.PieceInfo{{
Size: abi.PaddedPieceSize(tm.options.sectorSize),
PieceCID: cid.MustParse("baga6ea4seaqjtovkwk4myyzj56eztkh5pzsk5upksan6f5outesy62bsvl4dsha"),
}}
// Step 3: Generate a Pre-Commit for the CC sector -> this persists the proof on the `TestUnmanagedMiner` Miner State
tm.sealedCids[sectorNumber] = cid.MustParse("bagboea4b5abcatlxechwbp7kjpjguna6r6q7ejrhe6mdp3lf34pmswn27pkkiekz")
tm.unsealedCids[sectorNumber] = cid.MustParse("baga6ea4seaqjtovkwk4myyzj56eztkh5pzsk5upksan6f5outesy62bsvl4dsha")
// Step 4 : Submit the Pre-Commit to the network
unsealedCid := tm.unsealedCids[sectorNumber]
r, err := tm.submitMessage(ctx, &miner14.PreCommitSectorBatchParams2{
Sectors: []miner14.SectorPreCommitInfo{{
Expiration: 2880 * 300,
SectorNumber: sectorNumber,
SealProof: TestSpt,
SealedCID: tm.sealedCids[sectorNumber],
SealRandEpoch: preCommitSealRand,
UnsealedCid: &unsealedCid,
}},
}, 1, builtin.MethodsMiner.PreCommitSectorBatch2)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
// Step 5: Generate a ProveCommit for the CC sector
_ = tm.proveCommitWaitSeed(ctx, sectorNumber)
sectorProof := []byte{0xde, 0xad, 0xbe, 0xef}
// Step 6: Submit the ProveCommit to the network
tm.t.Log("Submitting ProveCommitSector ...")
var manifest []miner14.PieceActivationManifest
for _, piece := range pieces {
manifest = append(manifest, miner14.PieceActivationManifest{
CID: piece.PieceCID,
Size: piece.Size,
})
}
r, err = tm.submitMessage(ctx, &miner14.ProveCommitSectors3Params{
SectorActivations: []miner14.SectorActivationManifest{{SectorNumber: sectorNumber, Pieces: manifest}},
SectorProofs: [][]byte{sectorProof},
RequireActivationSuccess: true,
}, 1, builtin.MethodsMiner.ProveCommitSectors3)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
tm.proofType[sectorNumber] = proofType
respCh := make(chan WindowPostResp, 1)
wdCtx, cancelF := context.WithCancel(ctx)
go tm.wdPostLoop(wdCtx, sectorNumber, respCh, true, tm.sealedCids[sectorNumber], tm.sealedSectorPaths[sectorNumber], tm.cacheDirPaths[sectorNumber])
return sectorNumber, respCh, cancelF
}
func (tm *TestUnmanagedMiner) mkStagedFileWithPieces(pt abi.RegisteredSealProof) ([]abi.PieceInfo, string) {
paddedPieceSize := abi.PaddedPieceSize(tm.options.sectorSize)
unpaddedPieceSize := paddedPieceSize.Unpadded()
@ -393,35 +265,51 @@ func (tm *TestUnmanagedMiner) mkStagedFileWithPieces(pt abi.RegisteredSealProof)
return publicPieces, unsealedSectorFile.Name()
}
func (tm *TestUnmanagedMiner) SnapDealWithRealProofs(ctx context.Context, proofType abi.RegisteredSealProof, sectorNumber abi.SectorNumber) {
// generate sector key
pieces, unsealedPath := tm.mkStagedFileWithPieces(proofType)
func (tm *TestUnmanagedMiner) SnapDeal(ctx context.Context, proofType abi.RegisteredSealProof, sectorNumber abi.SectorNumber) []abi.PieceInfo {
updateProofType := abi.SealProofInfos[proofType].UpdateProof
var pieces []abi.PieceInfo
var snapProof []byte
var newSealedCid cid.Cid
s, err := os.Stat(tm.sealedSectorPaths[sectorNumber])
require.NoError(tm.t, err)
if !tm.mockProofs {
// generate sector key
var unsealedPath string
pieces, unsealedPath = tm.mkStagedFileWithPieces(proofType)
randomBytes := make([]byte, s.Size())
_, err = io.ReadFull(rand.Reader, randomBytes)
require.NoError(tm.t, err)
s, err := os.Stat(tm.sealedSectorPaths[sectorNumber])
require.NoError(tm.t, err)
updatePath := requireTempFile(tm.t, bytes.NewReader(randomBytes), uint64(s.Size()))
require.NoError(tm.t, updatePath.Close())
updateDir := filepath.Join(tm.t.TempDir(), fmt.Sprintf("update-%d", sectorNumber))
require.NoError(tm.t, os.MkdirAll(updateDir, 0700))
randomBytes := make([]byte, s.Size())
_, err = io.ReadFull(rand.Reader, randomBytes)
require.NoError(tm.t, err)
newSealed, newUnsealed, err := ffi.SectorUpdate.EncodeInto(updateProofType, updatePath.Name(), updateDir,
tm.sealedSectorPaths[sectorNumber], tm.cacheDirPaths[sectorNumber], unsealedPath, pieces)
require.NoError(tm.t, err)
updatePath := requireTempFile(tm.t, bytes.NewReader(randomBytes), uint64(s.Size()))
require.NoError(tm.t, updatePath.Close())
updateDir := filepath.Join(tm.t.TempDir(), fmt.Sprintf("update-%d", sectorNumber))
require.NoError(tm.t, os.MkdirAll(updateDir, 0700))
vp, err := ffi.SectorUpdate.GenerateUpdateVanillaProofs(updateProofType, tm.sealedCids[sectorNumber],
newSealed, newUnsealed, updatePath.Name(), updateDir, tm.sealedSectorPaths[sectorNumber],
tm.cacheDirPaths[sectorNumber])
require.NoError(tm.t, err)
var newUnsealedCid cid.Cid
newSealedCid, newUnsealedCid, err = ffi.SectorUpdate.EncodeInto(updateProofType, updatePath.Name(), updateDir,
tm.sealedSectorPaths[sectorNumber], tm.cacheDirPaths[sectorNumber], unsealedPath, pieces)
require.NoError(tm.t, err)
vp, err := ffi.SectorUpdate.GenerateUpdateVanillaProofs(updateProofType, tm.sealedCids[sectorNumber],
newSealedCid, newUnsealedCid, updatePath.Name(), updateDir, tm.sealedSectorPaths[sectorNumber],
tm.cacheDirPaths[sectorNumber])
require.NoError(tm.t, err)
snapProof, err = ffi.SectorUpdate.GenerateUpdateProofWithVanilla(updateProofType, tm.sealedCids[sectorNumber],
newSealedCid, newUnsealedCid, vp)
require.NoError(tm.t, err)
} else {
pieces = []abi.PieceInfo{{
Size: abi.PaddedPieceSize(tm.options.sectorSize),
PieceCID: cid.MustParse("baga6ea4seaqlhznlutptgfwhffupyer6txswamerq5fc2jlwf2lys2mm5jtiaeq"),
}}
snapProof = []byte{0xde, 0xad, 0xbe, 0xef}
newSealedCid = cid.MustParse("bagboea4b5abcatlxechwbp7kjpjguna6r6q7ejrhe6mdp3lf34pmswn27pkkieka")
}
snapProof, err := ffi.SectorUpdate.GenerateUpdateProofWithVanilla(updateProofType, tm.sealedCids[sectorNumber],
newSealed, newUnsealed, vp)
require.NoError(tm.t, err)
tm.waitForMutableDeadline(ctx, sectorNumber)
// submit proof
@ -445,7 +333,7 @@ func (tm *TestUnmanagedMiner) SnapDealWithRealProofs(ctx context.Context, proofT
Sector: sectorNumber,
Deadline: sl.Deadline,
Partition: sl.Partition,
NewSealedCID: newSealed,
NewSealedCID: newSealedCid,
Pieces: manifest,
},
},
@ -454,9 +342,11 @@ func (tm *TestUnmanagedMiner) SnapDealWithRealProofs(ctx context.Context, proofT
RequireActivationSuccess: true,
RequireNotificationSuccess: false,
}
r, err := tm.submitMessage(ctx, params, 1, builtin.MethodsMiner.ProveReplicaUpdates3)
r, err := tm.SubmitMessage(ctx, params, 1, builtin.MethodsMiner.ProveReplicaUpdates3)
require.NoError(tm.t, err)
require.True(tm.t, r.Receipt.ExitCode.IsSuccess())
return pieces
}
func (tm *TestUnmanagedMiner) waitForMutableDeadline(ctx context.Context, sectorNum abi.SectorNumber) {
@ -489,112 +379,246 @@ func (tm *TestUnmanagedMiner) waitForMutableDeadline(ctx context.Context, sector
}
}
func (tm *TestUnmanagedMiner) OnboardCCSectorWithMockProofs(ctx context.Context, proofType abi.RegisteredSealProof) (abi.SectorNumber, chan WindowPostResp,
context.CancelFunc) {
req := require.New(tm.t)
func (tm *TestUnmanagedMiner) NextSectorNumber() abi.SectorNumber {
sectorNumber := tm.currentSectorNum
tm.currentSectorNum++
// Step 1: Wait for the pre-commitseal randomness to be available (we can only draw seal randomness from tipsets that have already achieved finality)
preCommitSealRand := tm.waitPreCommitSealRandomness(ctx, sectorNumber)
tm.sealedCids[sectorNumber] = cid.MustParse("bagboea4b5abcatlxechwbp7kjpjguna6r6q7ejrhe6mdp3lf34pmswn27pkkiekz")
// Step 4 : Submit the Pre-Commit to the network
r, err := tm.submitMessage(ctx, &miner14.PreCommitSectorBatchParams2{
Sectors: []miner14.SectorPreCommitInfo{{
Expiration: 2880 * 300,
SectorNumber: sectorNumber,
SealProof: TestSpt,
SealedCID: tm.sealedCids[sectorNumber],
SealRandEpoch: preCommitSealRand,
}},
}, 1, builtin.MethodsMiner.PreCommitSectorBatch2)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
// Step 5: Generate a ProveCommit for the CC sector
_ = tm.proveCommitWaitSeed(ctx, sectorNumber)
sectorProof := []byte{0xde, 0xad, 0xbe, 0xef}
// Step 6: Submit the ProveCommit to the network
tm.t.Log("Submitting ProveCommitSector ...")
r, err = tm.submitMessage(ctx, &miner14.ProveCommitSectors3Params{
SectorActivations: []miner14.SectorActivationManifest{{SectorNumber: sectorNumber}},
SectorProofs: [][]byte{sectorProof},
RequireActivationSuccess: true,
}, 0, builtin.MethodsMiner.ProveCommitSectors3)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
tm.proofType[sectorNumber] = proofType
respCh := make(chan WindowPostResp, 1)
wdCtx, cancelF := context.WithCancel(ctx)
go tm.wdPostLoop(wdCtx, sectorNumber, respCh, true, tm.sealedCids[sectorNumber], tm.sealedSectorPaths[sectorNumber], tm.cacheDirPaths[sectorNumber])
return sectorNumber, respCh, cancelF
return sectorNumber
}
func (tm *TestUnmanagedMiner) OnboardCCSectorWithRealProofs(ctx context.Context, proofType abi.RegisteredSealProof) (abi.SectorNumber, chan WindowPostResp,
context.CancelFunc) {
func (tm *TestUnmanagedMiner) PrepareSectorForProveCommit(
ctx context.Context,
proofType abi.RegisteredSealProof,
sectorNumber abi.SectorNumber,
pieces []abi.PieceInfo,
) (seedEpoch abi.ChainEpoch, proveCommit []byte) {
req := require.New(tm.t)
sectorNumber := tm.currentSectorNum
tm.currentSectorNum++
// Wait for the pre-commitseal randomness to be available (we can only draw seal randomness from tipsets that have already achieved finality)
preCommitSealRandEpoch := tm.waitPreCommitSealRandomness(ctx, sectorNumber, proofType)
// Generate a Pre-Commit for the CC sector -> this persists the proof on the `TestUnmanagedMiner` Miner State
tm.generatePreCommit(ctx, sectorNumber, preCommitSealRandEpoch, proofType, pieces)
// --------------------Create pre-commit for the CC sector -> we'll just pre-commit `sector size` worth of 0s for this CC sector
// Step 1: Wait for the pre-commitseal randomness to be available (we can only draw seal randomness from tipsets that have already achieved finality)
preCommitSealRand := tm.waitPreCommitSealRandomness(ctx, sectorNumber)
if !proofType.IsNonInteractive() {
// Submit the Pre-Commit to the network
var uc *cid.Cid
if len(pieces) > 0 {
unsealedCid := tm.unsealedCids[sectorNumber]
uc = &unsealedCid
}
r, err := tm.SubmitMessage(ctx, &miner14.PreCommitSectorBatchParams2{
Sectors: []miner14.SectorPreCommitInfo{{
Expiration: 2880 * 300,
SectorNumber: sectorNumber,
SealProof: proofType,
SealedCID: tm.sealedCids[sectorNumber],
SealRandEpoch: preCommitSealRandEpoch,
UnsealedCid: uc,
}},
}, 1, builtin.MethodsMiner.PreCommitSectorBatch2)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
}
// Step 2: Write empty bytes that we want to seal i.e. create our CC sector
tm.makeAndSaveCCSector(ctx, sectorNumber)
// Generate a ProveCommit for the CC sector
var seedRandomness abi.InteractiveSealRandomness
seedEpoch, seedRandomness = tm.proveCommitWaitSeed(ctx, sectorNumber, proofType)
// Step 3: Generate a Pre-Commit for the CC sector -> this persists the proof on the `TestUnmanagedMiner` Miner State
tm.generatePreCommit(ctx, sectorNumber, preCommitSealRand, proofType, []abi.PieceInfo{})
proveCommit = []byte{0xde, 0xad, 0xbe, 0xef} // mock prove commit
if !tm.mockProofs {
proveCommit = tm.generateProveCommit(ctx, sectorNumber, proofType, seedRandomness, pieces)
}
// Step 4 : Submit the Pre-Commit to the network
r, err := tm.submitMessage(ctx, &miner14.PreCommitSectorBatchParams2{
Sectors: []miner14.SectorPreCommitInfo{{
Expiration: 2880 * 300,
SectorNumber: sectorNumber,
SealProof: TestSpt,
SealedCID: tm.sealedCids[sectorNumber],
SealRandEpoch: preCommitSealRand,
}},
}, 1, builtin.MethodsMiner.PreCommitSectorBatch2)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
// Step 5: Generate a ProveCommit for the CC sector
waitSeedRandomness := tm.proveCommitWaitSeed(ctx, sectorNumber)
proveCommit := tm.generateProveCommit(ctx, sectorNumber, proofType, waitSeedRandomness, []abi.PieceInfo{})
// Step 6: Submit the ProveCommit to the network
tm.t.Log("Submitting ProveCommitSector ...")
r, err = tm.submitMessage(ctx, &miner14.ProveCommitSectors3Params{
SectorActivations: []miner14.SectorActivationManifest{{SectorNumber: sectorNumber}},
SectorProofs: [][]byte{proveCommit},
RequireActivationSuccess: true,
}, 0, builtin.MethodsMiner.ProveCommitSectors3)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
tm.proofType[sectorNumber] = proofType
respCh := make(chan WindowPostResp, 1)
wdCtx, cancelF := context.WithCancel(ctx)
go tm.wdPostLoop(wdCtx, sectorNumber, respCh, false, tm.sealedCids[sectorNumber], tm.sealedSectorPaths[sectorNumber], tm.cacheDirPaths[sectorNumber])
return sectorNumber, respCh, cancelF
return seedEpoch, proveCommit
}
func (tm *TestUnmanagedMiner) wdPostLoop(ctx context.Context, sectorNumber abi.SectorNumber, respCh chan WindowPostResp, withMockProofs bool, sealedCid cid.Cid, sealedPath, cacheDir string) {
func (tm *TestUnmanagedMiner) SubmitProveCommit(
ctx context.Context,
proofType abi.RegisteredSealProof,
sectorNumber abi.SectorNumber,
seedEpoch abi.ChainEpoch,
proveCommit []byte,
pieceManifest []miner14.PieceActivationManifest,
) {
req := require.New(tm.t)
if proofType.IsNonInteractive() {
req.Nil(pieceManifest, "piece manifest should be nil for Non-interactive PoRep")
}
// Step 6: Submit the ProveCommit to the network
if proofType.IsNonInteractive() {
tm.t.Log("Submitting ProveCommitSector ...")
var provingDeadline uint64 = 7
if tm.IsImmutableDeadline(ctx, provingDeadline) {
// avoid immutable deadlines
provingDeadline = 5
}
actorIdNum, err := address.IDFromAddress(tm.ActorAddr)
req.NoError(err)
actorId := abi.ActorID(actorIdNum)
r, err := tm.SubmitMessage(ctx, &miner14.ProveCommitSectorsNIParams{
Sectors: []miner14.SectorNIActivationInfo{{
SealingNumber: sectorNumber,
SealerID: actorId,
SealedCID: tm.sealedCids[sectorNumber],
SectorNumber: sectorNumber,
SealRandEpoch: seedEpoch,
Expiration: 2880 * 300,
}},
AggregateProof: proveCommit,
SealProofType: proofType,
AggregateProofType: abi.RegisteredAggregationProof_SnarkPackV2,
ProvingDeadline: provingDeadline,
RequireActivationSuccess: true,
}, 1, builtin.MethodsMiner.ProveCommitSectorsNI)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
// NI-PoRep lets us determine the deadline, so we can check that it's set correctly
sp, err := tm.FullNode.StateSectorPartition(ctx, tm.ActorAddr, sectorNumber, r.TipSet)
req.NoError(err)
req.Equal(provingDeadline, sp.Deadline)
} else {
tm.t.Log("Submitting ProveCommitSector ...")
r, err := tm.SubmitMessage(ctx, &miner14.ProveCommitSectors3Params{
SectorActivations: []miner14.SectorActivationManifest{{SectorNumber: sectorNumber, Pieces: pieceManifest}},
SectorProofs: [][]byte{proveCommit},
RequireActivationSuccess: true,
}, 0, builtin.MethodsMiner.ProveCommitSectors3)
req.NoError(err)
req.True(r.Receipt.ExitCode.IsSuccess())
}
}
func (tm *TestUnmanagedMiner) OnboardCCSector(ctx context.Context, proofType abi.RegisteredSealProof) (abi.SectorNumber, chan WindowPostResp, context.CancelFunc) {
sectorNumber := tm.NextSectorNumber()
if !tm.mockProofs {
// Write empty bytes that we want to seal i.e. create our CC sector
tm.makeAndSaveCCSector(ctx, sectorNumber)
}
seedEpoch, proveCommit := tm.PrepareSectorForProveCommit(ctx, proofType, sectorNumber, []abi.PieceInfo{})
tm.SubmitProveCommit(ctx, proofType, sectorNumber, seedEpoch, proveCommit, nil)
tm.proofType[sectorNumber] = proofType
respCh, cancelFn := tm.wdPostLoop(ctx, sectorNumber, tm.sealedCids[sectorNumber], tm.sealedSectorPaths[sectorNumber], tm.cacheDirPaths[sectorNumber])
return sectorNumber, respCh, cancelFn
}
func (tm *TestUnmanagedMiner) OnboardSectorWithPieces(ctx context.Context, proofType abi.RegisteredSealProof) (abi.SectorNumber, chan WindowPostResp, context.CancelFunc) {
sectorNumber := tm.NextSectorNumber()
// Build a sector with non 0 Pieces that we want to onboard
var pieces []abi.PieceInfo
if !tm.mockProofs {
pieces = tm.mkAndSavePiecesToOnboard(ctx, sectorNumber, proofType)
} else {
pieces = []abi.PieceInfo{{
Size: abi.PaddedPieceSize(tm.options.sectorSize),
PieceCID: cid.MustParse("baga6ea4seaqjtovkwk4myyzj56eztkh5pzsk5upksan6f5outesy62bsvl4dsha"),
}}
}
_, proveCommit := tm.PrepareSectorForProveCommit(ctx, proofType, sectorNumber, pieces)
// Submit the ProveCommit to the network
tm.t.Log("Submitting ProveCommitSector ...")
var manifest []miner14.PieceActivationManifest
for _, piece := range pieces {
manifest = append(manifest, miner14.PieceActivationManifest{
CID: piece.PieceCID,
Size: piece.Size,
})
}
tm.SubmitProveCommit(ctx, proofType, sectorNumber, 0, proveCommit, manifest)
tm.proofType[sectorNumber] = proofType
respCh, cancelFn := tm.wdPostLoop(ctx, sectorNumber, tm.sealedCids[sectorNumber], tm.sealedSectorPaths[sectorNumber], tm.cacheDirPaths[sectorNumber])
return sectorNumber, respCh, cancelFn
}
// calculateNextPostEpoch calculates the first epoch of the deadline proving window
// that is desired for the given sector for the specified miner.
// This function returns the current epoch and the calculated proving epoch.
func (tm *TestUnmanagedMiner) calculateNextPostEpoch(
ctx context.Context,
sectorNumber abi.SectorNumber,
) (abi.ChainEpoch, abi.ChainEpoch, error) {
// Retrieve the current blockchain head
head, err := tm.FullNode.ChainHead(ctx)
if err != nil {
return 0, 0, fmt.Errorf("failed to get chain head: %w", err)
}
// Obtain the proving deadline information for the miner
di, err := tm.FullNode.StateMinerProvingDeadline(ctx, tm.ActorAddr, head.Key())
if err != nil {
return 0, 0, fmt.Errorf("failed to get proving deadline: %w", err)
}
tm.t.Logf("Miner %s: WindowPoST(%d): ProvingDeadline: %+v", tm.ActorAddr, sectorNumber, di)
// Fetch the sector partition for the given sector number
sp, err := tm.FullNode.StateSectorPartition(ctx, tm.ActorAddr, sectorNumber, head.Key())
if err != nil {
return 0, 0, fmt.Errorf("failed to get sector partition: %w", err)
}
tm.t.Logf("Miner %s: WindowPoST(%d): SectorPartition: %+v", tm.ActorAddr, sectorNumber, sp)
// Calculate the start of the period, adjusting if the current deadline has passed
periodStart := di.PeriodStart
// calculate current deadline index because it won't be reliable from state until the first
// challenge window cron tick after first sector onboarded
currentDeadlineIdx := uint64(math.Abs(float64((di.CurrentEpoch - di.PeriodStart) / di.WPoStChallengeWindow)))
if di.PeriodStart < di.CurrentEpoch && sp.Deadline <= currentDeadlineIdx {
// If the deadline has passed in the current proving period, calculate for the next period
// Note that di.Open may be > di.CurrentEpoch if the miner has just been enrolled in cron so
// their deadlines haven't started rolling yet
periodStart += di.WPoStProvingPeriod
}
// Calculate the exact epoch when proving should occur
provingEpoch := periodStart + di.WPoStChallengeWindow*abi.ChainEpoch(sp.Deadline)
tm.t.Logf("Miner %s: WindowPoST(%d): next ProvingEpoch: %d", tm.ActorAddr, sectorNumber, provingEpoch)
return di.CurrentEpoch, provingEpoch, nil
}
func (tm *TestUnmanagedMiner) wdPostLoop(
pctx context.Context,
sectorNumber abi.SectorNumber,
sealedCid cid.Cid,
sealedPath,
cacheDir string,
) (chan WindowPostResp, context.CancelFunc) {
ctx, cancelFn := context.WithCancel(pctx)
respCh := make(chan WindowPostResp, 1)
head, err := tm.FullNode.ChainHead(ctx)
require.NoError(tm.t, err)
// wait one challenge window for cron to do its thing with deadlines, just to be sure so we get
// an accurate dline.Info whenever we ask for it
_ = tm.FullNode.WaitTillChain(ctx, HeightAtLeast(head.Height()+miner14.WPoStChallengeWindow+5))
go func() {
var firstPost bool
@ -628,6 +652,8 @@ func (tm *TestUnmanagedMiner) wdPostLoop(ctx context.Context, sectorNumber abi.S
return
}
nextPost += 5 // add some padding so we're properly into the window
if nextPost > currentEpoch {
if _, err := tm.FullNode.WaitTillChainOrError(ctx, HeightAtLeast(nextPost)); err != nil {
writeRespF(err)
@ -635,12 +661,17 @@ func (tm *TestUnmanagedMiner) wdPostLoop(ctx context.Context, sectorNumber abi.S
}
}
err = tm.submitWindowPost(ctx, sectorNumber, withMockProofs, sealedCid, sealedPath, cacheDir)
err = tm.submitWindowPost(ctx, sectorNumber, sealedCid, sealedPath, cacheDir)
writeRespF(err) // send an error, or first post, or nothing if no error and this isn't the first post
if err != nil {
return
}
postCount++
tm.t.Logf("Sector %d: WindowPoSt #%d submitted", sectorNumber, postCount)
}
}()
return respCh, cancelFn
}
func (tm *TestUnmanagedMiner) SubmitPostDispute(ctx context.Context, sectorNumber abi.SectorNumber) error {
@ -668,14 +699,14 @@ func (tm *TestUnmanagedMiner) SubmitPostDispute(ctx context.Context, sectorNumbe
tm.t.Logf("Miner %s: Sector %d - Disputing WindowedPoSt to confirm validity at epoch %d", tm.ActorAddr, sectorNumber, disputeEpoch)
_, err = tm.submitMessage(ctx, &miner14.DisputeWindowedPoStParams{
_, err = tm.SubmitMessage(ctx, &miner14.DisputeWindowedPoStParams{
Deadline: sp.Deadline,
PoStIndex: 0,
}, 1, builtin.MethodsMiner.DisputeWindowedPoSt)
return err
}
func (tm *TestUnmanagedMiner) submitWindowPost(ctx context.Context, sectorNumber abi.SectorNumber, withMockProofs bool, sealedCid cid.Cid, sealedPath, cacheDir string) error {
func (tm *TestUnmanagedMiner) submitWindowPost(ctx context.Context, sectorNumber abi.SectorNumber, sealedCid cid.Cid, sealedPath, cacheDir string) error {
tm.t.Logf("Miner(%s): WindowPoST(%d): Running WindowPoSt ...\n", tm.ActorAddr, sectorNumber)
head, err := tm.FullNode.ChainHead(ctx)
@ -698,7 +729,7 @@ func (tm *TestUnmanagedMiner) submitWindowPost(ctx context.Context, sectorNumber
}
var proofBytes []byte
if withMockProofs {
if tm.mockProofs {
proofBytes = []byte{0xde, 0xad, 0xbe, 0xef}
} else {
proofBytes, err = tm.generateWindowPost(ctx, sectorNumber, sealedCid, sealedPath, cacheDir)
@ -721,7 +752,7 @@ func (tm *TestUnmanagedMiner) submitWindowPost(ctx context.Context, sectorNumber
return fmt.Errorf("Miner(%s): failed to get miner info for sector %d: %w", tm.ActorAddr, sectorNumber, err)
}
r, err := tm.submitMessage(ctx, &miner14.SubmitWindowedPoStParams{
r, err := tm.SubmitMessage(ctx, &miner14.SubmitWindowedPoStParams{
ChainCommitEpoch: chainRandomnessEpoch,
ChainCommitRand: chainRandomness,
Deadline: sp.Deadline,
@ -824,12 +855,16 @@ func (tm *TestUnmanagedMiner) generateWindowPost(
return proofBytes, nil
}
func (tm *TestUnmanagedMiner) waitPreCommitSealRandomness(ctx context.Context, sectorNumber abi.SectorNumber) abi.ChainEpoch {
func (tm *TestUnmanagedMiner) waitPreCommitSealRandomness(ctx context.Context, sectorNumber abi.SectorNumber, proofType abi.RegisteredSealProof) abi.ChainEpoch {
// We want to draw seal randomness from a tipset that has already achieved finality as PreCommits are expensive to re-generate.
// Check if we already have an epoch that is already final and wait for such an epoch if we don't have one.
head, err := tm.FullNode.ChainHead(ctx)
require.NoError(tm.t, err)
if proofType.IsNonInteractive() {
return head.Height() - 1 // no need to wait
}
var sealRandEpoch abi.ChainEpoch
if head.Height() > policy.SealRandomnessLookback {
sealRandEpoch = head.Height() - policy.SealRandomnessLookback
@ -845,50 +880,6 @@ func (tm *TestUnmanagedMiner) waitPreCommitSealRandomness(ctx context.Context, s
return sealRandEpoch
}
// calculateNextPostEpoch calculates the first epoch of the deadline proving window
// that is desired for the given sector for the specified miner.
// This function returns the current epoch and the calculated proving epoch.
func (tm *TestUnmanagedMiner) calculateNextPostEpoch(
ctx context.Context,
sectorNumber abi.SectorNumber,
) (abi.ChainEpoch, abi.ChainEpoch, error) {
// Retrieve the current blockchain head
head, err := tm.FullNode.ChainHead(ctx)
if err != nil {
return 0, 0, fmt.Errorf("failed to get chain head: %w", err)
}
// Fetch the sector partition for the given sector number
sp, err := tm.FullNode.StateSectorPartition(ctx, tm.ActorAddr, sectorNumber, head.Key())
if err != nil {
return 0, 0, fmt.Errorf("failed to get sector partition: %w", err)
}
tm.t.Logf("Miner %s: WindowPoST(%d): SectorPartition: %+v", tm.ActorAddr, sectorNumber, sp)
// Obtain the proving deadline information for the miner
di, err := tm.FullNode.StateMinerProvingDeadline(ctx, tm.ActorAddr, head.Key())
if err != nil {
return 0, 0, fmt.Errorf("failed to get proving deadline: %w", err)
}
tm.t.Logf("Miner %s: WindowPoST(%d): ProvingDeadline: %+v", tm.ActorAddr, sectorNumber, di)
// Calculate the start of the period, adjusting if the current deadline has passed
periodStart := di.PeriodStart
if di.PeriodStart < di.CurrentEpoch && sp.Deadline <= di.Index {
// If the deadline has passed in the current proving period, calculate for the next period
periodStart += di.WPoStProvingPeriod
}
// Calculate the exact epoch when proving should occur
provingEpoch := periodStart + (di.WPoStProvingPeriod/abi.ChainEpoch(di.WPoStPeriodDeadlines))*abi.ChainEpoch(sp.Deadline)
tm.t.Logf("Miner %s: WindowPoST(%d): next ProvingEpoch: %d", tm.ActorAddr, sectorNumber, provingEpoch)
return di.CurrentEpoch, provingEpoch, nil
}
func (tm *TestUnmanagedMiner) generatePreCommit(
ctx context.Context,
sectorNumber abi.SectorNumber,
@ -896,6 +887,15 @@ func (tm *TestUnmanagedMiner) generatePreCommit(
proofType abi.RegisteredSealProof,
pieceInfo []abi.PieceInfo,
) {
if tm.mockProofs {
tm.sealedCids[sectorNumber] = cid.MustParse("bagboea4b5abcatlxechwbp7kjpjguna6r6q7ejrhe6mdp3lf34pmswn27pkkiekz")
if len(pieceInfo) > 0 {
tm.unsealedCids[sectorNumber] = cid.MustParse("baga6ea4seaqjtovkwk4myyzj56eztkh5pzsk5upksan6f5outesy62bsvl4dsha")
}
return
}
req := require.New(tm.t)
tm.t.Logf("Miner %s: Generating proof type %d PreCommit for sector %d...", tm.ActorAddr, proofType, sectorNumber)
@ -945,41 +945,48 @@ func (tm *TestUnmanagedMiner) generatePreCommit(
tm.unsealedCids[sectorNumber] = unsealedCid
}
func (tm *TestUnmanagedMiner) proveCommitWaitSeed(ctx context.Context, sectorNumber abi.SectorNumber) abi.InteractiveSealRandomness {
func (tm *TestUnmanagedMiner) proveCommitWaitSeed(ctx context.Context, sectorNumber abi.SectorNumber, proofType abi.RegisteredSealProof) (abi.ChainEpoch, abi.InteractiveSealRandomness) {
req := require.New(tm.t)
head, err := tm.FullNode.ChainHead(ctx)
req.NoError(err)
tm.t.Logf("Miner %s: Fetching pre-commit info for sector %d...", tm.ActorAddr, sectorNumber)
preCommitInfo, err := tm.FullNode.StateSectorPreCommitInfo(ctx, tm.ActorAddr, sectorNumber, head.Key())
req.NoError(err)
seedRandomnessHeight := preCommitInfo.PreCommitEpoch + policy.GetPreCommitChallengeDelay()
var seedRandomnessHeight abi.ChainEpoch
tm.t.Logf("Miner %s: Waiting %d epochs for seed randomness at epoch %d (current epoch %d) for sector %d...", tm.ActorAddr, seedRandomnessHeight-head.Height(), seedRandomnessHeight, head.Height(), sectorNumber)
tm.FullNode.WaitTillChain(ctx, HeightAtLeast(seedRandomnessHeight+5))
if proofType.IsNonInteractive() {
seedRandomnessHeight = head.Height() - 1 // no need to wait, it just can't be current epoch
} else {
tm.t.Logf("Miner %s: Fetching pre-commit info for sector %d...", tm.ActorAddr, sectorNumber)
preCommitInfo, err := tm.FullNode.StateSectorPreCommitInfo(ctx, tm.ActorAddr, sectorNumber, head.Key())
req.NoError(err)
seedRandomnessHeight = preCommitInfo.PreCommitEpoch + policy.GetPreCommitChallengeDelay()
tm.t.Logf("Miner %s: Waiting %d epochs for seed randomness at epoch %d (current epoch %d) for sector %d...", tm.ActorAddr, seedRandomnessHeight-head.Height(), seedRandomnessHeight, head.Height(), sectorNumber)
tm.FullNode.WaitTillChain(ctx, HeightAtLeast(seedRandomnessHeight+5))
head, err = tm.FullNode.ChainHead(ctx)
req.NoError(err)
}
minerAddrBytes := new(bytes.Buffer)
req.NoError(tm.ActorAddr.MarshalCBOR(minerAddrBytes))
head, err = tm.FullNode.ChainHead(ctx)
req.NoError(err)
tm.t.Logf("Miner %s: Fetching seed randomness for sector %d...", tm.ActorAddr, sectorNumber)
rand, err := tm.FullNode.StateGetRandomnessFromBeacon(ctx, crypto.DomainSeparationTag_InteractiveSealChallengeSeed, seedRandomnessHeight, minerAddrBytes.Bytes(), head.Key())
req.NoError(err)
seedRandomness := abi.InteractiveSealRandomness(rand)
tm.t.Logf("Miner %s: Obtained seed randomness for sector %d: %x", tm.ActorAddr, sectorNumber, seedRandomness)
return seedRandomness
return seedRandomnessHeight, seedRandomness
}
func (tm *TestUnmanagedMiner) generateProveCommit(
ctx context.Context,
_ context.Context,
sectorNumber abi.SectorNumber,
proofType abi.RegisteredSealProof,
seedRandomness abi.InteractiveSealRandomness,
pieces []abi.PieceInfo,
) []byte {
tm.t.Logf("Miner %s: Generating proof type %d Sector Proof for sector %d...", tm.ActorAddr, proofType, sectorNumber)
req := require.New(tm.t)
@ -1005,20 +1012,43 @@ func (tm *TestUnmanagedMiner) generateProveCommit(
tm.t.Logf("Miner %s: Running proof type %d SealCommitPhase2 for sector %d...", tm.ActorAddr, proofType, sectorNumber)
sectorProof, err := ffi.SealCommitPhase2(scp1, sectorNumber, actorId)
req.NoError(err)
var sectorProof []byte
if proofType.IsNonInteractive() {
circuitProofs, err := ffi.SealCommitPhase2CircuitProofs(scp1, sectorNumber)
req.NoError(err)
asvpai := proof.AggregateSealVerifyProofAndInfos{
Miner: actorId,
SealProof: proofType,
AggregateProof: abi.RegisteredAggregationProof_SnarkPackV2,
Infos: []proof.AggregateSealVerifyInfo{{
Number: sectorNumber,
Randomness: tm.sealTickets[sectorNumber],
InteractiveRandomness: make([]byte, 32),
SealedCID: tm.sealedCids[sectorNumber],
UnsealedCID: tm.unsealedCids[sectorNumber],
}},
}
tm.t.Logf("Miner %s: Aggregating circuit proofs for sector %d: %+v", tm.ActorAddr, sectorNumber, asvpai)
sectorProof, err = ffi.AggregateSealProofs(asvpai, [][]byte{circuitProofs})
req.NoError(err)
} else {
sectorProof, err = ffi.SealCommitPhase2(scp1, sectorNumber, actorId)
req.NoError(err)
}
tm.t.Logf("Miner %s: Got proof type %d sector proof of length %d for sector %d", tm.ActorAddr, proofType, len(sectorProof), sectorNumber)
return sectorProof
}
func (tm *TestUnmanagedMiner) submitMessage(
func (tm *TestUnmanagedMiner) SubmitMessage(
ctx context.Context,
params cbg.CBORMarshaler,
value uint64,
method abi.MethodNum,
) (*api.MsgLookup, error) {
enc, aerr := actors.SerializeParams(params)
if aerr != nil {
return nil, aerr
@ -1070,3 +1100,54 @@ func requireTempFile(t *testing.T, fileContentsReader io.Reader, size uint64) *o
return tempFile
}
func (tm *TestUnmanagedMiner) WaitTillActivatedAndAssertPower(
ctx context.Context,
respCh chan WindowPostResp,
sector abi.SectorNumber,
) {
// wait till sector is activated
select {
case resp := <-respCh:
require.NoError(tm.t, resp.Error)
require.True(tm.t, resp.Posted)
case <-ctx.Done():
tm.t.Fatal("timed out waiting for sector activation")
}
// Fetch on-chain sector properties
head, err := tm.FullNode.ChainHead(ctx)
require.NoError(tm.t, err)
soi, err := tm.FullNode.StateSectorGetInfo(ctx, tm.ActorAddr, sector, head.Key())
require.NoError(tm.t, err)
tm.t.Logf("Miner %s SectorOnChainInfo %d: %+v", tm.ActorAddr.String(), sector, soi)
_ = tm.FullNode.WaitTillChain(ctx, HeightAtLeast(head.Height()+5))
tm.t.Log("Checking power after PoSt ...")
// Miner B should now have power
tm.AssertPower(ctx, uint64(tm.options.sectorSize), uint64(tm.options.sectorSize))
if !tm.mockProofs {
// WindowPost Dispute should fail
tm.AssertDisputeFails(ctx, sector)
} // else it would pass, which we don't want
}
func (tm *TestUnmanagedMiner) AssertDisputeFails(ctx context.Context, sector abi.SectorNumber) {
err := tm.SubmitPostDispute(ctx, sector)
require.Error(tm.t, err)
require.Contains(tm.t, err.Error(), "failed to dispute valid post")
require.Contains(tm.t, err.Error(), "(RetCode=16)")
}
func (tm *TestUnmanagedMiner) IsImmutableDeadline(ctx context.Context, deadlineIndex uint64) bool {
di, err := tm.FullNode.StateMinerProvingDeadline(ctx, tm.ActorAddr, types.EmptyTSK)
require.NoError(tm.t, err)
// don't rely on di.Index because if we haven't enrolled in cron it won't be ticking
currentDeadlineIdx := uint64(math.Abs(float64((di.CurrentEpoch - di.PeriodStart) / di.WPoStChallengeWindow)))
return currentDeadlineIdx == deadlineIndex || currentDeadlineIdx == deadlineIndex-1
}

View File

@ -9,6 +9,12 @@ import (
// and set to value "1" to enable running expensive tests outside of CI.
const EnvRunExpensiveTests = "LOTUS_RUN_EXPENSIVE_TESTS"
// EnvRunVeryExpensiveTests is the environment variable that needs to be present
// and set to value "1" to enable running very expensive tests outside of CI.
// A "very expensive" test is one that is expected to take too long to run in
// a standard CI setup, and should be skipped unless explicitly enabled.
const EnvRunVeryExpensiveTests = "LOTUS_RUN_VERY_EXPENSIVE_TESTS"
// Expensive marks a test as expensive, skipping it immediately if not running an
func Expensive(t *testing.T) {
switch {
@ -18,3 +24,10 @@ func Expensive(t *testing.T) {
t.Skipf("skipping expensive test outside of CI; enable by setting env var %s=1", EnvRunExpensiveTests)
}
}
// Expensive marks a test as expensive, skipping it immediately if not running an
func VeryExpensive(t *testing.T) {
if os.Getenv(EnvRunVeryExpensiveTests) != "1" {
t.Skipf("skipping VERY expensive test outside of CI; enable by setting env var %s=1", EnvRunVeryExpensiveTests)
}
}

View File

@ -8,24 +8,28 @@ import (
"github.com/stretchr/testify/require"
"github.com/filecoin-project/go-state-types/abi"
"github.com/filecoin-project/go-state-types/network"
"github.com/filecoin-project/lotus/build"
"github.com/filecoin-project/lotus/chain/actors/builtin/miner"
"github.com/filecoin-project/lotus/itests/kit"
)
const defaultSectorSize = abi.SectorSize(2 << 10) // 2KiB
// Manually onboard CC sectors, bypassing lotus-miner onboarding pathways
func TestManualSectorOnboarding(t *testing.T) {
req := require.New(t)
const defaultSectorSize = abi.SectorSize(2 << 10) // 2KiB
sealProofType, err := miner.SealProofTypeFromSectorSize(defaultSectorSize, network.Version23, miner.SealProofVariant_Standard)
req.NoError(err)
for _, withMockProofs := range []bool{true, false} {
testName := "WithRealProofs"
if withMockProofs {
testName = "WithMockProofs"
}
t.Run(testName, func(t *testing.T) {
if testName == "WithRealProofs" {
if !withMockProofs {
kit.Expensive(t)
}
kit.QuietMiningLogs()
@ -41,11 +45,7 @@ func TestManualSectorOnboarding(t *testing.T) {
// Setup and begin mining with a single miner (A)
// Miner A will only be a genesis Miner with power allocated in the genesis block and will not onboard any sectors from here on
kitOpts := []kit.EnsembleOpt{}
if withMockProofs {
kitOpts = append(kitOpts, kit.MockProofs())
}
ens := kit.NewEnsemble(t, kitOpts...).
ens := kit.NewEnsemble(t, kit.MockProofs(withMockProofs)).
FullNode(&client, kit.SectorSize(defaultSectorSize)).
// preseal more than the default number of sectors to ensure that the genesis miner has power
// because our unmanaged miners won't produce blocks so we may get null rounds
@ -89,11 +89,7 @@ func TestManualSectorOnboarding(t *testing.T) {
var bRespCh chan kit.WindowPostResp
var bWdPostCancelF context.CancelFunc
if withMockProofs {
bSectorNum, bRespCh, bWdPostCancelF = minerB.OnboardCCSectorWithMockProofs(ctx, kit.TestSpt)
} else {
bSectorNum, bRespCh, bWdPostCancelF = minerB.OnboardCCSectorWithRealProofs(ctx, kit.TestSpt)
}
bSectorNum, bRespCh, bWdPostCancelF = minerB.OnboardCCSector(ctx, sealProofType)
// Miner B should still not have power as power can only be gained after sector is activated i.e. the first WindowPost is submitted for it
minerB.AssertNoPower(ctx)
// Ensure that the block miner checks for and waits for posts during the appropriate proving window from our new miner with a sector
@ -103,72 +99,20 @@ func TestManualSectorOnboarding(t *testing.T) {
var cSectorNum abi.SectorNumber
var cRespCh chan kit.WindowPostResp
if withMockProofs {
cSectorNum, cRespCh, _ = minerC.OnboardSectorWithPiecesAndMockProofs(ctx, kit.TestSpt)
} else {
cSectorNum, cRespCh, _ = minerC.OnboardSectorWithPiecesAndRealProofs(ctx, kit.TestSpt)
}
cSectorNum, cRespCh, _ = minerC.OnboardSectorWithPieces(ctx, kit.TestSpt)
// Miner C should still not have power as power can only be gained after sector is activated i.e. the first WindowPost is submitted for it
minerC.AssertNoPower(ctx)
// Ensure that the block miner checks for and waits for posts during the appropriate proving window from our new miner with a sector
blockMiner.WatchMinerForPost(minerC.ActorAddr)
// Wait till both miners' sectors have had their first post and are activated and check that this is reflected in miner power
waitTillActivatedAndAssertPower(ctx, t, minerB, bRespCh, bSectorNum, uint64(defaultSectorSize), withMockProofs)
waitTillActivatedAndAssertPower(ctx, t, minerC, cRespCh, cSectorNum, uint64(defaultSectorSize), withMockProofs)
minerB.WaitTillActivatedAndAssertPower(ctx, bRespCh, bSectorNum)
minerC.WaitTillActivatedAndAssertPower(ctx, cRespCh, cSectorNum)
// Miner B has activated the CC sector -> upgrade it with snapdeals
// Note: We can't activate a sector with mock proofs as the WdPost is successfully disputed and so no point
// in snapping it as snapping is only for activated sectors
if !withMockProofs {
minerB.SnapDealWithRealProofs(ctx, kit.TestSpt, bSectorNum)
// cancel the WdPost for the CC sector as the corresponding CommR is no longer valid
bWdPostCancelF()
}
_ = minerB.SnapDeal(ctx, kit.TestSpt, bSectorNum)
// cancel the WdPost for the CC sector as the corresponding CommR is no longer valid
bWdPostCancelF()
})
}
}
func waitTillActivatedAndAssertPower(ctx context.Context, t *testing.T, miner *kit.TestUnmanagedMiner, respCh chan kit.WindowPostResp, sector abi.SectorNumber,
sectorSize uint64, withMockProofs bool) {
req := require.New(t)
// wait till sector is activated
select {
case resp := <-respCh:
req.NoError(resp.Error)
req.True(resp.Posted)
case <-ctx.Done():
t.Fatal("timed out waiting for sector activation")
}
// Fetch on-chain sector properties
head, err := miner.FullNode.ChainHead(ctx)
req.NoError(err)
soi, err := miner.FullNode.StateSectorGetInfo(ctx, miner.ActorAddr, sector, head.Key())
req.NoError(err)
t.Logf("Miner %s SectorOnChainInfo %d: %+v", miner.ActorAddr.String(), sector, soi)
_ = miner.FullNode.WaitTillChain(ctx, kit.HeightAtLeast(head.Height()+5))
t.Log("Checking power after PoSt ...")
// Miner B should now have power
miner.AssertPower(ctx, sectorSize, sectorSize)
if withMockProofs {
// WindowPost Dispute should succeed as we are using mock proofs
err := miner.SubmitPostDispute(ctx, sector)
require.NoError(t, err)
} else {
// WindowPost Dispute should fail
assertDisputeFails(ctx, t, miner, sector)
}
}
func assertDisputeFails(ctx context.Context, t *testing.T, miner *kit.TestUnmanagedMiner, sector abi.SectorNumber) {
err := miner.SubmitPostDispute(ctx, sector)
require.Error(t, err)
require.Contains(t, err.Error(), "failed to dispute valid post")
require.Contains(t, err.Error(), "(RetCode=16)")
}

View File

@ -7,6 +7,7 @@ import (
"testing"
"time"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"github.com/filecoin-project/go-address"
@ -17,6 +18,7 @@ import (
miner11 "github.com/filecoin-project/go-state-types/builtin/v11/miner"
power11 "github.com/filecoin-project/go-state-types/builtin/v11/power"
adt11 "github.com/filecoin-project/go-state-types/builtin/v11/util/adt"
account "github.com/filecoin-project/go-state-types/builtin/v14/account"
markettypes "github.com/filecoin-project/go-state-types/builtin/v9/market"
migration "github.com/filecoin-project/go-state-types/builtin/v9/migration/test"
miner9 "github.com/filecoin-project/go-state-types/builtin/v9/miner"
@ -302,7 +304,7 @@ func TestMigrationNV17(t *testing.T) {
minerInfo, err := testClient.StateMinerInfo(ctx, testMiner.ActorAddr, types.EmptyTSK)
require.NoError(t, err)
spt, err := miner.SealProofTypeFromSectorSize(minerInfo.SectorSize, network.Version17, false)
spt, err := miner.SealProofTypeFromSectorSize(minerInfo.SectorSize, network.Version17, miner.SealProofVariant_Standard)
require.NoError(t, err)
preCommitParams := miner9.PreCommitSectorParams{
@ -594,7 +596,7 @@ func TestMigrationNV18(t *testing.T) {
// check all actor's Address fields
require.NoError(t, newStateTree.ForEach(func(address address.Address, actor *types.Actor) error {
if address != ethZeroAddrID {
require.Nil(t, actor.Address)
require.Nil(t, actor.DelegatedAddress)
}
return nil
}))
@ -828,3 +830,70 @@ func TestMigrationNV21(t *testing.T) {
//todo @zen Direct data onboarding tests
}
func TestMigrationNV23(t *testing.T) {
kit.QuietMiningLogs()
f090Addr, err := address.NewIDAddress(90)
require.NoError(t, err)
nv23epoch := abi.ChainEpoch(100)
testClient, _, ens := kit.EnsembleMinimal(t, kit.MockProofs(),
kit.UpgradeSchedule(stmgr.Upgrade{
Network: network.Version22,
Height: -1,
}, stmgr.Upgrade{
Network: network.Version23,
Height: nv23epoch,
Migration: filcns.UpgradeActorsV14,
},
))
ens.InterconnectAll().BeginMining(10 * time.Millisecond)
clientApi := testClient.FullNode.(*impl.FullNodeAPI)
ctx, cancel := context.WithCancel(context.Background())
defer cancel()
testClient.WaitTillChain(ctx, kit.HeightAtLeast(nv23epoch+5))
bs := blockstore.NewAPIBlockstore(testClient)
ctxStore := gstStore.WrapBlockStore(ctx, bs)
preMigrationTs, err := clientApi.ChainGetTipSetByHeight(ctx, nv23epoch-1, types.EmptyTSK)
require.NoError(t, err)
root := preMigrationTs.Blocks()[0].ParentStateRoot
preStateTree, err := state.LoadStateTree(ctxStore, root)
require.NoError(t, err)
require.Equal(t, types.StateTreeVersion5, preStateTree.Version())
// Check f090 actor before migration
msigCodeNv22, ok := actors.GetActorCodeID(actorstypes.Version13, manifest.MultisigKey)
assert.True(t, ok)
f090ActorPre, err := preStateTree.GetActor(f090Addr)
require.NoError(t, err)
require.True(t, f090ActorPre.Code.Equals(msigCodeNv22))
// Get state after the migration
postMigrationTs, err := clientApi.ChainHead(ctx)
require.NoError(t, err)
postStateTree, err := state.LoadStateTree(ctxStore, postMigrationTs.Blocks()[0].ParentStateRoot)
require.NoError(t, err)
// Check the new system actor
systemAct, err := postStateTree.GetActor(builtin.SystemActorAddr)
require.NoError(t, err)
systemCode, ok := actors.GetActorCodeID(actorstypes.Version14, manifest.SystemKey)
require.True(t, ok)
require.Equal(t, systemCode, systemAct.Code)
// Check f090 actor after migration
f090ActorPost, err := postStateTree.GetActor(f090Addr)
require.NoError(t, err)
accountNV23, ok := actors.GetActorCodeID(actorstypes.Version14, manifest.AccountKey)
assert.True(t, ok)
require.True(t, f090ActorPost.Code.Equals(accountNV23))
f090StatePost, err := clientApi.StateReadState(ctx, f090Addr, types.EmptyTSK)
require.NoError(t, err)
state := f090StatePost.State.(*account.State)
require.Equal(t, state.Address, f090Addr)
}

View File

@ -0,0 +1,260 @@
package itests
import (
"context"
"fmt"
"math"
"testing"
"time"
"github.com/ipfs/go-cid"
"github.com/ipld/go-ipld-prime"
"github.com/ipld/go-ipld-prime/codec/dagcbor"
"github.com/ipld/go-ipld-prime/datamodel"
cidlink "github.com/ipld/go-ipld-prime/linking/cid"
"github.com/ipld/go-ipld-prime/node/basicnode"
"github.com/multiformats/go-multicodec"
"github.com/stretchr/testify/require"
"github.com/filecoin-project/go-address"
"github.com/filecoin-project/go-state-types/abi"
"github.com/filecoin-project/go-state-types/builtin"
miner14 "github.com/filecoin-project/go-state-types/builtin/v14/miner"
"github.com/filecoin-project/go-state-types/network"
"github.com/filecoin-project/lotus/build"
"github.com/filecoin-project/lotus/chain/actors/builtin/miner"
"github.com/filecoin-project/lotus/chain/types"
"github.com/filecoin-project/lotus/itests/kit"
"github.com/filecoin-project/lotus/lib/must"
)
func TestManualNISectorOnboarding(t *testing.T) {
req := require.New(t)
const defaultSectorSize = abi.SectorSize(2 << 10) // 2KiB
sealProofType, err := miner.SealProofTypeFromSectorSize(defaultSectorSize, network.Version23, miner.SealProofVariant_NonInteractive)
req.NoError(err)
for _, withMockProofs := range []bool{true, false} {
testName := "WithRealProofs"
if withMockProofs {
testName = "WithMockProofs"
}
t.Run(testName, func(t *testing.T) {
if !withMockProofs {
kit.VeryExpensive(t)
}
kit.QuietMiningLogs()
ctx, cancel := context.WithCancel(context.Background())
defer cancel()
var (
// need to pick a balance value so that the test is not racy on CI by running through it's WindowPostDeadlines too fast
blocktime = 2 * time.Millisecond
client kit.TestFullNode
minerA kit.TestMiner // A is a standard genesis miner
)
// Setup and begin mining with a single miner (A)
// Miner A will only be a genesis Miner with power allocated in the genesis block and will not onboard any sectors from here on
ens := kit.NewEnsemble(t, kit.MockProofs(withMockProofs)).
FullNode(&client, kit.SectorSize(defaultSectorSize)).
// preseal more than the default number of sectors to ensure that the genesis miner has power
// because our unmanaged miners won't produce blocks so we may get null rounds
Miner(&minerA, &client, kit.PresealSectors(5), kit.SectorSize(defaultSectorSize), kit.WithAllSubsystems()).
Start().
InterconnectAll()
blockMiners := ens.BeginMiningMustPost(blocktime)
req.Len(blockMiners, 1)
blockMiner := blockMiners[0]
// Instantiate MinerB to manually handle sector onboarding and power acquisition through sector activation.
// Unlike other miners managed by the Lotus Miner storage infrastructure, MinerB operates independently,
// performing all related tasks manually. Managed by the TestKit, MinerB has the capability to utilize actual proofs
// for the processes of sector onboarding and activation.
nodeOpts := []kit.NodeOpt{kit.SectorSize(defaultSectorSize), kit.OwnerAddr(client.DefaultKey)}
minerB, ens := ens.UnmanagedMiner(&client, nodeOpts...)
ens.Start()
build.Clock.Sleep(time.Second)
t.Log("Checking initial power ...")
// Miner A should have power as it has already onboarded sectors in the genesis block
head, err := client.ChainHead(ctx)
req.NoError(err)
p, err := client.StateMinerPower(ctx, minerA.ActorAddr, head.Key())
req.NoError(err)
t.Logf("MinerA RBP: %v, QaP: %v", p.MinerPower.QualityAdjPower.String(), p.MinerPower.RawBytePower.String())
// Miner B should have no power as it has yet to onboard and activate any sectors
minerB.AssertNoPower(ctx)
// Verify that ProveCommitSectorsNI rejects messages with invalid parameters
verifyProveCommitSectorsNIErrorConditions(ctx, t, minerB, sealProofType)
// ---- Miner B onboards a CC sector
var bSectorNum abi.SectorNumber
var bRespCh chan kit.WindowPostResp
var bWdPostCancelF context.CancelFunc
// Onboard a CC sector with Miner B using NI-PoRep
bSectorNum, bRespCh, bWdPostCancelF = minerB.OnboardCCSector(ctx, sealProofType)
// Miner B should still not have power as power can only be gained after sector is activated i.e. the first WindowPost is submitted for it
minerB.AssertNoPower(ctx)
// Check that the sector-activated event was emitted
{
expectedEntries := []types.EventEntry{
{Flags: 0x03, Codec: uint64(multicodec.Cbor), Key: "$type", Value: must.One(ipld.Encode(basicnode.NewString("sector-activated"), dagcbor.Encode))},
{Flags: 0x03, Codec: uint64(multicodec.Cbor), Key: "sector", Value: must.One(ipld.Encode(basicnode.NewInt(int64(bSectorNum)), dagcbor.Encode))},
{Flags: 0x03, Codec: uint64(multicodec.Cbor), Key: "unsealed-cid", Value: must.One(ipld.Encode(datamodel.Null, dagcbor.Encode))},
}
from := head.Height()
recentEvents, err := client.FullNode.GetActorEventsRaw(ctx, &types.ActorEventFilter{FromHeight: &from})
req.NoError(err)
req.Len(recentEvents, 1)
req.Equal(expectedEntries, recentEvents[0].Entries)
}
// Ensure that the block miner checks for and waits for posts during the appropriate proving window from our new miner with a sector
blockMiner.WatchMinerForPost(minerB.ActorAddr)
// Wait till both miners' sectors have had their first post and are activated and check that this is reflected in miner power
minerB.WaitTillActivatedAndAssertPower(ctx, bRespCh, bSectorNum)
head, err = client.ChainHead(ctx)
req.NoError(err)
// Miner B has activated the CC sector -> upgrade it with snapdeals
snapPieces := minerB.SnapDeal(ctx, kit.TestSpt, bSectorNum)
// cancel the WdPost for the CC sector as the corresponding CommR is no longer valid
bWdPostCancelF()
// Check "sector-updated" event happned after snap
{
expectedEntries := []types.EventEntry{
{Flags: 0x03, Codec: uint64(multicodec.Cbor), Key: "$type", Value: must.One(ipld.Encode(basicnode.NewString("sector-updated"), dagcbor.Encode))},
{Flags: 0x03, Codec: uint64(multicodec.Cbor), Key: "sector", Value: must.One(ipld.Encode(basicnode.NewInt(int64(bSectorNum)), dagcbor.Encode))},
{Flags: 0x03, Codec: uint64(multicodec.Cbor), Key: "unsealed-cid", Value: must.One(ipld.Encode(basicnode.NewLink(cidlink.Link{Cid: snapPieces[0].PieceCID}), dagcbor.Encode))},
{Flags: 0x03, Codec: uint64(multicodec.Cbor), Key: "piece-cid", Value: must.One(ipld.Encode(basicnode.NewLink(cidlink.Link{Cid: snapPieces[0].PieceCID}), dagcbor.Encode))},
{Flags: 0x01, Codec: uint64(multicodec.Cbor), Key: "piece-size", Value: must.One(ipld.Encode(basicnode.NewInt(int64(snapPieces[0].Size)), dagcbor.Encode))},
}
from := head.Height()
recentEvents, err := client.FullNode.GetActorEventsRaw(ctx, &types.ActorEventFilter{FromHeight: &from})
req.NoError(err)
req.Len(recentEvents, 1)
req.Equal(expectedEntries, recentEvents[0].Entries)
}
})
}
}
func verifyProveCommitSectorsNIErrorConditions(ctx context.Context, t *testing.T, miner *kit.TestUnmanagedMiner, sealProofType abi.RegisteredSealProof) {
req := require.New(t)
head, err := miner.FullNode.ChainHead(ctx)
req.NoError(err)
actorIdNum, err := address.IDFromAddress(miner.ActorAddr)
req.NoError(err)
actorId := abi.ActorID(actorIdNum)
var provingDeadline uint64 = 7
if miner.IsImmutableDeadline(ctx, provingDeadline) {
// avoid immutable deadlines
provingDeadline = 5
}
submitAndFail := func(params *miner14.ProveCommitSectorsNIParams, errMsg string, errCode int) {
t.Helper()
r, err := miner.SubmitMessage(ctx, params, 1, builtin.MethodsMiner.ProveCommitSectorsNI)
req.Error(err)
req.Contains(err.Error(), errMsg)
if errCode > 0 {
req.Contains(err.Error(), fmt.Sprintf("(RetCode=%d)", errCode))
}
req.Nil(r)
}
sn := abi.SectorNumber(5000)
mkSai := func() miner14.SectorNIActivationInfo {
sn++
return miner14.SectorNIActivationInfo{
SealingNumber: sn,
SealerID: actorId,
SealedCID: cid.MustParse("bagboea4b5abcatlxechwbp7kjpjguna6r6q7ejrhe6mdp3lf34pmswn27pkkiekz"),
SectorNumber: sn,
SealRandEpoch: head.Height() - 10,
Expiration: 2880 * 300,
}
}
mkParams := func() miner14.ProveCommitSectorsNIParams {
return miner14.ProveCommitSectorsNIParams{
Sectors: []miner14.SectorNIActivationInfo{mkSai(), mkSai()},
AggregateProof: []byte{0xca, 0xfe, 0xbe, 0xef},
SealProofType: sealProofType,
AggregateProofType: abi.RegisteredAggregationProof_SnarkPackV2,
ProvingDeadline: provingDeadline,
RequireActivationSuccess: true,
}
}
// Test message rejection on no sectors
params := mkParams()
params.Sectors = []miner14.SectorNIActivationInfo{}
submitAndFail(&params, "too few sectors", 16)
// Test message rejection on too many sectors
sectorInfos := make([]miner14.SectorNIActivationInfo, 66)
for i := range sectorInfos {
sectorInfos[i] = mkSai()
}
params = mkParams()
params.Sectors = sectorInfos
submitAndFail(&params, "too many sectors", 16)
// Test bad aggregation proof type
params = mkParams()
params.AggregateProofType = abi.RegisteredAggregationProof_SnarkPackV1
submitAndFail(&params, "aggregate proof type", 16)
// Test bad SealerID
params = mkParams()
params.Sectors[1].SealerID = 1234
submitAndFail(&params, "invalid NI commit 1 while requiring activation success", 16)
// Test bad SealingNumber
params = mkParams()
params.Sectors[1].SealingNumber = 1234
submitAndFail(&params, "invalid NI commit 1 while requiring activation success", 16)
// Test bad SealedCID
params = mkParams()
params.Sectors[1].SealedCID = cid.MustParse("baga6ea4seaqjtovkwk4myyzj56eztkh5pzsk5upksan6f5outesy62bsvl4dsha")
submitAndFail(&params, "invalid NI commit 1 while requiring activation success", 16)
// Test bad SealRandEpoch
head, err = miner.FullNode.ChainHead(ctx)
req.NoError(err)
params = mkParams()
params.Sectors[1].SealRandEpoch = head.Height() + builtin.EpochsInDay
submitAndFail(&params, fmt.Sprintf("seal challenge epoch %d must be before now", params.Sectors[1].SealRandEpoch), 16)
params.Sectors[1].SealRandEpoch = head.Height() - 190*builtin.EpochsInDay
submitAndFail(&params, "invalid NI commit 1 while requiring activation success", 16)
// Immutable/bad deadlines
di, err := miner.FullNode.StateMinerProvingDeadline(ctx, miner.ActorAddr, head.Key())
req.NoError(err)
currentDeadlineIdx := uint64(math.Abs(float64((di.CurrentEpoch - di.PeriodStart) / di.WPoStChallengeWindow)))
req.Less(currentDeadlineIdx, di.WPoStPeriodDeadlines)
params = mkParams()
params.ProvingDeadline = currentDeadlineIdx
submitAndFail(&params, fmt.Sprintf("proving deadline %d must not be the current or next deadline", currentDeadlineIdx), 18)
params.ProvingDeadline = currentDeadlineIdx + 1
submitAndFail(&params, fmt.Sprintf("proving deadline %d must not be the current or next deadline", currentDeadlineIdx+1), 18)
params.ProvingDeadline = di.WPoStPeriodDeadlines // too big
submitAndFail(&params, fmt.Sprintf("proving deadline index %d invalid", di.WPoStPeriodDeadlines), 16)
}

View File

@ -114,6 +114,7 @@ const (
HandleDealsKey
HandleRetrievalKey
RunSectorServiceKey
F3Participation
// daemon
ExtractApiKey

View File

@ -17,6 +17,7 @@ import (
"github.com/filecoin-project/lotus/chain/exchange"
"github.com/filecoin-project/lotus/chain/gen/slashfilter"
"github.com/filecoin-project/lotus/chain/index"
"github.com/filecoin-project/lotus/chain/lf3"
"github.com/filecoin-project/lotus/chain/market"
"github.com/filecoin-project/lotus/chain/messagepool"
"github.com/filecoin-project/lotus/chain/messagesigner"
@ -149,6 +150,8 @@ var ChainNode = Options(
Override(HandleIncomingMessagesKey, modules.HandleIncomingMessages),
Override(HandleIncomingBlocksKey, modules.HandleIncomingBlocks),
),
If(build.F3Enabled, Override(new(*lf3.F3), lf3.New)),
)
func ConfigFullNode(c interface{}) Option {

View File

@ -141,6 +141,7 @@ func ConfigStorageMiner(c interface{}) Option {
Override(new(config.HarmonyDB), cfg.HarmonyDB),
Override(new(harmonydb.ITestID), harmonydb.ITestID("")),
Override(new(*ctladdr.AddressSelector), modules.AddressSelector(&cfg.Addresses)),
If(build.F3Enabled, Override(F3Participation, modules.F3Participation)),
)
}

View File

@ -117,509 +117,6 @@ your node if metadata log is disabled`,
Comment: ``,
},
},
"CurioAddresses": {
{
Name: "PreCommitControl",
Type: "[]string",
Comment: `Addresses to send PreCommit messages from`,
},
{
Name: "CommitControl",
Type: "[]string",
Comment: `Addresses to send Commit messages from`,
},
{
Name: "TerminateControl",
Type: "[]string",
Comment: ``,
},
{
Name: "DisableOwnerFallback",
Type: "bool",
Comment: `DisableOwnerFallback disables usage of the owner address for messages
sent automatically`,
},
{
Name: "DisableWorkerFallback",
Type: "bool",
Comment: `DisableWorkerFallback disables usage of the worker address for messages
sent automatically, if control addresses are configured.
A control address that doesn't have enough funds will still be chosen
over the worker address if this flag is set.`,
},
{
Name: "MinerAddresses",
Type: "[]string",
Comment: `MinerAddresses are the addresses of the miner actors to use for sending messages`,
},
},
"CurioAlerting": {
{
Name: "PagerDutyEventURL",
Type: "string",
Comment: `PagerDutyEventURL is URL for PagerDuty.com Events API v2 URL. Events sent to this API URL are ultimately
routed to a PagerDuty.com service and processed.
The default is sufficient for integration with the stock commercial PagerDuty.com company's service.`,
},
{
Name: "PageDutyIntegrationKey",
Type: "string",
Comment: `PageDutyIntegrationKey is the integration key for a PagerDuty.com service. You can find this unique service
identifier in the integration page for the service.`,
},
{
Name: "MinimumWalletBalance",
Type: "types.FIL",
Comment: `MinimumWalletBalance is the minimum balance all active wallets. If the balance is below this value, an
alerts will be triggered for the wallet`,
},
},
"CurioConfig": {
{
Name: "Subsystems",
Type: "CurioSubsystemsConfig",
Comment: ``,
},
{
Name: "Fees",
Type: "CurioFees",
Comment: ``,
},
{
Name: "Addresses",
Type: "[]CurioAddresses",
Comment: `Addresses of wallets per MinerAddress (one of the fields).`,
},
{
Name: "Proving",
Type: "CurioProvingConfig",
Comment: ``,
},
{
Name: "Ingest",
Type: "CurioIngestConfig",
Comment: ``,
},
{
Name: "Journal",
Type: "JournalConfig",
Comment: ``,
},
{
Name: "Apis",
Type: "ApisConfig",
Comment: ``,
},
{
Name: "Alerting",
Type: "CurioAlerting",
Comment: ``,
},
},
"CurioFees": {
{
Name: "DefaultMaxFee",
Type: "types.FIL",
Comment: ``,
},
{
Name: "MaxPreCommitGasFee",
Type: "types.FIL",
Comment: ``,
},
{
Name: "MaxCommitGasFee",
Type: "types.FIL",
Comment: ``,
},
{
Name: "MaxPreCommitBatchGasFee",
Type: "BatchFeeConfig",
Comment: `maxBatchFee = maxBase + maxPerSector * nSectors`,
},
{
Name: "MaxCommitBatchGasFee",
Type: "BatchFeeConfig",
Comment: ``,
},
{
Name: "MaxTerminateGasFee",
Type: "types.FIL",
Comment: ``,
},
{
Name: "MaxWindowPoStGasFee",
Type: "types.FIL",
Comment: `WindowPoSt is a high-value operation, so the default fee should be high.`,
},
{
Name: "MaxPublishDealsFee",
Type: "types.FIL",
Comment: ``,
},
},
"CurioIngestConfig": {
{
Name: "MaxQueueSDR",
Type: "int",
Comment: `Maximum number of sectors that can be queued waiting for SDR to start processing.
0 = unlimited
Note: This mechanism will delay taking deal data from markets, providing backpressure to the market subsystem.
The SDR queue includes deals which are in the process of entering the sealing pipeline - size of this queue
will also impact the maximum number of ParkPiece tasks which can run concurrently.
SDR queue is the first queue in the sealing pipeline, meaning that it should be used as the primary backpressure mechanism.`,
},
{
Name: "MaxQueueTrees",
Type: "int",
Comment: `Maximum number of sectors that can be queued waiting for SDRTrees to start processing.
0 = unlimited
Note: This mechanism will delay taking deal data from markets, providing backpressure to the market subsystem.
In case of the trees tasks it is possible that this queue grows more than this limit, the backpressure is only
applied to sectors entering the pipeline.`,
},
{
Name: "MaxQueuePoRep",
Type: "int",
Comment: `Maximum number of sectors that can be queued waiting for PoRep to start processing.
0 = unlimited
Note: This mechanism will delay taking deal data from markets, providing backpressure to the market subsystem.
Like with the trees tasks, it is possible that this queue grows more than this limit, the backpressure is only
applied to sectors entering the pipeline.`,
},
},
"CurioProvingConfig": {
{
Name: "ParallelCheckLimit",
Type: "int",
Comment: `Maximum number of sector checks to run in parallel. (0 = unlimited)
WARNING: Setting this value too high may make the node crash by running out of stack
WARNING: Setting this value too low may make sector challenge reading much slower, resulting in failed PoSt due
to late submission.
After changing this option, confirm that the new value works in your setup by invoking
'lotus-miner proving compute window-post 0'`,
},
{
Name: "SingleCheckTimeout",
Type: "Duration",
Comment: `Maximum amount of time a proving pre-check can take for a sector. If the check times out the sector will be skipped
WARNING: Setting this value too low risks in sectors being skipped even though they are accessible, just reading the
test challenge took longer than this timeout
WARNING: Setting this value too high risks missing PoSt deadline in case IO operations related to this sector are
blocked (e.g. in case of disconnected NFS mount)`,
},
{
Name: "PartitionCheckTimeout",
Type: "Duration",
Comment: `Maximum amount of time a proving pre-check can take for an entire partition. If the check times out, sectors in
the partition which didn't get checked on time will be skipped
WARNING: Setting this value too low risks in sectors being skipped even though they are accessible, just reading the
test challenge took longer than this timeout
WARNING: Setting this value too high risks missing PoSt deadline in case IO operations related to this partition are
blocked or slow`,
},
{
Name: "DisableWDPoStPreChecks",
Type: "bool",
Comment: `Disable WindowPoSt provable sector readability checks.
In normal operation, when preparing to compute WindowPoSt, lotus-miner will perform a round of reading challenges
from all sectors to confirm that those sectors can be proven. Challenges read in this process are discarded, as
we're only interested in checking that sector data can be read.
When using builtin proof computation (no PoSt workers, and DisableBuiltinWindowPoSt is set to false), this process
can save a lot of time and compute resources in the case that some sectors are not readable - this is caused by
the builtin logic not skipping snark computation when some sectors need to be skipped.
When using PoSt workers, this process is mostly redundant, with PoSt workers challenges will be read once, and
if challenges for some sectors aren't readable, those sectors will just get skipped.
Disabling sector pre-checks will slightly reduce IO load when proving sectors, possibly resulting in shorter
time to produce window PoSt. In setups with good IO capabilities the effect of this option on proving time should
be negligible.
NOTE: It likely is a bad idea to disable sector pre-checks in setups with no PoSt workers.
NOTE: Even when this option is enabled, recovering sectors will be checked before recovery declaration message is
sent to the chain
After changing this option, confirm that the new value works in your setup by invoking
'lotus-miner proving compute window-post 0'`,
},
{
Name: "MaxPartitionsPerPoStMessage",
Type: "int",
Comment: `Maximum number of partitions to prove in a single SubmitWindowPoSt messace. 0 = network limit (3 in nv21)
A single partition may contain up to 2349 32GiB sectors, or 2300 64GiB sectors.
//
Note that setting this value lower may result in less efficient gas use - more messages will be sent,
to prove each deadline, resulting in more total gas use (but each message will have lower gas limit)
Setting this value above the network limit has no effect`,
},
{
Name: "MaxPartitionsPerRecoveryMessage",
Type: "int",
Comment: `In some cases when submitting DeclareFaultsRecovered messages,
there may be too many recoveries to fit in a BlockGasLimit.
In those cases it may be necessary to set this value to something low (eg 1);
Note that setting this value lower may result in less efficient gas use - more messages will be sent than needed,
resulting in more total gas use (but each message will have lower gas limit)`,
},
{
Name: "SingleRecoveringPartitionPerPostMessage",
Type: "bool",
Comment: `Enable single partition per PoSt Message for partitions containing recovery sectors
In cases when submitting PoSt messages which contain recovering sectors, the default network limit may still be
too high to fit in the block gas limit. In those cases, it becomes useful to only house the single partition
with recovering sectors in the post message
Note that setting this value lower may result in less efficient gas use - more messages will be sent,
to prove each deadline, resulting in more total gas use (but each message will have lower gas limit)`,
},
},
"CurioSubsystemsConfig": {
{
Name: "EnableWindowPost",
Type: "bool",
Comment: `EnableWindowPost enables window post to be executed on this curio instance. Each machine in the cluster
with WindowPoSt enabled will also participate in the window post scheduler. It is possible to have multiple
machines with WindowPoSt enabled which will provide redundancy, and in case of multiple partitions per deadline,
will allow for parallel processing of partitions.
It is possible to have instances handling both WindowPoSt and WinningPoSt, which can provide redundancy without
the need for additional machines. In setups like this it is generally recommended to run
partitionsPerDeadline+1 machines.`,
},
{
Name: "WindowPostMaxTasks",
Type: "int",
Comment: ``,
},
{
Name: "EnableWinningPost",
Type: "bool",
Comment: `EnableWinningPost enables winning post to be executed on this curio instance.
Each machine in the cluster with WinningPoSt enabled will also participate in the winning post scheduler.
It is possible to mix machines with WindowPoSt and WinningPoSt enabled, for details see the EnableWindowPost
documentation.`,
},
{
Name: "WinningPostMaxTasks",
Type: "int",
Comment: ``,
},
{
Name: "EnableParkPiece",
Type: "bool",
Comment: `EnableParkPiece enables the "piece parking" task to run on this node. This task is responsible for fetching
pieces from the network and storing them in the storage subsystem until sectors are sealed. This task is
only applicable when integrating with boost, and should be enabled on nodes which will hold deal data
from boost until sectors containing the related pieces have the TreeD/TreeR constructed.
Note that future Curio implementations will have a separate task type for fetching pieces from the internet.`,
},
{
Name: "ParkPieceMaxTasks",
Type: "int",
Comment: ``,
},
{
Name: "EnableSealSDR",
Type: "bool",
Comment: `EnableSealSDR enables SDR tasks to run. SDR is the long sequential computation
creating 11 layer files in sector cache directory.
SDR is the first task in the sealing pipeline. It's inputs are just the hash of the
unsealed data (CommD), sector number, miner id, and the seal proof type.
It's outputs are the 11 layer files in the sector cache directory.
In lotus-miner this was run as part of PreCommit1.`,
},
{
Name: "SealSDRMaxTasks",
Type: "int",
Comment: `The maximum amount of SDR tasks that can run simultaneously. Note that the maximum number of tasks will
also be bounded by resources available on the machine.`,
},
{
Name: "EnableSealSDRTrees",
Type: "bool",
Comment: `EnableSealSDRTrees enables the SDR pipeline tree-building task to run.
This task handles encoding of unsealed data into last sdr layer and building
of TreeR, TreeC and TreeD.
This task runs after SDR
TreeD is first computed with optional input of unsealed data
TreeR is computed from replica, which is first computed as field
addition of the last SDR layer and the bottom layer of TreeD (which is the unsealed data)
TreeC is computed from the 11 SDR layers
The 3 trees will later be used to compute the PoRep proof.
In case of SyntheticPoRep challenges for PoRep will be pre-generated at this step, and trees and layers
will be dropped. SyntheticPoRep works by pre-generating a very large set of challenges (~30GiB on disk)
then using a small subset of them for the actual PoRep computation. This allows for significant scratch space
saving between PreCommit and PoRep generation at the expense of more computation (generating challenges in this step)
In lotus-miner this was run as part of PreCommit2 (TreeD was run in PreCommit1).
Note that nodes with SDRTrees enabled will also answer to Finalize tasks,
which just remove unneeded tree data after PoRep is computed.`,
},
{
Name: "SealSDRTreesMaxTasks",
Type: "int",
Comment: `The maximum amount of SealSDRTrees tasks that can run simultaneously. Note that the maximum number of tasks will
also be bounded by resources available on the machine.`,
},
{
Name: "FinalizeMaxTasks",
Type: "int",
Comment: `FinalizeMaxTasks is the maximum amount of finalize tasks that can run simultaneously.
The finalize task is enabled on all machines which also handle SDRTrees tasks. Finalize ALWAYS runs on whichever
machine holds sector cache files, as it removes unneeded tree data after PoRep is computed.
Finalize will run in parallel with the SubmitCommitMsg task.`,
},
{
Name: "EnableSendPrecommitMsg",
Type: "bool",
Comment: `EnableSendPrecommitMsg enables the sending of precommit messages to the chain
from this curio instance.
This runs after SDRTrees and uses the output CommD / CommR (roots of TreeD / TreeR) for the message`,
},
{
Name: "EnablePoRepProof",
Type: "bool",
Comment: `EnablePoRepProof enables the computation of the porep proof
This task runs after interactive-porep seed becomes available, which happens 150 epochs (75min) after the
precommit message lands on chain. This task should run on a machine with a GPU. Vanilla PoRep proofs are
requested from the machine which holds sector cache files which most likely is the machine which ran the SDRTrees
task.
In lotus-miner this was Commit1 / Commit2`,
},
{
Name: "PoRepProofMaxTasks",
Type: "int",
Comment: `The maximum amount of PoRepProof tasks that can run simultaneously. Note that the maximum number of tasks will
also be bounded by resources available on the machine.`,
},
{
Name: "EnableSendCommitMsg",
Type: "bool",
Comment: `EnableSendCommitMsg enables the sending of commit messages to the chain
from this curio instance.`,
},
{
Name: "EnableMoveStorage",
Type: "bool",
Comment: `EnableMoveStorage enables the move-into-long-term-storage task to run on this curio instance.
This tasks should only be enabled on nodes with long-term storage.
The MoveStorage task is the last task in the sealing pipeline. It moves the sealed sector data from the
SDRTrees machine into long-term storage. This task runs after the Finalize task.`,
},
{
Name: "MoveStorageMaxTasks",
Type: "int",
Comment: `The maximum amount of MoveStorage tasks that can run simultaneously. Note that the maximum number of tasks will
also be bounded by resources available on the machine. It is recommended that this value is set to a number which
uses all available network (or disk) bandwidth on the machine without causing bottlenecks.`,
},
{
Name: "BoostAdapters",
Type: "[]string",
Comment: `BoostAdapters is a list of tuples of miner address and port/ip to listen for market (e.g. boost) requests.
This interface is compatible with the lotus-miner RPC, implementing a subset needed for storage market operations.
Strings should be in the format "actor:ip:port". IP cannot be 0.0.0.0. We recommend using a private IP.
Example: "f0123:127.0.0.1:32100". Multiple addresses can be specified.
When a market node like boost gives Curio's market RPC a deal to placing into a sector, Curio will first store the
deal data in a temporary location "Piece Park" before assigning it to a sector. This requires that at least one
node in the cluster has the EnableParkPiece option enabled and has sufficient scratch space to store the deal data.
This is different from lotus-miner which stored the deal data into an "unsealed" sector as soon as the deal was
received. Deal data in PiecePark is accessed when the sector TreeD and TreeR are computed, but isn't needed for
the initial SDR layers computation. Pieces in PiecePark are removed after all sectors referencing the piece are
sealed.
To get API info for boost configuration run 'curio market rpc-info'
NOTE: All deal data will flow through this service, so it should be placed on a machine running boost or on
a machine which handles ParkPiece tasks.`,
},
{
Name: "EnableWebGui",
Type: "bool",
Comment: `EnableWebGui enables the web GUI on this curio instance. The UI has minimal local overhead, but it should
only need to be run on a single machine in the cluster.`,
},
{
Name: "GuiAddress",
Type: "string",
Comment: `The address that should listen for Web GUI requests.`,
},
},
"DealmakingConfig": {
{
Name: "StartEpochSealingBuffer",

View File

@ -60,20 +60,6 @@ type StorageMiner struct {
HarmonyDB HarmonyDB
}
type CurioConfig struct {
Subsystems CurioSubsystemsConfig
Fees CurioFees
// Addresses of wallets per MinerAddress (one of the fields).
Addresses []CurioAddresses
Proving CurioProvingConfig
Ingest CurioIngestConfig
Journal JournalConfig
Apis ApisConfig
Alerting CurioAlerting
}
type ApisConfig struct {
// ChainApiInfo is the API endpoint for the Lotus daemon.
ChainApiInfo []string
@ -89,140 +75,6 @@ type JournalConfig struct {
DisabledEvents string
}
type CurioSubsystemsConfig struct {
// EnableWindowPost enables window post to be executed on this curio instance. Each machine in the cluster
// with WindowPoSt enabled will also participate in the window post scheduler. It is possible to have multiple
// machines with WindowPoSt enabled which will provide redundancy, and in case of multiple partitions per deadline,
// will allow for parallel processing of partitions.
//
// It is possible to have instances handling both WindowPoSt and WinningPoSt, which can provide redundancy without
// the need for additional machines. In setups like this it is generally recommended to run
// partitionsPerDeadline+1 machines.
EnableWindowPost bool
WindowPostMaxTasks int
// EnableWinningPost enables winning post to be executed on this curio instance.
// Each machine in the cluster with WinningPoSt enabled will also participate in the winning post scheduler.
// It is possible to mix machines with WindowPoSt and WinningPoSt enabled, for details see the EnableWindowPost
// documentation.
EnableWinningPost bool
WinningPostMaxTasks int
// EnableParkPiece enables the "piece parking" task to run on this node. This task is responsible for fetching
// pieces from the network and storing them in the storage subsystem until sectors are sealed. This task is
// only applicable when integrating with boost, and should be enabled on nodes which will hold deal data
// from boost until sectors containing the related pieces have the TreeD/TreeR constructed.
// Note that future Curio implementations will have a separate task type for fetching pieces from the internet.
EnableParkPiece bool
ParkPieceMaxTasks int
// EnableSealSDR enables SDR tasks to run. SDR is the long sequential computation
// creating 11 layer files in sector cache directory.
//
// SDR is the first task in the sealing pipeline. It's inputs are just the hash of the
// unsealed data (CommD), sector number, miner id, and the seal proof type.
// It's outputs are the 11 layer files in the sector cache directory.
//
// In lotus-miner this was run as part of PreCommit1.
EnableSealSDR bool
// The maximum amount of SDR tasks that can run simultaneously. Note that the maximum number of tasks will
// also be bounded by resources available on the machine.
SealSDRMaxTasks int
// EnableSealSDRTrees enables the SDR pipeline tree-building task to run.
// This task handles encoding of unsealed data into last sdr layer and building
// of TreeR, TreeC and TreeD.
//
// This task runs after SDR
// TreeD is first computed with optional input of unsealed data
// TreeR is computed from replica, which is first computed as field
// addition of the last SDR layer and the bottom layer of TreeD (which is the unsealed data)
// TreeC is computed from the 11 SDR layers
// The 3 trees will later be used to compute the PoRep proof.
//
// In case of SyntheticPoRep challenges for PoRep will be pre-generated at this step, and trees and layers
// will be dropped. SyntheticPoRep works by pre-generating a very large set of challenges (~30GiB on disk)
// then using a small subset of them for the actual PoRep computation. This allows for significant scratch space
// saving between PreCommit and PoRep generation at the expense of more computation (generating challenges in this step)
//
// In lotus-miner this was run as part of PreCommit2 (TreeD was run in PreCommit1).
// Note that nodes with SDRTrees enabled will also answer to Finalize tasks,
// which just remove unneeded tree data after PoRep is computed.
EnableSealSDRTrees bool
// The maximum amount of SealSDRTrees tasks that can run simultaneously. Note that the maximum number of tasks will
// also be bounded by resources available on the machine.
SealSDRTreesMaxTasks int
// FinalizeMaxTasks is the maximum amount of finalize tasks that can run simultaneously.
// The finalize task is enabled on all machines which also handle SDRTrees tasks. Finalize ALWAYS runs on whichever
// machine holds sector cache files, as it removes unneeded tree data after PoRep is computed.
// Finalize will run in parallel with the SubmitCommitMsg task.
FinalizeMaxTasks int
// EnableSendPrecommitMsg enables the sending of precommit messages to the chain
// from this curio instance.
// This runs after SDRTrees and uses the output CommD / CommR (roots of TreeD / TreeR) for the message
EnableSendPrecommitMsg bool
// EnablePoRepProof enables the computation of the porep proof
//
// This task runs after interactive-porep seed becomes available, which happens 150 epochs (75min) after the
// precommit message lands on chain. This task should run on a machine with a GPU. Vanilla PoRep proofs are
// requested from the machine which holds sector cache files which most likely is the machine which ran the SDRTrees
// task.
//
// In lotus-miner this was Commit1 / Commit2
EnablePoRepProof bool
// The maximum amount of PoRepProof tasks that can run simultaneously. Note that the maximum number of tasks will
// also be bounded by resources available on the machine.
PoRepProofMaxTasks int
// EnableSendCommitMsg enables the sending of commit messages to the chain
// from this curio instance.
EnableSendCommitMsg bool
// EnableMoveStorage enables the move-into-long-term-storage task to run on this curio instance.
// This tasks should only be enabled on nodes with long-term storage.
//
// The MoveStorage task is the last task in the sealing pipeline. It moves the sealed sector data from the
// SDRTrees machine into long-term storage. This task runs after the Finalize task.
EnableMoveStorage bool
// The maximum amount of MoveStorage tasks that can run simultaneously. Note that the maximum number of tasks will
// also be bounded by resources available on the machine. It is recommended that this value is set to a number which
// uses all available network (or disk) bandwidth on the machine without causing bottlenecks.
MoveStorageMaxTasks int
// BoostAdapters is a list of tuples of miner address and port/ip to listen for market (e.g. boost) requests.
// This interface is compatible with the lotus-miner RPC, implementing a subset needed for storage market operations.
// Strings should be in the format "actor:ip:port". IP cannot be 0.0.0.0. We recommend using a private IP.
// Example: "f0123:127.0.0.1:32100". Multiple addresses can be specified.
//
// When a market node like boost gives Curio's market RPC a deal to placing into a sector, Curio will first store the
// deal data in a temporary location "Piece Park" before assigning it to a sector. This requires that at least one
// node in the cluster has the EnableParkPiece option enabled and has sufficient scratch space to store the deal data.
// This is different from lotus-miner which stored the deal data into an "unsealed" sector as soon as the deal was
// received. Deal data in PiecePark is accessed when the sector TreeD and TreeR are computed, but isn't needed for
// the initial SDR layers computation. Pieces in PiecePark are removed after all sectors referencing the piece are
// sealed.
//
// To get API info for boost configuration run 'curio market rpc-info'
//
// NOTE: All deal data will flow through this service, so it should be placed on a machine running boost or on
// a machine which handles ParkPiece tasks.
BoostAdapters []string
// EnableWebGui enables the web GUI on this curio instance. The UI has minimal local overhead, but it should
// only need to be run on a single machine in the cluster.
EnableWebGui bool
// The address that should listen for Web GUI requests.
GuiAddress string
}
type MinerSubsystemConfig struct {
EnableMining bool
EnableSealing bool
@ -543,20 +395,6 @@ type MinerFeeConfig struct {
MaximizeWindowPoStFeeCap bool
}
type CurioFees struct {
DefaultMaxFee types.FIL
MaxPreCommitGasFee types.FIL
MaxCommitGasFee types.FIL
// maxBatchFee = maxBase + maxPerSector * nSectors
MaxPreCommitBatchGasFee BatchFeeConfig
MaxCommitBatchGasFee BatchFeeConfig
MaxTerminateGasFee types.FIL
// WindowPoSt is a high-value operation, so the default fee should be high.
MaxWindowPoStGasFee types.FIL
MaxPublishDealsFee types.FIL
}
type MinerAddressConfig struct {
// Addresses to send PreCommit messages from
PreCommitControl []string
@ -575,135 +413,6 @@ type MinerAddressConfig struct {
DisableWorkerFallback bool
}
type CurioAddresses struct {
// Addresses to send PreCommit messages from
PreCommitControl []string
// Addresses to send Commit messages from
CommitControl []string
TerminateControl []string
// DisableOwnerFallback disables usage of the owner address for messages
// sent automatically
DisableOwnerFallback bool
// DisableWorkerFallback disables usage of the worker address for messages
// sent automatically, if control addresses are configured.
// A control address that doesn't have enough funds will still be chosen
// over the worker address if this flag is set.
DisableWorkerFallback bool
// MinerAddresses are the addresses of the miner actors to use for sending messages
MinerAddresses []string
}
type CurioProvingConfig struct {
// Maximum number of sector checks to run in parallel. (0 = unlimited)
//
// WARNING: Setting this value too high may make the node crash by running out of stack
// WARNING: Setting this value too low may make sector challenge reading much slower, resulting in failed PoSt due
// to late submission.
//
// After changing this option, confirm that the new value works in your setup by invoking
// 'lotus-miner proving compute window-post 0'
ParallelCheckLimit int
// Maximum amount of time a proving pre-check can take for a sector. If the check times out the sector will be skipped
//
// WARNING: Setting this value too low risks in sectors being skipped even though they are accessible, just reading the
// test challenge took longer than this timeout
// WARNING: Setting this value too high risks missing PoSt deadline in case IO operations related to this sector are
// blocked (e.g. in case of disconnected NFS mount)
SingleCheckTimeout Duration
// Maximum amount of time a proving pre-check can take for an entire partition. If the check times out, sectors in
// the partition which didn't get checked on time will be skipped
//
// WARNING: Setting this value too low risks in sectors being skipped even though they are accessible, just reading the
// test challenge took longer than this timeout
// WARNING: Setting this value too high risks missing PoSt deadline in case IO operations related to this partition are
// blocked or slow
PartitionCheckTimeout Duration
// Disable WindowPoSt provable sector readability checks.
//
// In normal operation, when preparing to compute WindowPoSt, lotus-miner will perform a round of reading challenges
// from all sectors to confirm that those sectors can be proven. Challenges read in this process are discarded, as
// we're only interested in checking that sector data can be read.
//
// When using builtin proof computation (no PoSt workers, and DisableBuiltinWindowPoSt is set to false), this process
// can save a lot of time and compute resources in the case that some sectors are not readable - this is caused by
// the builtin logic not skipping snark computation when some sectors need to be skipped.
//
// When using PoSt workers, this process is mostly redundant, with PoSt workers challenges will be read once, and
// if challenges for some sectors aren't readable, those sectors will just get skipped.
//
// Disabling sector pre-checks will slightly reduce IO load when proving sectors, possibly resulting in shorter
// time to produce window PoSt. In setups with good IO capabilities the effect of this option on proving time should
// be negligible.
//
// NOTE: It likely is a bad idea to disable sector pre-checks in setups with no PoSt workers.
//
// NOTE: Even when this option is enabled, recovering sectors will be checked before recovery declaration message is
// sent to the chain
//
// After changing this option, confirm that the new value works in your setup by invoking
// 'lotus-miner proving compute window-post 0'
DisableWDPoStPreChecks bool
// Maximum number of partitions to prove in a single SubmitWindowPoSt messace. 0 = network limit (3 in nv21)
//
// A single partition may contain up to 2349 32GiB sectors, or 2300 64GiB sectors.
// //
// Note that setting this value lower may result in less efficient gas use - more messages will be sent,
// to prove each deadline, resulting in more total gas use (but each message will have lower gas limit)
//
// Setting this value above the network limit has no effect
MaxPartitionsPerPoStMessage int
// Maximum number of partitions to declare in a single DeclareFaultsRecovered message. 0 = no limit.
// In some cases when submitting DeclareFaultsRecovered messages,
// there may be too many recoveries to fit in a BlockGasLimit.
// In those cases it may be necessary to set this value to something low (eg 1);
// Note that setting this value lower may result in less efficient gas use - more messages will be sent than needed,
// resulting in more total gas use (but each message will have lower gas limit)
MaxPartitionsPerRecoveryMessage int
// Enable single partition per PoSt Message for partitions containing recovery sectors
//
// In cases when submitting PoSt messages which contain recovering sectors, the default network limit may still be
// too high to fit in the block gas limit. In those cases, it becomes useful to only house the single partition
// with recovering sectors in the post message
//
// Note that setting this value lower may result in less efficient gas use - more messages will be sent,
// to prove each deadline, resulting in more total gas use (but each message will have lower gas limit)
SingleRecoveringPartitionPerPostMessage bool
}
type CurioIngestConfig struct {
// Maximum number of sectors that can be queued waiting for SDR to start processing.
// 0 = unlimited
// Note: This mechanism will delay taking deal data from markets, providing backpressure to the market subsystem.
// The SDR queue includes deals which are in the process of entering the sealing pipeline - size of this queue
// will also impact the maximum number of ParkPiece tasks which can run concurrently.
//
// SDR queue is the first queue in the sealing pipeline, meaning that it should be used as the primary backpressure mechanism.
MaxQueueSDR int
// Maximum number of sectors that can be queued waiting for SDRTrees to start processing.
// 0 = unlimited
// Note: This mechanism will delay taking deal data from markets, providing backpressure to the market subsystem.
// In case of the trees tasks it is possible that this queue grows more than this limit, the backpressure is only
// applied to sectors entering the pipeline.
MaxQueueTrees int
// Maximum number of sectors that can be queued waiting for PoRep to start processing.
// 0 = unlimited
// Note: This mechanism will delay taking deal data from markets, providing backpressure to the market subsystem.
// Like with the trees tasks, it is possible that this queue grows more than this limit, the backpressure is only
// applied to sectors entering the pipeline.
MaxQueuePoRep int
}
// API contains configs for API endpoint
type API struct {
// Binding address for the Lotus API
@ -947,18 +656,3 @@ type FaultReporterConfig struct {
// rewards. This address should have adequate funds to cover gas fees.
ConsensusFaultReporterAddress string
}
type CurioAlerting struct {
// PagerDutyEventURL is URL for PagerDuty.com Events API v2 URL. Events sent to this API URL are ultimately
// routed to a PagerDuty.com service and processed.
// The default is sufficient for integration with the stock commercial PagerDuty.com company's service.
PagerDutyEventURL string
// PageDutyIntegrationKey is the integration key for a PagerDuty.com service. You can find this unique service
// identifier in the integration page for the service.
PageDutyIntegrationKey string
// MinimumWalletBalance is the minimum balance all active wallets. If the balance is below this value, an
// alerts will be triggered for the wallet
MinimumWalletBalance types.FIL
}

View File

@ -34,6 +34,7 @@ type FullNodeAPI struct {
full.SyncAPI
full.EthAPI
full.ActorEventsAPI
full.F3API
DS dtypes.MetadataDS
NetworkName dtypes.NetworkName

View File

@ -44,6 +44,11 @@ var ErrUnsupported = errors.New("unsupported method")
const maxEthFeeHistoryRewardPercentiles = 100
var (
// wait for 3 epochs
eventReadTimeout = 90 * time.Second
)
type EthModuleAPI interface {
EthBlockNumber(ctx context.Context) (ethtypes.EthUint64, error)
EthAccounts(ctx context.Context) ([]ethtypes.EthAddress, error)
@ -1258,10 +1263,58 @@ func (e *EthEventHandler) EthGetLogs(ctx context.Context, filterSpec *ethtypes.E
return nil, api.ErrNotSupported
}
// Create a temporary filter
f, err := e.installEthFilterSpec(ctx, filterSpec)
if e.EventFilterManager.EventIndex == nil {
return nil, xerrors.Errorf("cannot use eth_get_logs if historical event index is disabled")
}
pf, err := e.parseEthFilterSpec(ctx, filterSpec)
if err != nil {
return nil, err
return nil, xerrors.Errorf("failed to parse eth filter spec: %w", err)
}
if pf.tipsetCid == cid.Undef {
maxHeight := pf.maxHeight
if maxHeight == -1 {
maxHeight = e.Chain.GetHeaviestTipSet().Height()
}
if maxHeight > e.Chain.GetHeaviestTipSet().Height() {
return nil, xerrors.Errorf("maxHeight requested is greater than the heaviest tipset")
}
err := e.waitForHeightProcessed(ctx, maxHeight)
if err != nil {
return nil, err
}
// should also have the minHeight in the filter indexed
if b, err := e.EventFilterManager.EventIndex.IsHeightProcessed(ctx, uint64(pf.minHeight)); err != nil {
return nil, xerrors.Errorf("failed to check if event index has events for the minHeight: %w", err)
} else if !b {
return nil, xerrors.Errorf("event index does not have event for epoch %d", pf.minHeight)
}
} else {
ts, err := e.Chain.GetTipSetByCid(ctx, pf.tipsetCid)
if err != nil {
return nil, xerrors.Errorf("failed to get tipset by cid: %w", err)
}
err = e.waitForHeightProcessed(ctx, ts.Height())
if err != nil {
return nil, err
}
b, err := e.EventFilterManager.EventIndex.IsTipsetProcessed(ctx, pf.tipsetCid.Bytes())
if err != nil {
return nil, xerrors.Errorf("failed to check if tipset events have been indexed: %w", err)
}
if !b {
return nil, xerrors.Errorf("event index failed to index tipset %s", pf.tipsetCid.String())
}
}
// Create a temporary filter
f, err := e.EventFilterManager.Install(ctx, pf.minHeight, pf.maxHeight, pf.tipsetCid, pf.addresses, pf.keys, true)
if err != nil {
return nil, xerrors.Errorf("failed to install event filter: %w", err)
}
ces := f.TakeCollectedEvents(ctx)
@ -1270,6 +1323,47 @@ func (e *EthEventHandler) EthGetLogs(ctx context.Context, filterSpec *ethtypes.E
return ethFilterResultFromEvents(ctx, ces, e.SubManager.StateAPI)
}
func (e *EthEventHandler) waitForHeightProcessed(ctx context.Context, height abi.ChainEpoch) error {
ei := e.EventFilterManager.EventIndex
if height > e.Chain.GetHeaviestTipSet().Height() {
return xerrors.New("height is in the future")
}
ctx, cancel := context.WithTimeout(ctx, eventReadTimeout)
defer cancel()
// if the height we're interested in has already been indexed -> there's nothing to do here
if b, err := ei.IsHeightProcessed(ctx, uint64(height)); err != nil {
return xerrors.Errorf("failed to check if event index has events for given height: %w", err)
} else if b {
return nil
}
// subscribe for updates to the event index
subCh, unSubscribeF := ei.SubscribeUpdates()
defer unSubscribeF()
// it could be that the event index was update while the subscription was being processed -> check if index has what we need now
if b, err := ei.IsHeightProcessed(ctx, uint64(height)); err != nil {
return xerrors.Errorf("failed to check if event index has events for given height: %w", err)
} else if b {
return nil
}
for {
select {
case <-subCh:
if b, err := ei.IsHeightProcessed(ctx, uint64(height)); err != nil {
return xerrors.Errorf("failed to check if event index has events for given height: %w", err)
} else if b {
return nil
}
case <-ctx.Done():
return ctx.Err()
}
}
}
func (e *EthEventHandler) EthGetFilterChanges(ctx context.Context, id ethtypes.EthFilterID) (*ethtypes.EthFilterResult, error) {
if e.FilterStore == nil {
return nil, api.ErrNotSupported
@ -1368,7 +1462,15 @@ func parseBlockRange(heaviest abi.ChainEpoch, fromBlock, toBlock *string, maxRan
return minHeight, maxHeight, nil
}
func (e *EthEventHandler) installEthFilterSpec(ctx context.Context, filterSpec *ethtypes.EthFilterSpec) (filter.EventFilter, error) {
type parsedFilter struct {
minHeight abi.ChainEpoch
maxHeight abi.ChainEpoch
tipsetCid cid.Cid
addresses []address.Address
keys map[string][]types.ActorEventBlock
}
func (e *EthEventHandler) parseEthFilterSpec(ctx context.Context, filterSpec *ethtypes.EthFilterSpec) (*parsedFilter, error) {
var (
minHeight abi.ChainEpoch
maxHeight abi.ChainEpoch
@ -1405,7 +1507,13 @@ func (e *EthEventHandler) installEthFilterSpec(ctx context.Context, filterSpec *
return nil, err
}
return e.EventFilterManager.Install(ctx, minHeight, maxHeight, tipsetCid, addresses, keysToKeysWithCodec(keys), true)
return &parsedFilter{
minHeight: minHeight,
maxHeight: maxHeight,
tipsetCid: tipsetCid,
addresses: addresses,
keys: keysToKeysWithCodec(keys),
}, nil
}
func keysToKeysWithCodec(keys map[string][][]byte) map[string][]types.ActorEventBlock {
@ -1426,11 +1534,16 @@ func (e *EthEventHandler) EthNewFilter(ctx context.Context, filterSpec *ethtypes
return ethtypes.EthFilterID{}, api.ErrNotSupported
}
f, err := e.installEthFilterSpec(ctx, filterSpec)
pf, err := e.parseEthFilterSpec(ctx, filterSpec)
if err != nil {
return ethtypes.EthFilterID{}, err
}
f, err := e.EventFilterManager.Install(ctx, pf.minHeight, pf.maxHeight, pf.tipsetCid, pf.addresses, pf.keys, true)
if err != nil {
return ethtypes.EthFilterID{}, xerrors.Errorf("failed to install event filter: %w", err)
}
if err := e.FilterStore.Add(ctx, f); err != nil {
// Could not record in store, attempt to delete filter to clean up
err2 := e.TipSetFilterManager.Remove(ctx, f.ID())

View File

@ -103,8 +103,8 @@ func baseEnvironment(st *state.StateTree, from address.Address) (*environment, e
}
func traceToAddress(act *types.ActorTrace) ethtypes.EthAddress {
if act.State.Address != nil {
if addr, err := ethtypes.EthAddressFromFilecoinAddress(*act.State.Address); err == nil {
if act.State.DelegatedAddress != nil {
if addr, err := ethtypes.EthAddressFromFilecoinAddress(*act.State.DelegatedAddress); err == nil {
return addr
}
}

View File

@ -57,6 +57,22 @@ func getTipsetByBlockNumber(ctx context.Context, chain *store.ChainStore, blkPar
return nil, fmt.Errorf("cannot get parent tipset")
}
return parent, nil
case "safe":
latestHeight := head.Height() - 1
safeHeight := latestHeight - ethtypes.SafeEpochDelay
ts, err := chain.GetTipsetByHeight(ctx, safeHeight, head, true)
if err != nil {
return nil, fmt.Errorf("cannot get tipset at height: %v", safeHeight)
}
return ts, nil
case "finalized":
latestHeight := head.Height() - 1
safeHeight := latestHeight - build.Finality
ts, err := chain.GetTipsetByHeight(ctx, safeHeight, head, true)
if err != nil {
return nil, fmt.Errorf("cannot get tipset at height: %v", safeHeight)
}
return ts, nil
default:
var num ethtypes.EthUint64
err := num.UnmarshalJSON([]byte(`"` + blkParam + `"`))
@ -403,9 +419,9 @@ func lookupEthAddress(addr address.Address, st *state.StateTree) (ethtypes.EthAd
} else if err != nil {
// Any other error -> fail.
return ethtypes.EthAddress{}, err
} else if actor.Address == nil {
} else if actor.DelegatedAddress == nil {
// No delegated address -> use masked ID address.
} else if ethAddr, err := ethtypes.EthAddressFromFilecoinAddress(*actor.Address); err == nil && !ethAddr.IsMaskedID() {
} else if ethAddr, err := ethtypes.EthAddressFromFilecoinAddress(*actor.DelegatedAddress); err == nil && !ethAddr.IsMaskedID() {
// Conversable into an eth address, use it.
return ethAddr, nil
}

57
node/impl/full/f3.go Normal file
View File

@ -0,0 +1,57 @@
package full
import (
"context"
"errors"
"go.uber.org/fx"
"golang.org/x/xerrors"
"github.com/filecoin-project/go-address"
"github.com/filecoin-project/go-f3/certs"
"github.com/filecoin-project/lotus/chain/lf3"
)
type F3API struct {
fx.In
F3 *lf3.F3 `optional:"true"`
}
var ErrF3Disabled = errors.New("f3 is disabled")
func (f3api *F3API) F3Participate(ctx context.Context, miner address.Address) (<-chan string, error) {
if f3api.F3 == nil {
log.Infof("F3Participate called for %v, F3 is disabled", miner)
return nil, ErrF3Disabled
}
// Make channel with some buffer to avoid blocking under higher load.
errCh := make(chan string, 4)
log.Infof("starting F3 participation for %v", miner)
actorID, err := address.IDFromAddress(miner)
if err != nil {
return nil, xerrors.Errorf("miner address in F3Participate not of ID type: %w", err)
}
// Participate takes control of closing the channel
go f3api.F3.Participate(ctx, actorID, errCh)
return errCh, nil
}
func (f3api *F3API) F3GetCertificate(ctx context.Context, instance uint64) (*certs.FinalityCertificate, error) {
if f3api.F3 == nil {
return nil, ErrF3Disabled
}
return f3api.F3.GetCert(ctx, instance)
}
func (f3api *F3API) F3GetLatestCertificate(ctx context.Context) (*certs.FinalityCertificate, error) {
if f3api.F3 == nil {
return nil, ErrF3Disabled
}
return f3api.F3.GetLatestCert(ctx)
}

View File

@ -1962,7 +1962,7 @@ func (a *StateAPI) StateGetNetworkParams(ctx context.Context) (*api.NetworkParam
UpgradeWatermelonHeight: build.UpgradeWatermelonHeight,
UpgradeDragonHeight: build.UpgradeDragonHeight,
UpgradePhoenixHeight: build.UpgradePhoenixHeight,
UpgradeAussieHeight: build.UpgradeAussieHeight,
UpgradeWaffleHeight: build.UpgradeWaffleHeight,
},
}, nil
}

View File

@ -138,11 +138,11 @@ func EventFilterManager(cfg config.EventsConfig) func(helpers.MetricsCtx, repo.L
}
actor, err := sm.LoadActor(ctx, idAddr, ts)
if err != nil || actor.Address == nil {
if err != nil || actor.DelegatedAddress == nil {
return idAddr, true
}
return *actor.Address, true
return *actor.DelegatedAddress, true
},
MaxFilterResults: cfg.MaxFilterResults,

View File

@ -4,10 +4,10 @@ import (
"context"
"fmt"
nilrouting "github.com/ipfs/boxo/routing/none"
"github.com/libp2p/go-libp2p"
dht "github.com/libp2p/go-libp2p-kad-dht"
record "github.com/libp2p/go-libp2p-record"
routinghelpers "github.com/libp2p/go-libp2p-routing-helpers"
"github.com/libp2p/go-libp2p/core/host"
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/peerstore"
@ -115,7 +115,7 @@ func DHTRouting(mode dht.ModeOpt) interface{} {
}
func NilRouting(mctx helpers.MetricsCtx) (BaseIpfsRouting, error) {
return nilrouting.ConstructNilRouting(mctx, nil, nil, nil)
return &routinghelpers.Null{}, nil
}
func RoutedHost(rh RawHost, r BaseIpfsRouting) host.Host {

View File

@ -16,6 +16,8 @@ import (
"go.uber.org/fx"
"golang.org/x/xerrors"
"github.com/filecoin-project/go-f3/gpbft"
"github.com/filecoin-project/lotus/build"
"github.com/filecoin-project/lotus/metrics"
"github.com/filecoin-project/lotus/node/config"
@ -378,6 +380,11 @@ func GossipSub(in GossipIn) (service *pubsub.PubSub, err error) {
build.MessagesTopic(in.Nn),
build.IndexerIngestTopic(in.Nn),
}
if build.F3Enabled {
allowTopics = append(allowTopics, gpbft.NetworkName(in.Nn).PubSubTopic())
}
allowTopics = append(allowTopics, drandTopics...)
options = append(options,
pubsub.WithSubscriptionFilter(

View File

@ -10,6 +10,7 @@ import (
"github.com/google/uuid"
"github.com/ipfs/go-datastore"
"github.com/ipfs/go-datastore/namespace"
"github.com/jpillora/backoff"
"go.uber.org/fx"
"go.uber.org/multierr"
"golang.org/x/xerrors"
@ -32,6 +33,7 @@ import (
"github.com/filecoin-project/lotus/journal"
lotusminer "github.com/filecoin-project/lotus/miner"
"github.com/filecoin-project/lotus/node/config"
"github.com/filecoin-project/lotus/node/impl/full"
"github.com/filecoin-project/lotus/node/modules/dtypes"
"github.com/filecoin-project/lotus/node/modules/helpers"
"github.com/filecoin-project/lotus/node/repo"
@ -351,6 +353,60 @@ func SectorStorage(mctx helpers.MetricsCtx, lc fx.Lifecycle, lstor *paths.Local,
return sst, nil
}
func F3Participation(mctx helpers.MetricsCtx, lc fx.Lifecycle, api v1api.FullNode, minerAddress dtypes.MinerAddress) error {
ctx := helpers.LifecycleCtx(mctx, lc)
b := &backoff.Backoff{
Min: 1 * time.Second,
Max: 1 * time.Minute,
Factor: 1.5,
Jitter: false,
}
go func() {
timer := time.NewTimer(0)
defer timer.Stop()
if !timer.Stop() {
<-timer.C
}
// Backoff while obeying the context.
backoffWithContext := func() {
timer.Reset(b.Duration())
select {
case <-ctx.Done():
log.Errorf("Context is done while retrying F3 participation: %+v", ctx.Err())
case <-timer.C:
}
}
for ctx.Err() == nil {
switch ch, err := api.F3Participate(ctx, address.Address(minerAddress)); {
case errors.Is(err, context.Canceled):
log.Errorf("Context cancelled while attampting F3 participation: %+v", err)
return
case errors.Is(err, full.ErrF3Disabled):
log.Errorf("Cannot participate in F3 as it is disabled: %+v", err)
return
case err != nil:
log.Errorf("while starting to participate in F3: %+v", err)
// use exponential backoff to avoid hotloop
backoffWithContext()
default:
for err := range ch {
// we have communication with F3 in lotus, reset the backoff
b.Reset()
if err != "" {
log.Warnf("participating in F3 encountered an error: %v", err)
}
}
log.Warn("F3Participate exited, retrying")
backoffWithContext()
}
}
}()
return nil
}
func StorageAuth(ctx helpers.MetricsCtx, ca v0api.Common) (sealer.StorageAuth, error) {
token, err := ca.AuthNew(ctx, []auth.Permission{"admin"})
if err != nil {

View File

@ -39,15 +39,15 @@ func LayerFileName(layer int) string {
func SDRLayers(spt abi.RegisteredSealProof) (int, error) {
switch spt {
case abi.RegisteredSealProof_StackedDrg2KiBV1, abi.RegisteredSealProof_StackedDrg2KiBV1_1, abi.RegisteredSealProof_StackedDrg2KiBV1_1_Feat_SyntheticPoRep:
case abi.RegisteredSealProof_StackedDrg2KiBV1, abi.RegisteredSealProof_StackedDrg2KiBV1_1, abi.RegisteredSealProof_StackedDrg2KiBV1_1_Feat_SyntheticPoRep, abi.RegisteredSealProof_StackedDrg2KiBV1_2_Feat_NiPoRep:
return 2, nil
case abi.RegisteredSealProof_StackedDrg8MiBV1, abi.RegisteredSealProof_StackedDrg8MiBV1_1, abi.RegisteredSealProof_StackedDrg8MiBV1_1_Feat_SyntheticPoRep:
case abi.RegisteredSealProof_StackedDrg8MiBV1, abi.RegisteredSealProof_StackedDrg8MiBV1_1, abi.RegisteredSealProof_StackedDrg8MiBV1_1_Feat_SyntheticPoRep, abi.RegisteredSealProof_StackedDrg8MiBV1_2_Feat_NiPoRep:
return 2, nil
case abi.RegisteredSealProof_StackedDrg512MiBV1, abi.RegisteredSealProof_StackedDrg512MiBV1_1, abi.RegisteredSealProof_StackedDrg512MiBV1_1_Feat_SyntheticPoRep:
case abi.RegisteredSealProof_StackedDrg512MiBV1, abi.RegisteredSealProof_StackedDrg512MiBV1_1, abi.RegisteredSealProof_StackedDrg512MiBV1_1_Feat_SyntheticPoRep, abi.RegisteredSealProof_StackedDrg512MiBV1_2_Feat_NiPoRep:
return 2, nil
case abi.RegisteredSealProof_StackedDrg32GiBV1, abi.RegisteredSealProof_StackedDrg32GiBV1_1, abi.RegisteredSealProof_StackedDrg32GiBV1_1_Feat_SyntheticPoRep:
case abi.RegisteredSealProof_StackedDrg32GiBV1, abi.RegisteredSealProof_StackedDrg32GiBV1_1, abi.RegisteredSealProof_StackedDrg32GiBV1_1_Feat_SyntheticPoRep, abi.RegisteredSealProof_StackedDrg32GiBV1_2_Feat_NiPoRep:
return 11, nil
case abi.RegisteredSealProof_StackedDrg64GiBV1, abi.RegisteredSealProof_StackedDrg64GiBV1_1, abi.RegisteredSealProof_StackedDrg64GiBV1_1_Feat_SyntheticPoRep:
case abi.RegisteredSealProof_StackedDrg64GiBV1, abi.RegisteredSealProof_StackedDrg64GiBV1_1, abi.RegisteredSealProof_StackedDrg64GiBV1_1_Feat_SyntheticPoRep, abi.RegisteredSealProof_StackedDrg64GiBV1_2_Feat_NiPoRep:
return 11, nil
default:
return 0, fmt.Errorf("unsupported proof type: %v", spt)