Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix start date on history #1576

Merged
merged 1 commit into from
Jun 27, 2023
Merged

fix start date on history #1576

merged 1 commit into from
Jun 27, 2023

Conversation

lucas03
Copy link
Contributor

@lucas03 lucas03 commented Jun 26, 2023

ticker.basic_info["last_price"]

sometimes raises:

GDEVW: 1d data not available for startTime=-2208994789 and endTime=1687780922. Only 100 years worth of day granularity data are allowed to be fetched per request.

@lucas03 lucas03 changed the base branch from main to dev June 26, 2023 14:56
@lucas03 lucas03 changed the base branch from dev to main June 26, 2023 14:56
@ValueRaider
Copy link
Collaborator

To merge into dev you first need to branch off dev, otherwise commit log gets messy as you saw.

Run a floor or ceil on max start, it will help with cache reuse.

@lucas03 lucas03 changed the base branch from main to dev June 26, 2023 16:12
@lucas03
Copy link
Contributor Author

lucas03 commented Jun 26, 2023

To merge into dev you first need to branch off dev

updated

Run a floor or ceil on max start, it will help with cache reuse.

how come? I thought int( does that.

EDIT: oh, it's not good enough

@ValueRaider
Copy link
Collaborator

ValueRaider commented Jun 26, 2023

I neglected argument - floor('D') or ceil('D') - round to midnight. If stuck look for other examples in yfinance

timestamp of 1900 is older than 100 years,
so yahoo responds with error:

GDEVW: 1d data not available for startTime=-2208994789 and
endTime=1687780922. Only 100 years worth of day granularity data are
allowed to be fetched per request.

this should fix it,
something similar was proposed here:
#648

 # Please enter the commit message for
your changes. Lines starting
@lucas03
Copy link
Contributor Author

lucas03 commented Jun 26, 2023

thanks, updated

@ValueRaider ValueRaider merged commit 711e113 into ranaroussi:dev Jun 27, 2023
@ValueRaider
Copy link
Collaborator

ValueRaider commented Jul 2, 2023

I just noticed the docstrings still say default is 1900. Can you update? Wiki too.

@lucas03
Copy link
Contributor Author

lucas03 commented Jul 2, 2023

new pull request I guess, right?

@ValueRaider
Copy link
Collaborator

Yup, can't modify a merged PR.

@lucas03
Copy link
Contributor Author

lucas03 commented Jul 6, 2023

@ValueRaider
Copy link
Collaborator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants