Commit Graph

552 Commits

Author SHA1 Message Date
Raúl Kripalani
7f0f7d0b36 Merge branch 'master' into refactor/lib/blockstore 2021-02-28 19:55:23 +00:00
Aayush Rajasekaran
60b7f56297 Code review 2021-02-19 15:10:56 -05:00
Aayush Rajasekaran
96b4b828f7 Remove the null bls actor from the init actor state 2021-02-18 19:01:28 -05:00
Aayush Rajasekaran
a0fedf8bdb Only delete the zero BLS actor on mainnet 2021-02-18 19:01:21 -05:00
Aayush Rajasekaran
5aff54161a Delete the null-bls actor 2021-02-18 19:01:03 -05:00
Łukasz Magiera
0c6aef221d Fix error logging format strings 2021-02-11 12:00:26 +01:00
Łukasz Magiera
56a9d05491 Merge remote-tracking branch 'origin/master' into steb/refactor-consistent-tipset-methods 2021-01-30 12:05:21 +01:00
Raúl Kripalani
d1104fec4c rename blockstores for consistency. 2021-01-29 23:17:25 +00:00
Raúl Kripalani
e02fdf5064 Merge branch 'master' into refactor/lib/blockstore 2021-01-29 21:21:31 +00:00
Raúl Kripalani
b0cbc932bd consolidate all blockstores in blockstore package. 2021-01-29 20:01:00 +00:00
Steven Allen
53271729b6 tweak migration perf 2021-01-28 16:15:23 -08:00
Steven Allen
2f3c912ad9 improve upgrade logging 2021-01-28 16:15:23 -08:00
Steven Allen
a9a65e05d8 feat: avoid computing the tip-set state when looking up addresses 2021-01-27 17:54:42 -08:00
Steven Allen
4890d83acb test: assert that pre-migrations are actually run 2021-01-27 16:12:08 -08:00
Steven Allen
39d4f6780d pre-migration: refactor timing specification
There are now three times:

1. StartWithin: start within X epochs of the upgrade.
2. DontStartWithin: don't start within X epochs of the upgrade.
3. StopWithin: stop within X epochs of the upgrade.
2021-01-27 16:09:07 -08:00
Steven Allen
bceb246080 set worker counts for pre-migrations 2021-01-27 15:47:51 -08:00
Steven Allen
cffeb1a590
fix doc comments
Co-authored-by: Aayush Rajasekaran <arajasek94@gmail.com>
2021-01-27 15:41:26 -08:00
Steven Allen
9574db6d0a log in migration 2021-01-27 15:05:00 -08:00
Steven Allen
9a03c003fe fix sorted test 2021-01-27 13:05:14 -08:00
Steven Allen
56054b0ad3 sort pre-migrations 2021-01-27 12:57:47 -08:00
Steven Allen
854385168d add additional pre-migration validations 2021-01-27 12:57:47 -08:00
Steven Allen
35d6a40071 cleanup pre-migration code a bit 2021-01-27 12:57:17 -08:00
Steven Allen
4072f24bf2 test pre-migrations 2021-01-27 12:57:17 -08:00
Steven Allen
05026a23b9 actually use the temp cache for pre-migrations 2021-01-27 12:57:17 -08:00
Steven Allen
32059d0cbf stmgr: only persist the migration cache on success
Otherwise, we may end up referencing blocks we never wrote to disk.
2021-01-27 12:56:47 -08:00
Steven Allen
b08abc12ba fix error message 2021-01-27 12:55:56 -08:00
Steven Allen
6362887ce3 rename Upgrade to Migration where applicable
This was really confusing.
2021-01-27 12:55:56 -08:00
Steven Allen
77117a0be5 wait for pre-upgrades to exit on stop 2021-01-27 12:55:56 -08:00
Steven Allen
f65d179f2c make pre-migrations async 2021-01-27 12:55:56 -08:00
Steven Allen
8d05c5d62c validate pre-migrations 2021-01-27 12:55:56 -08:00
Steven Allen
8986a2002d wire up re-migration logic for nv10 2021-01-27 12:55:56 -08:00
Steven Allen
8d3cc632ac add support for running pre-migrations and caching their results
This can significantly speedup state migrations.
2021-01-27 12:55:53 -08:00
Steven Allen
f10b13ff32 register v3 methods 2021-01-21 15:21:20 -08:00
Steven Allen
f1719d1e23 mark v3 as expensive 2021-01-21 15:21:20 -08:00
Steven Allen
bf48728875 move winning post proof type logic into a helper 2021-01-21 15:21:20 -08:00
Steven Allen
64e805926f update specs-actors for migration name change
Actors v3 is network version 10.
2021-01-21 15:21:19 -08:00
Aayush Rajasekaran
f6a0da3751 Add the migrationLogger struct 2021-01-21 15:21:19 -08:00
Steven Allen
99ea5b62ea wire up v3 migration 2021-01-21 15:21:19 -08:00
Steven Allen
9d2c430138 remove abstract map constructor/loader
Different maps have different parameters now so we just construct/load them manually where needed.
2021-01-21 15:21:19 -08:00
Steven Allen
8dc49db30d window <-> winning 2021-01-21 15:21:19 -08:00
Steven Allen
c05df6dc1d fix: use the correct proof type in winning proofs 2021-01-21 15:21:19 -08:00
Aayush Rajasekaran
ab90a3b2bc Actors update: MinerInfo.SealProofType has been removed 2021-01-21 15:21:19 -08:00
Aayush Rajasekaran
ba3b32cfe7 Pull in actors v3 2021-01-21 15:21:18 -08:00
Dirk McCormick
827a473391 feat: expose StateSearchMessage on gateway 2021-01-19 11:27:43 +01:00
Łukasz Magiera
22884f18f1 define v9 upgrade 2020-12-19 20:44:21 +01:00
Steven Allen
b8e3808c4f Make state tipset usage consistent in the API
_Always_ (almost) use the tipset's parent state, instead of computing.

