-
Notifications
You must be signed in to change notification settings - Fork 220
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
sessions.py _get_crumb does not get the crumb, it's empty #181
Comments
@bjosun I’ll check this out over the weekend and see. |
I conducted some testing and encountered an issue with obtaining the cookie from Yahoo using requests. However, I managed to circumvent this issue by manually obtaining the cookie from Chrome and applying it to the request header. This approach worked successfully. Below is the tested code:
|
@JECSand Did you have any progress with it? |
@JECSand @bjosun I've run the code provided and get the following response 200, which is good. So if I understand your question it seems to be working. `Response Headers: Status Code: 200` |
Correct, the snippet works. |
@bjosun can you somehow google that or ask chatgpt to suggest alternate routes, I don't know if response handling will work but hope you figure it out. Let us know |
Seems to be a problem with requests and yahoo finance
response = session.get('https://query2.finance.yahoo.com/v1/test/getcrumb')
response.text is empty. Works in browser where it returns:
<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="s: break-word; white-space: pre-wrap;">CRUMB</pre></body></html>
Is this a user agent issue? Been trying different settings without luck.
The text was updated successfully, but these errors were encountered: