Documentation ¶
Index ¶
- Variables
- func CarWalkFunc(nd format.Node) (out []*format.Link, err error)
- func ComputeVRF(ctx context.Context, sign SignFunc, worker address.Address, sigInput []byte) ([]byte, error)
- func IsRoundWinner(ctx context.Context, round abi.ChainEpoch, miner address.Address, ...) (*types.ElectionProof, error)
- type ChainGen
- func (cg *ChainGen) Banker() address.Address
- func (cg *ChainGen) BeaconSchedule() beacon.Schedule
- func (cg *ChainGen) Blockstore() blockstore.Blockstore
- func (cg *ChainGen) ChainStore() *store.ChainStore
- func (cg *ChainGen) Genesis() *types.BlockHeader
- func (cg *ChainGen) GenesisCar() ([]byte, error)
- func (cg *ChainGen) NextTipSet() (*MinedTipSet, error)
- func (cg *ChainGen) NextTipSetFromMiners(base *types.TipSet, miners []address.Address, nulls abi.ChainEpoch) (*MinedTipSet, error)
- func (cg *ChainGen) NextTipSetFromMinersWithMessagesAndNulls(base *types.TipSet, miners []address.Address, msgs [][]*types.SignedMessage, ...) (*store.FullTipSet, error)
- func (cg *ChainGen) NextTipSetWithNulls(nulls abi.ChainEpoch) (*MinedTipSet, error)
- func (cg *ChainGen) ResyncBankerNonce(ts *types.TipSet) error
- func (cg *ChainGen) SetStateManager(sm *stmgr.StateManager)
- func (cg *ChainGen) SetWinningPoStProver(m address.Address, wpp WinningPoStProver)
- func (cg *ChainGen) StateManager() *stmgr.StateManager
- func (cg *ChainGen) Wallet() *wallet.LocalWallet
- func (cg *ChainGen) YieldRepo() (repo.Repo, error)
- type MinedTipSet
- type MiningCheckAPI
- type SignFunc
- type WinningPoStProver
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultRemainderAccountActor = genesis.Actor{ Type: genesis.TMultisig, Balance: big.NewInt(0), Meta: remAccMeta.ActorMeta(), }
View Source
var DefaultVerifregRootkeyActor = genesis.Actor{ Type: genesis.TMultisig, Balance: big.NewInt(0), Meta: rootkeyMultisig.ActorMeta(), }
View Source
var ValidWpostForTesting = []proof7.PoStProof{{ ProofBytes: []byte("valid proof"), }}
Functions ¶
func ComputeVRF ¶
func IsRoundWinner ¶
func IsRoundWinner(ctx context.Context, round abi.ChainEpoch, miner address.Address, brand types.BeaconEntry, mbi *api.MiningBaseInfo, a MiningCheckAPI) (*types.ElectionProof, error)
Types ¶
type ChainGen ¶
type ChainGen struct { CurTipset *store.FullTipSet Timestamper func(*types.TipSet, abi.ChainEpoch) uint64 GetMessages func(*ChainGen) ([]*types.SignedMessage, error) // Set to false to allow the chain to advance without updating the state-tree (e.g., this // allows one to keep the power without having to post). AdvanceState bool Miners []address.Address // contains filtered or unexported fields }
func NewGenerator ¶
func NewGeneratorWithSectors ¶ added in v0.3.0
func NewGeneratorWithSectorsAndUpgradeSchedule ¶ added in v1.10.0
func NewGeneratorWithSectorsAndUpgradeSchedule(numSectors int, us stmgr.UpgradeSchedule) (*ChainGen, error)
func NewGeneratorWithUpgradeSchedule ¶ added in v1.10.0
func NewGeneratorWithUpgradeSchedule(us stmgr.UpgradeSchedule) (*ChainGen, error)
func (*ChainGen) BeaconSchedule ¶ added in v1.12.0
func (*ChainGen) Blockstore ¶ added in v1.13.0
func (cg *ChainGen) Blockstore() blockstore.Blockstore
func (*ChainGen) ChainStore ¶ added in v0.2.8
func (cg *ChainGen) ChainStore() *store.ChainStore
func (*ChainGen) Genesis ¶
func (cg *ChainGen) Genesis() *types.BlockHeader
func (*ChainGen) GenesisCar ¶
func (*ChainGen) NextTipSet ¶
func (cg *ChainGen) NextTipSet() (*MinedTipSet, error)
func (*ChainGen) NextTipSetFromMiners ¶
func (cg *ChainGen) NextTipSetFromMiners(base *types.TipSet, miners []address.Address, nulls abi.ChainEpoch) (*MinedTipSet, error)
func (*ChainGen) NextTipSetFromMinersWithMessagesAndNulls ¶ added in v1.10.0
func (cg *ChainGen) NextTipSetFromMinersWithMessagesAndNulls(base *types.TipSet, miners []address.Address, msgs [][]*types.SignedMessage, nulls abi.ChainEpoch) (*store.FullTipSet, error)
func (*ChainGen) NextTipSetWithNulls ¶ added in v1.12.0
func (cg *ChainGen) NextTipSetWithNulls(nulls abi.ChainEpoch) (*MinedTipSet, error)
func (*ChainGen) ResyncBankerNonce ¶
ResyncBankerNonce is used for dealing with messages made when simulating forks
func (*ChainGen) SetStateManager ¶ added in v0.2.8
func (cg *ChainGen) SetStateManager(sm *stmgr.StateManager)
func (*ChainGen) SetWinningPoStProver ¶ added in v0.5.0
func (cg *ChainGen) SetWinningPoStProver(m address.Address, wpp WinningPoStProver)
func (*ChainGen) StateManager ¶ added in v0.5.0
func (cg *ChainGen) StateManager() *stmgr.StateManager
func (*ChainGen) Wallet ¶ added in v0.2.8
func (cg *ChainGen) Wallet() *wallet.LocalWallet
type MinedTipSet ¶
type MinedTipSet struct { TipSet *store.FullTipSet Messages []*types.SignedMessage }
type MiningCheckAPI ¶
type MiningCheckAPI interface { StateGetRandomnessFromBeacon(ctx context.Context, personalization crypto.DomainSeparationTag, randEpoch abi.ChainEpoch, entropy []byte, tsk types.TipSetKey) (abi.Randomness, error) StateGetRandomnessFromTickets(ctx context.Context, personalization crypto.DomainSeparationTag, randEpoch abi.ChainEpoch, entropy []byte, tsk types.TipSetKey) (abi.Randomness, error) MinerGetBaseInfo(context.Context, address.Address, abi.ChainEpoch, types.TipSetKey) (*api.MiningBaseInfo, error) WalletSign(context.Context, address.Address, []byte) (*crypto.Signature, error) }
type WinningPoStProver ¶ added in v0.3.0
type WinningPoStProver interface { GenerateCandidates(context.Context, abi.PoStRandomness, uint64) ([]uint64, error) ComputeProof(context.Context, []proof7.ExtendedSectorInfo, abi.PoStRandomness, abi.ChainEpoch, network.Version) ([]proof7.PoStProof, error) }
Click to show internal directories.
Click to hide internal directories.