Commit Graph

227 Commits

Author SHA1 Message Date
Aayush Rajasekaran
4d6a0f7b8c Set WinningPoStSectorSetLookback to finality post-v2 actors 2020-10-06 17:40:37 -04:00
Aayush Rajasekaran
4a9155ba85 Use new MinerEligibleToMine method post-v2 actors 2020-10-06 04:43:55 -04:00
Aayush Rajasekaran
f8c886a611 Rename MiningBaseInfo.HasMinPower to EligibleForMining 2020-10-06 03:49:11 -04:00
Steven Allen
5253c0d959 fix: import the correct v2 methods 2020-09-30 10:11:48 -07:00
Steven Allen
ca9448bc11 rename actors v1 -> actors v2
The actual actors version is v2, not v1. Using Version1 internally was really confusing.
2020-09-28 13:13:18 -07:00
Steven Allen
947d1e2902 Merge branch 'master' into asr/spec-v1 2020-09-28 12:53:40 -07:00
Steven Allen
5f3160cf5b continue expanding vm abstraction layer 2020-09-28 12:48:08 -07:00
whyrusleeping
bddd6dd8a8 fix GetPower with no miner address 2020-09-26 11:06:16 -05:00
Łukasz Magiera
ef28ebb14a Ignition upgrades, much excite. 2020-09-25 23:55:37 -07:00
Steven Allen
858f11992f compile fix 2020-09-25 12:49:39 -07:00
Aayush Rajasekaran
ebad0ded3d Introduce v1 actors 2020-09-25 12:49:39 -07:00
Steven Allen
441d7ff790 cleanup imports some more 2020-09-22 11:14:55 -07:00
Aayush Rajasekaran
d56da1b014 Refinements to stmgr and utils 2020-09-22 01:34:20 -04:00
Steven Allen
4cf0c105eb optimize sector loading
And avoid exposing "arrays" via the miner abstraction. We may change these
structures later.
2020-09-21 12:12:08 -07:00
Aayush Rajasekaran
286fe04271 Add some TODOs 2020-09-21 02:52:45 -04:00
Aayush Rajasekaran
a95e34f742 Fix build 2020-09-21 02:02:33 -04:00
Łukasz Magiera
b25dd2a00d More correct / fasterer GetSectorsForWinningPoSt 2020-09-20 23:04:45 +02:00
Steven Allen
1bf3b4989d rename imports to match actors code
`sed -i 's/\bv0\(\w\)\(\w*\)/\L\1\E\20/g' **/*.go`
2020-09-18 14:59:27 -07:00
Łukasz Magiera
70faa36b7f Merge remote-tracking branch 'origin/master' into refactor/net-upgrade 2020-09-18 19:29:06 +02:00
Łukasz Magiera
6eda53565f Most tests passing 2020-09-17 17:30:24 +02:00
Aayush Rajasekaran
31ff5230bb Get State API almost working 2020-09-17 05:05:32 -04:00
Aayush Rajasekaran
053cfc1cc7 Migrate verifreg actor 2020-09-17 03:55:23 -04:00
hannahhoward
691bd9f442 feat(markets): complete markets conversion
complete markets conversion to using chain/actors types, also replacing DealProposal/DealState
interfaces with structs
2020-09-17 00:43:14 -07:00
Aayush Rajasekaran
e2295c372a Migrate multisig actor 2020-09-17 02:57:45 -04:00
Aayush Rajasekaran
b60614982e Migrate reward actor 2020-09-17 02:42:39 -04:00
Aayush Rajasekaran
9e48dd211a Fixups 2020-09-17 02:34:15 -04:00
Aayush Rajasekaran
90853e24cf Add a boolean HasMinPower to return of GetPower 2020-09-16 01:47:24 -04:00
Aayush Rajasekaran
b4ee519282 Partial progress towards switching to miner and power interfaces 2020-09-16 01:37:49 -04:00
jennijuju
5c69249ba3 Use window post for window PoSt related log messages. 2020-09-15 21:22:29 -04:00
Steven Allen
454c382e7e migrate StateMinerInitialPledgeCollateral 2020-09-15 18:05:33 -07:00
Steven Allen
91e9573863 Compile fixes 2020-09-15 12:13:13 -07:00
Łukasz Magiera
4419850195 state api impl fixes 2020-09-15 15:29:25 +02:00
Łukasz Magiera
4dabab5ce6 state manager progress 2020-09-15 13:04:45 +02:00
Steven Allen
36f920bcd7 progress 2020-09-14 21:55:49 -07:00
Steven Allen
cc4d5306eb Progress 2020-09-14 15:43:12 -07:00
Steven Allen
02dcb5e182 Merge branch 'master' into refactor/net-upgrade 2020-09-14 14:53:57 -07:00
Steven Allen
9804310cc8 Update specs-actors to 0.9.10
Moves the Keyer type (and helpers) into go-state-types.
2020-09-14 14:32:57 -07:00
Łukasz Magiera
06ec571c20 Merge remote-tracking branch 'origin/master' into refactor/net-upgrade 2020-09-14 15:09:52 +02:00
Łukasz Magiera
683a58195e More terraforming in chain/ 2020-09-14 14:46:38 +02:00
Steven Allen
d3594835c4 [WIP] Network upgrade support
This patch starts adding support for network upgrades.