Exceptions:

* MinerGetBaseInfo. Fixing this would break things so we need to be
careful (although we could bump the API version, fix it, then fix the call
sites).
* StateReplay. This is replaying a message on top of the given tipset.
* GasEstimateGasLimit. This executes the message on-top-of the tipset's
computed state (unlike call which executes it on the tipset's parent state).
  * Having this method and Call apply the message at different heights is really
  weird.
2020-12-09 11:29:40 -08:00
Dirk McCormick
e02a366419 feat: error out deals that are not activated by proposed deal start epoch 2020-11-30 15:27:40 +01:00
Aayush Rajasekaran
526cd739f6 Return total power when GetPowerRaw doesn't find miner claim 2020-11-20 00:31:04 -05:00
zgfzgf
7b39c3a907 optimize code UpgradeTapeHeight and go fmt 2020-11-19 14:47:13 +08:00
Aayush Rajasekaran
c40c513508
Merge pull request #4862 from filecoin-project/asr/circ-supply
Modify vesting schedule post-calico
2020-11-17 13:32:55 -05:00
Steven Allen
4f33c91f81 fix calico upgrade logic 2020-11-16 19:04:17 +01:00
Steven Allen
948ee53080 add upgrade height where SDR is required 2020-11-16 19:04:13 +01:00
Łukasz Magiera
6bea9dd178 Making sealing logic work with multiple seal proof types 2020-11-16 19:03:30 +01:00
Aayush Rajasekaran
96d56ec096 Modify vesting schedule post-calico 2020-11-15 19:27:45 -05:00
Aayush Rajasekaran
5d9c79811f
Update to actors v2.3.0
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-11-12 18:49:11 +01:00
Łukasz Magiera
3a3270b37c nv7 upgrade: Don't use terminated sectors for winning PoSt 2020-11-09 18:52:10 +01:00
Aayush Rajasekaran
7b8158b1af Update to actors v2.3.0 2020-11-08 16:00:22 -05:00
Aayush Rajasekaran
5ff42505e8 Add a StateDecodeParams method 2020-10-29 22:04:33 -04:00
Steven Allen
f23034305f Handle worker key changes correctly in runtime 2020-10-24 02:57:17 -07:00
Steven Allen
8bb69f1e9c Use pre-computed parent state root for lookback info
There's no need to call TipSetState and recompute it.
2020-10-23 19:40:01 -07:00
Dirk McCormick
92942d44d1 feat: lite-mode - market storage and retrieval clients 2020-10-23 15:02:26 +02:00
Łukasz Magiera
b2510e5fc5
Merge pull request #4508 from filecoin-project/fix/actor-not-found-mininig-base
MinerGetBaseInfo: if miner is not found in lookback, check current
2020-10-22 19:45:43 +02:00
Steven Allen
5e23933757 fix import of v0 for test
We're still on actors v0 in this test.
2020-10-21 12:18:38 -07:00
Steven Allen
bcabe7b3b5 migrate methods to abstracted methods
Method numbers never change anyways. At worst, we'll deprecate old methods and
have to explicitly import them from the correct actors version to use them.
2020-10-21 12:18:37 -07:00
Steven Allen
4e730b5ec8 port to v2 imports 2020-10-21 12:16:23 -07:00
Jakub Sztandera
6530431995
MinerGetBaseInfo: if miner is not found in lookback, check current
If miner is found in current state, just return nil base info as miner
cannot mine if he is not found in the lookback.

Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-10-20 23:54:35 +02:00
Aayush Rajasekaran
556f92a823 Update to actors v2.2.0 at PostLiftoff epoch 2020-10-20 17:23:35 -04:00
Aayush Rajasekaran
89f46cb5cc Make ApplyRet's GasOutputs a pointer, return nil when unused 2020-10-15 21:20:53 -04:00
Aayush Rajasekaran
cb801d47c7 Add GasCost to InvocResult 2020-10-15 18:48:51 -04:00
Łukasz Magiera
22f49f8946
Merge pull request #4366 from zgfzgf/feat-applyblocks-map
optimize map use struct{}
2020-10-15 03:04:57 +02:00
Łukasz Magiera
1350079503
Merge pull request #4353 from zgfzgf/feat-compute-tipSet-state
optimize code use ts.Cids
2020-10-15 03:03:39 +02:00
Aayush Rajasekaran
bf619862c3
Merge pull request #4382 from filecoin-project/asr/invoc-result
Add message CID to InvocResult
2020-10-14 02:06:09 -04:00
Aayush Rajasekaran
ce54110228 Add message CID to InvocResult 2020-10-14 00:06:22 -04:00
Aayush Rajasekaran
458ea277fc Aggregate irregular state transitions into a single EexcutionTrace 2020-10-13 22:59:42 -04:00
Aayush Rajasekaran
7dbc8965be Apply nonces to implicit messages 2020-10-13 22:06:06 -04:00
Aayush Rajasekaran
2426700821 Don't transfer zero FIL during rebalancing fork 2020-10-13 22:06:06 -04:00
Jakub Sztandera
87cd8c6725
Fix off by one tipset in searchBackForMsg
This way we will return the tipset the message was executed in

Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-10-13 17:48:54 +02:00
zgfzgf
1eb2d0ae50 optimize map use struct{} 2020-10-13 22:34:07 +08:00
zgfzgf
07d0b67628 optimize code use ts.Cids 2020-10-13 10:46:41 +08:00
Aayush Rajasekaran
96e1dfd8d7 Add an endpoint for precise circulating supply 2020-10-12 16:38:29 -04:00
Steven Allen
92177b5738 implement tape upgrade
Upgrade to specs-actors v2.1 and network version 5. This fixes the bug where
prove commits were not accepted.
2020-10-12 02:00:27 -04:00
Steven Allen
d84f5dabab remove upgrade invariant checks
These checks may be _too_ strict and could cause the upgrade to fail unnecessarily.
2020-10-09 21:51:58 -07:00
Łukasz Magiera
fdaa9c14ad Merge remote-tracking branch 'origin/master' into feat/signing-backends 2020-10-09 20:36:51 +02:00
Dirk McCormick
767611247c feat: add RPC for StateWaitMsg 2020-10-09 11:45:16 +02:00
Dirk McCormick
00a14de094 feat: gateway - StateLookupID 2020-10-09 11:43:03 +02:00
Dirk McCormick
e19cd9ed01 feat: lotus-lite - replace wallet StateManager with thin client to gateway 2020-10-09 11:43:03 +02:00
Łukasz Magiera
7d2f06cfbd Fix WalletSign in tests 2020-10-09 01:34:48 +02:00
Łukasz Magiera
8783c7434e Merge remote-tracking branch 'origin/master' into feat/signing-backends 2020-10-09 00:50:41 +02:00
Jakub Sztandera
60768f4863
Optimize SearchForMessage and GetReceipt
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-10-08 23:10:06 +02:00
Łukasz Magiera
8dd8892b81 Merge remote-tracking branch 'origin/next' into feat/faster-v2-upgrade 2020-10-08 01:54:29 +02:00
Łukasz Magiera
f9f54819d4 Env var to control v2 actor migration
Env var to control v2 actor migration
2020-10-07 19:41:36 -04:00
Aayush Rajasekaran
d1555106a4 Set actorsv2 upgrade epoch 2020-10-07 19:41:36 -04:00
Steven Allen
d97eb10349 fix spelling nit 2020-10-07 16:32:54 -07:00
Steven Allen
e8253d22c6 only forbid Call* at expensive forks 2020-10-07 16:14:11 -07:00
Steven Allen
1fea550ce5 test that we refuse explicit calls at the migration epochs 2020-10-07 15:33:14 -07:00
Steven Allen
9b7b6146eb construct the new vm with the state manager's vm constructor 2020-10-07 15:31:14 -07:00
Steven Allen
dab1107f5b avoid estimating gas and explicitly calling blocks on fork tipsets
These tipsets can be slow.
2020-10-07 15:31:14 -07:00
Steven Allen
fe912223bd pass an explicit upgrade height to migrations
The tipset height may not be the correct one, given null blocks.
2020-10-07 15:31:12 -07:00
Steven Allen
cca17f6078 fix state tree version in v2 upgrade 2020-10-07 12:04:32 -07:00
Steven Allen
e803cf151f introduce separate state-tree versions
Instead of versioning the state tree along with the actors, version it
separately. This structure may not upgrade every time we update actors.
2020-10-07 12:04:32 -07:00