Fix 7 bugs found in full online testing; 89/89 tests green, 0 skips
openhands+1: openhands
1f64f81
Model layer:
- TimesFM: restore corrupted else: branch so the covariates path returns
the forecast, not the backcast; unify point_values across both paths
- TimesFM: right-size compiled max_context per input length
(_ensure_compiled_for) — timesfm 3.0.2's compiled decode NaNs whenever
zero-padding exceeds ~1 patch (short windows); recompiles on every
length change, not just upward
- All 5 models: shared validate_history_and_horizon() guard now rejects
NaN history and horizon < 1 with a clean ValueError naming the model
UI layer (both tabs previously crashed on EVERY use on the Space):
- Live tab: write predicted_at/target_time as ISO strings — gr.State JSON
round-trips and cannot serialize pd.Timestamp
- Backtest tab: emit datetime as ISO strings — gr.Dataframe serialization
Data layer:
- Replace dead default ticker MATIC-USD (Polygon delisted; verified no
Yahoo data under MATIC/POL/POL1/POL.X) with LINK-USD; all 20 defaults
now fetch
Tests: 87 -> 89, zero skips (was…
Root-cause debug showed 1-bar hold plus a fixed 1% TP/SL forced most forex
intraday trades into tiny time-exits (then costs), and did not invent a 60%
win rate. Filters and ATR levels are causal, off by default, and reported
honestly. No fake accuracy.