* It adds an actors abstraction layer for loading abstract (cross-version) actors.
* It starts switching over to a shared deadline type.
* It adds an abstraction for ADTs (hamt/amt).
* It removes the callback-based API in the StateManager (difficult to abstract
across actor versions).
* It _does not_ actually add support for actors v2. We can do that in a followup
patch but that should be relatively easy.

This patch is heavily WIP and does not compile. Feel free to push changes
directly to this branch.

Notes:

* State tree access now needs a network version, because the HAMT type will change.
* I haven't figured out a nice way to abstract over changes to the _message_
types. However, many of them will be type aliased to actors v0 in actors v2 so
we can likely continue using the v0 versions (or use the v2 versions
everywhere). I've been renaming imports to `v0*` to make it clear that we're
importing types from a _specific_ actors version.

TODO:

* Consider merging incremental improvements? We'd have to get this compiling
again first but we could merge in the new abstractions, and slowly switch over.
* Finish migrating to the new abstractions.
* Remove all actor state types from the public API. See `miner.State.Info()` for
the planned approach here.
* Fix the tests. This is likely going to be a massive pain.
2020-09-11 20:16:29 -07:00
Aayush Rajasekaran
316ac61875 Update to go state types 3ca0d2890090 2020-09-10 17:41:55 -04:00
Jakub Sztandera
2d3f92aeed Introduce beacon Schedule
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-09-10 17:41:55 -04:00
whyrusleeping
8a8f0ab3ec pass tipset through upgrade logic 2020-09-08 13:45:44 -07:00
Aayush Rajasekaran
6eea5dd109 Update to specs 0.9.7 and markets 0.6.0 2020-09-07 17:11:32 -04:00
Aayush Rajasekaran
d678fe4bfa Fix tests 2020-09-07 15:48:42 -04:00
Aayush Rajasekaran
39755a294a Update to specs v0.9.6 2020-09-07 15:48:41 -04:00
Steven Allen
fceeaf42ca Robustify state manager against holes in actor method numbers
Also, don't simply assume that the field order matches the method numbers in
`builtin.Method*` structs.
2020-09-04 12:26:55 -07:00
austinabell
ba881eb4cf
Remove height from chain rand 2020-09-01 15:48:16 -04:00
Łukasz Magiera
df635579c4 storagefsm: Handle sectors with expired deals better 2020-08-27 13:51:38 +02:00
Łukasz Magiera
6ef7a30b19
Merge pull request #3089 from filecoin-project/integrate/storage-fsm
integrate extern/{storage-fsm,sector-storage} into lotus source tree
2020-08-17 18:37:54 +02:00
Łukasz Magiera
704578c9c2
Merge pull request #3108 from austinabell/msload
Remove unnecessary miner state load for checking slashed
2020-08-17 18:11:09 +02:00
austinabell
c3c6fda9d5
Remove unnecessary miner state load for checking slashed 2020-08-17 09:32:47 -04:00
Raúl Kripalani
efdc428d5d keep storage-fsm (renamed to storage-sealing) and sector-storage in extern. 2020-08-17 14:26:18 +01:00
Raúl Kripalani
3c17cd655e integrate extern/sector-storage into lotus proper. 2020-08-16 11:09:58 +01:00
whyrusleeping
b3a31d8823 add function to check entire state tree balance 2020-08-12 15:45:46 -07:00
Aayush Rajasekaran
48ab706691 Subtract out genesis pledge and market funds when calculating circ supply 2020-08-12 15:32:11 -04:00
Aayush Rajasekaran
fe2da35a45 Move GetCircSupply out of the vm, and into stmgr 2020-08-12 15:32:07 -04:00
Steven Allen
9135a5d048 Pass bitfields by-value
This ensures we can't end up decoding nil bitfields from clients when not
expecting them.

Part of https://github.com/filecoin-project/specs-actors/issues/895. Please see
this issue for details and leave any comments there.
2020-08-12 10:32:39 -07:00
whyrusleeping
fbe206f843 add command to view circulating supply 2020-08-07 12:57:03 -07:00
Jakub Sztandera
722d6e8ffb
Introduce base fee
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-08-06 21:14:38 +02:00
Aayush Rajasekaran
b51e2a868b
Merge branch 'next' into feat/cid-builder 2020-07-28 21:02:30 -04:00
Aayush Rajasekaran
a4fe359c28
Merge pull request #2605 from filecoin-project/asr/vesting-genesis
Correct calculation of TotalCircSupply
2020-07-28 20:43:55 -04:00
Aayush Rajasekaran
de867d7a9a Correct calculation of TotalCircSupply 2020-07-28 17:26:55 -04:00
Aayush Rajasekaran
859168015a Use specs actor's MinerNominalPowerMeetsConsensusMinimum 2020-07-28 17:21:05 -04:00
Łukasz Magiera
09b90773d8 Merge remote-tracking branch 'origin/next' into feat/cid-builder 2020-07-28 16:06:06 +02:00
Łukasz Magiera
eac0a1bba9 stmgr: Handle state forks with cron on null blocks correctly 2020-07-28 14:31:28 +02:00
Steven Allen
b7a4dbb07f Support inline CIDs
And use the new CidBuilder from the spec actors.

