Commit Graph
2 Commits
Author SHA1 Message Date
dennisthiessenandClaude Opus 4.8 1155c9ed1b Shorten alembic revision ids to fit version_num VARCHAR(32)
Deploy / lint (push) Successful in 7s
Deploy / test (push) Successful in 1m29s
Deploy / deploy (push) Successful in 42s
The deploy's `alembic upgrade head` failed at 016->017 with
StringDataRightTruncationError: the revision id
"017_add_trade_setup_strategy_rank" is 33 chars, but Postgres's
alembic_version.version_num is VARCHAR(32). Offline/SQLite checks don't
enforce the length, so this only surfaced against prod Postgres.

Rename the revision ids to the repo's short numeric convention (017, 018);
descriptive filenames are kept. down_revision links updated to match.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-04 08:17:10 +02:00
dennisthiessenandClaude Opus 4.8 cfca59a2d4 Fix migration chain and clear stored paper exit mode
Deploy / lint (push) Failing after 9s
Deploy / test (push) Has been skipped
Deploy / deploy (push) Has been skipped
Migration 017 set down_revision to "016_add_signal_context_snapshots",
but migration 016's revision id is "016", so `alembic upgrade head` could
not resolve the chain and the deploy's auto-alembic step would fail. Point
017 at the real id "016".

Add migration 018 to delete any persisted `paper_exit_mode` row. The July
2026 promotion changed the paper-trade exit default to `atr_trailing`, but
`get_exit_policy` reads a stored value before the code default, so an
environment that had ever saved the old `time` mode would silently keep it
and never run the promoted 3x ATR trailing exit. Mirrors migration 015's
one-way settings reset.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-04 08:05:32 +02:00