Repository navigation
fix: session filter, short weight cap, futures multiplier in cash checks, CAGR overflow - #129
Merged
Merged
Conversation
CME-style sessions open on the calendar day before their session date. The filter expanded the schedule start but not the end, so a bar on that open was removed whenever the frame's latest UTC date was still the prior day. Co-authored-by: quantum-like <[email protected]>
min() only upper-bounds a weight, so a short target more negative than the configured cap was left unchanged. Apply the cap as a magnitude limit. Co-authored-by: quantum-like <[email protected]>
The open cash check treated notional as price times quantity and then skipped the gatekeeper. A one-lot futures buy could fill and drive cash negative. Scale the projected debit by the contract multiplier. Co-authored-by: quantum-like <[email protected]>
Sequential fills treat a reserved order as already validated and skip the gatekeeper. The shadow reserved price times quantity, so a futures order could fill for many times the reserved cash. Reserve price times quantity times multiplier. Co-authored-by: quantum-like <[email protected]>
A one-minute equity gain made (final/initial) ** (1/years) exceed the float range and raise OverflowError while assembling run metrics. Return infinity for that overflow and leave finite windows unchanged. Co-authored-by: quantum-like <[email protected]>
(cherry picked from commit 45ba846)
(cherry picked from commit 6f810d1)
(cherry picked from commit d771ff5)
…d claims (cherry picked from commit 2d5c37f)
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.
Owning issue
Closes #128
Outcome
Preserves the original contributor's five commits and corrects the four independently reproduced behaviors:
The maintainer completion adds public Engine regressions and genuinely regenerated synthetic, frozen-input native and performance evidence. It also fixes the benchmark producer's empty Linux processor field, which prevented a valid measurement report from passing its validator. That two-file dependency repair has its own failing-base/passing-fix regression; it changes no timed engine call.
Each numerical change was reproduced and reviewed independently. This retains the existing accepted issue/PR and original attribution while completing the evidence needed to accept the submitted repair tree. It introduces no unrelated policy, migration or shared comparison-extra changes.
Base/fix behavior
Public workflows failed on the pre-fix main and passed on the corresponding repairs:
The original focused regression names remain in the contributor commits. Added end-user futures checks are in tests/futures/test_cash_multiplier_engine.py. The producer regression uses the actual build_report and report_failures functions with retained measurement samples solely to isolate host metadata; it does not fabricate a timing run.
Verification
Selected head
574f34b4785d7b006d0172fc49ae01b3a54cfb8fincorporates main132c349bd23a7323da9c2540dd44943305badaa8without rewriting the contributor's history. All hooks, 304 focused correctness/report tests, generated claims and diff checks pass. The engine, producer and retained report files match the qualified integration exactly. Both the owner backup branch and this existing contributor PR branch were pushed normally and verified with ls-remote. Current-head hosted qualification is pending.Earlier full local qualification at maintainer completion
de390181aae4c0647cd3595b1ac57b07ec7b6c2e:The completed source tree has exactly the same engine, producer, adapter and retained report files as the separately qualified integration tree:
bc83aab413d63c02fb16b48390db161d239bd490: all 17 required framework/workload pairs passed, eight unsupported.d771ff5608bb1c5e5977c8fb32f8afeeab33cd04: one warmup and ten isolated samples per side for all 17 pairs. All 34 measured output SHA256 sets were independently matched to the actual retained correctness files. The reports retain their real generating revisions; no pins were manually relabeled.a949116d19b51cfc8ff4d296661f4fc924679fd0: reproducible wheel/sdist, metadata checks, installed-wheel marked examples, Diagnostic 0.1.4 handoff/results and representative installed-wheel consumer typing passed.Final automatically triggered supported Python/OS CI and package gates must pass at the selected PR head before merge. Local integration evidence does not replace that exact-head hosted qualification.
Compatibility and limits
Outputs change in the specific corrected cases above. Consumers serializing extreme annualized metrics must handle nonfinite CAGR. The comparisons apply only to their retained framework builds, inputs and explicit settings; they do not establish universal framework equivalence or correctness of every strategy.
AI assistance
The original functional commits were authored by Cursor Agent with quantum-like credited as co-author. Codex reproduced and independently assessed the changes, preserved the original history, added the public Engine and metadata regressions, generated and checked the actual evidence, and drafted this description. These are agent-run checks; no independent human review is asserted.
Release
Recommend a patch release after accepted main passes full release gates. This PR does not authorize a release, tag, PyPI publication or documentation deployment.