fix(technical): snap missing fib start_date to the date nearest start_date - #7583
Open
Bortlesboat wants to merge 1 commit into
Open
Bortlesboat wants to merge 1 commit into
Bortlesboat wants to merge 1 commit into
Conversation
Collaborator
|
Hi @Bortlesboat, thanks for the PR. Can you please check the #7489 to verify if the issue still exists there? The technical extension has been refactored, so lots of the code has changed upstream. Thanks! |
Contributor
Author
|
Hi @deeleeramone, thanks for the pointer — just re-checked against current The bug is still there: So any |
Bortlesboat
force-pushed
the
fix/fib-start-date-nearest-lookup
branch
from
September 30, 2026 04:04
e4f51dc to
8040ea3
Compare
This branch has not been deployed
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.
Why
When
calculate_fib_levelsreceives a start date outside the price index, it searches for the nearestend_dateinstead. With a Saturday start and an exact trading-day end, both endpoints collapse to the end date and every Fibonacci level has the same price.What
Resolve the missing start date against
start_date. The regression checks that January 6, 2024 snaps to Friday January 5, preserves the requested end date, and produces a nonzero price span.Refreshed against the v5
developtree atbbf1ab20; the regression now lives intests/test_helpers.py.Validation
uv build --no-sources.Validated locally on Windows / Python 3.11. No live provider calls were required.