Lint rules
negative-shift
.shift({n}) moves a later bar's value onto an earlier bar. Use a number of bars back, 0 or more.
centred-window
A centred window reads bars after the one it is placed on.
unseeded-random
This random source is not seeded, so two runs differ. Use ctx.rng in hooks, or numpy.random.default_rng(seed) with a fixed seed.
mode-branch
This code depends on the run mode. If it changes trading, a backtest and a live run trade differently.
last-row-in-compute
{expr} reads the last bar of the whole history, which is later than most bars it decides on.
whole-series-aggregate
{expr} uses every bar, including later ones. Use a trailing window such as forge.series.rolling.
fit-full-history
A model is fitted on the whole history inside compute(), so early bars learn from later ones.
reversed-series
Reversing a series before a running calculation lets early bars read later ones.
module-state
A module-level {name} is changed by strategy code, so results depend on what ran before.