-
Notifications
You must be signed in to change notification settings - Fork 138
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
Don't get Ticker.history dataframe at time of market open. #210
Comments
Looking through my logs I see that the premarket change percent and market change percent are coming through, but are blocked after a certain number of tries. Most likely it is rate limited. However the volume issue is persistent on every call. |
Is seriously nobody else having this problem? Nothing else in my code has changed but the yahoo query version. I have now finally tried rotating proxies and still have same issue. I either get a empty dataframe or I get one row that has a "0" for volume value. Ex: Ex: 2023-07-25 08:36:10.354911 This is how I call it: now_adj is todays datestock = Ticker(stock_1, retry=40, status_forcelist=[404, 429, 500, 502, 503, 504], I find it difficult to believe that nobody is having this issue. |
Hi @quikksilver1, I'm struggling to understand this issue. With respect to Ideally enclose the code part in the following way: from yahooquery import Ticker
# your example here |
Certainly, the issue is when I call the Ticker.history function between the hrs of 8:30am to 9am Central time. I either get a empty dataframe or a dataframe that contains only one row. "stock_1" is a list of stocks that I iterate through. The list changes daily. Here is how I call it
''' or I get 1 row that has a 0 for the volume. (Showing that that was the last row in the dataframe): If run my code later in the day, I get the correct dataframe, but I need to run my code in the first 30 minutes of market opening. Thank you for trying to help. |
dude, that's not minimal Could you cut your example down to a bare minimum of code under which the issue reproduces. |
I couldn't fix it so I ended up getting the data through yfinance. |
One hack I used is to pass "daily" to _get_daily_index and override with keep_live_indice = False def _get_daily_index(data, index_utc, adj_timezone, daily=False): line 1482 ...just a thought |
I run my code between the hours of 8:30-9am CDT.
Using windows 11
yahooquery==2.3.2
I switched to 2.3.2 after getting "Invalid Cookie" error
python 3.11.3
Expected behavior
Here is an example of when I run the code after I get home.
Screenshots
If applicable, add screenshots to help explain your problem.
The text was updated successfully, but these errors were encountered: