Repository navigation
Fix whole-lot opening budgets after completed closes - #224
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Whole-lot percent-of-equity orders can be sized from rounded equity even when their exact notional cost exceeds the frozen budget. After a separate close, the general one-lot allowance could admit that unaffordable opening. Apply the existing exact-budget check to both directions and recognize completed internal closes while preserving the closing fill and existing competing-order exclusions.
The fix has no strategy, symbol, or date lookup. The affected Ford 15-minute probe moves from strong to excellent with 100% canonical match and zero P90 entry, exit, PnL, and quantity discrepancy. README records the measured scoreboard and the remaining physical margin-fragment distinction.
Validation: 250 native tests pass; 16 TradingView controls and an unchanged-output Cloud diagnostic establish the budget boundary. The full 4,190-probe comparison yields 4,181 excellent / 9 strong / 0 moderate, with all 704 hard probes unchanged and 4,189 trade CSVs identical. Grading, profiles, input files, feeds, references, and population are unchanged. Independent exact-head review is GREEN.
The README-inclusive Cloud sweep reproduces all 4,190 earlier results. PR gate
pineforge-pr-gate-svv5qis PASS: target score +1, zero hard regressions, no tolerated exceptions, complete coverage. Recorded candidate snapshot:0258370541cfd00acd419f75ef3dc731c531632ed369487167ab92d23eb0f099(788,828 bytes), bound to engine5c2be9d9f2c936b4903fd76c324bd8bdf74876aeand codegenc8ffe587c8fb82435fec34121a93fab2b7018924.