hook a great context in the sky to satisfy DI; sigh...

This commit is contained in:
vyzo 2021-12-14 16:57:09 +02:00
parent eb48dc9b68
commit 716b4a3b09

View File

@ -161,6 +161,12 @@ func defaults() []Option {
}),
Override(new(dtypes.ShutdownChan), make(chan struct{})),
// the great context in the sky, otherwise we can't DI build genesis; there has to be a better
// solution than this hack.
Override(new(context.Context), func(lc fx.Lifecycle, mctx helpers.MetricsCtx) context.Context {
return helpers.LifecycleCtx(mctx, lc)
}),
}
}