Address review comments
- Add comment to clarify the reason for loop in testkit - Trim common prefix in state printed in CLI commands for better readability - Upgrade to a tagged release of `go-fil-markets` that includes indexing work; see: https://github.com/filecoin-project/go-fil-markets/pull/673 - Fix typo in CLI usage. - Add comments to note that it is safe to use fx `OnStart` context when starting the provider engine. - Fix string concatenation in error message formatting.
This commit is contained in:
@@ -54,6 +54,9 @@ func IndexProvider(cfg config.IndexProviderConfig) func(params IdxProv, marketHo
|
||||
|
||||
args.Lifecycle.Append(fx.Hook{
|
||||
OnStart: func(ctx context.Context) error {
|
||||
// Note that the OnStart context is cancelled after startup. Its use in e.Start is
|
||||
// to start up gossipsub publishers and restore cache, all of which are completed
|
||||
// before e.Start returns. Therefore, it is fine to reuse the give context.
|
||||
if err := e.Start(ctx); err != nil {
|
||||
return xerrors.Errorf("starting indexer provider engine: %w", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user