This patch does not switch over to inline CIDs by default, but paves the way.
2020-07-23 23:12:32 -07:00
Steven Allen
5fc83f4d05 Refactor to use actor adt types instead of directly using HAMTs and AMTs
This way there's a single source of truth. Preparation for fixing
https://github.com/filecoin-project/specs-actors/issues/517 (requires changing
HAMT parameters).
2020-07-23 09:34:57 -07:00
Jakub Sztandera
7da629d03b
Update gas prices
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-07-20 21:31:05 +02:00
Łukasz Magiera
af87b9aa98 Fix widowed PoSt scheduler 2020-07-14 19:10:31 +02:00
Łukasz Magiera
faebc4c948 WIP Integrating specs-actors with refactored miner state 2020-07-14 13:45:45 +02:00
Aayush Rajasekaran
2a61b241a8 Replace abi.BitFieldUnion with bitfield.MultiMerge 2020-07-12 00:30:42 -04:00
Łukasz Magiera
4b0ae7ef9a Merge remote-tracking branch 'origin/master' into next 2020-07-06 11:38:19 +02:00
whyrusleeping
16e493a67a provide decoded return values in output of StateWaitMsg 2020-07-03 09:57:58 -07:00
Łukasz Magiera
655d6f6720 Merge remote-tracking branch 'origin/master' into next 2020-07-03 17:03:09 +02:00
Aayush Rajasekaran
605e9bbbd7 Add docs comments to API 2020-07-01 17:16:05 -04:00
Łukasz Magiera
4c422c2d50 specs-actors v0.7.1 2020-07-01 13:47:40 +02:00
Łukasz Magiera
cfdbc2312d Merge branch 'master' into next 2020-07-01 11:22:57 +02:00
whyrusleeping
da78ff9151 use bitfields to enumerate sectors for winning post 2020-06-30 21:57:49 -07:00
Łukasz Magiera
edd7151184 Fix StateMinerInitialPledgeCollateral 2020-06-26 15:49:39 +02:00
Łukasz Magiera
a6d1323eba Update specs-actors to v0.7.0; More correct genesis sector import 2020-06-26 15:08:12 +02:00
Łukasz Magiera
907364ce67 Update deps, fix more tests 2020-06-15 18:30:49 +02:00
Jakub Sztandera
5605aae269
Fix even more lint warnings
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-02 16:29:39 +02:00
Jeromy
e2a554c2e6 update specs actors to version with batch porep verification 2020-05-28 13:19:18 -07:00
Łukasz Magiera
ae60001dcc post: Handle Recovering sectors 2020-05-20 18:41:20 +02:00
Jeromy
fa59cdc2ad update to specs-actors code with faster publish deals 2020-05-05 17:06:32 -07:00
Jeromy
74510adaaa add flag to choose what to do when looking back tipsets in null rounds 2020-05-05 10:06:05 -07:00
Jeromy
be2a357102 winning post wants the actual epoch of the block, not the previous 2020-05-01 12:42:59 -07:00
Łukasz Magiera
d9acd484c0 storageminer: Improve CLI UX 2020-05-01 14:06:19 +02:00
Jeromy
bee25d221f fix mining base randomness 2020-04-30 15:11:14 -07:00
Łukasz Magiera
c137b0cf73 Merge remote-tracking branch 'origin/testnet/3' into feat/newminer 2020-04-23 23:53:23 +02:00
Łukasz Magiera
86e7f5914b testing: test 2-miner mining 2020-04-23 23:20:02 +02:00
Whyrusleeping
faa9002cce working on sector pledge requirements after specs-actors 1.0.0 (#1584)
* WIP: working on sector pledge requirements after specs-actors 1.0.0

* update storage-fsm with pledge collateral logic

* Set bigger balances for miners

* Return only additional required pledge

* split collateral methods into two methods

Co-authored-by: Łukasz Magiera <magik6k@gmail.com>
2020-04-23 12:39:34 -07:00
Łukasz Magiera
8be9494672 windowed post: Get correct sector set 2020-04-21 19:22:53 +02:00
Łukasz Magiera
f43ce74604 Update specs-actors 2020-04-21 16:32:17 +02:00
Łukasz Magiera
ecc38d1bd8 sync: env var to fix drand 2020-04-20 20:33:53 +02:00
Jeromy
91f56742c4 Use lookback to get sector set and power for miners 2020-04-17 16:44:18 -07:00
Łukasz Magiera
3b7ae0d6d9 mod tidy, gofmt 2020-04-18 00:02:43 +02:00
Łukasz Magiera
712e2683d6 miner: proving info commands 2020-04-18 00:02:18 +02:00
Łukasz Magiera
e6270e4291 Update fsm; get sectorset form correct ts 2020-04-17 21:49:32 +02:00