polish(statetree): accept a context in statetree diff for timeouts
- this operation can take a while, this changes gives users the option to abort if it takes "too long".
This commit is contained in:
@@ -705,7 +705,7 @@ func (a *StateAPI) StateChangedActors(ctx context.Context, old cid.Cid, new cid.
|
||||
return nil, xerrors.Errorf("failed to load new state tree: %w", err)
|
||||
}
|
||||
|
||||
return state.Diff(oldTree, newTree)
|
||||
return state.Diff(ctx, oldTree, newTree)
|
||||
}
|
||||
|
||||
func (a *StateAPI) StateMinerSectorCount(ctx context.Context, addr address.Address, tsk types.TipSetKey) (api.MinerSectors, error) {
|
||||
|
||||
Reference in New Issue
Block a user