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

I couldn't download stocks #43

Closed
kismp123 opened this issue Apr 21, 2018 · 8 comments
Closed

I couldn't download stocks #43

kismp123 opened this issue Apr 21, 2018 · 8 comments
Assignees
Labels

Comments

@kismp123
Copy link

root@bad:~# YahooTickerDownloader.py stocks
Checking if we can resume a old download session
Downloader found on disk, resuming
Downloading stocks


req https://finance.yahoo.com/_finance_doubledown/api/resource/finance.yfinlist.symbol_lookup;p=1;s=a;b=0;m=all;t=S?device=console&returnMeta=true
Retry attempt: 1. Sleep period: 5 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/finance.yfinlist.symbol_lookup;p=1;s=a;b=0;m=all;t=S?device=console&returnMeta=true
Retry attempt: 2. Sleep period: 25 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/finance.yfinlist.symbol_lookup;p=1;s=a;b=0;m=all;t=S?device=console&returnMeta=true
Retry attempt: 3. Sleep period: 125 seconds.

I think that url does not work.
That response is below.
{"output":{"message":"Not Found"},"meta":{}}

Thank you

@Benny- Benny- added the bug label Apr 21, 2018
@Benny-
Copy link
Owner

Benny- commented Apr 21, 2018

Yes! You are right. The API probably changed.

@Benny- Benny- self-assigned this Apr 21, 2018
@Benny-
Copy link
Owner

Benny- commented Apr 29, 2018

I looked a bit around on google finance and could not find a GUI to list symbols using a search string. It could be they (re)moved it. If it is removed this utility can't do it's job and is rendered useless. If anyone known of a api to find a list of stocks please say so.

@Benny-
Copy link
Owner

Benny- commented Apr 29, 2018

So basically the unofficial Yahoo API broke, and I'm not yet sure if there is a replacement.

@Benny-
Copy link
Owner

Benny- commented May 7, 2018

This is great! Do you know where this api is used, @jharker ? If it supports pagination this will be a suitable replacement.

@jharker
Copy link
Contributor

jharker commented May 20, 2018

Hi, @Benny- Yup, the API is used by the "Symbol Lookup" tool on this page:

https://finance.yahoo.com/lookup/

But unfortunately, from what I can tell it doesn't support pagination. Still, it seems like it should be possible to use this to pull symbols in groups of ten or less using a few modifications to the search algorithm you're already using. I'll see if I have time to give it a shot in the next week or so.

@jharker
Copy link
Contributor

jharker commented May 26, 2018

Hi, @Benny- I created a pull request that implements the new Yahoo API. You may want to modify this to be more seamlessly integrated into the old code -- I didn't want to rip too much out of the existing code so I created some parallel functionality instead.

I've tested this over the past few days and it works pretty well. I wish there was a way to make it more efficient in terms of the number of API calls, but with the API results set apparently limited to 10 and not paginated, I can't figure out a way to do it more efficiently than this.

https://github.com/Benny-/Yahoo-ticker-symbol-downloader/pull/44

@Benny-
Copy link
Owner

Benny- commented May 26, 2018

I ran it and I'm am quite impressed with the results so far. It got 84464 unique results so far.

Exporting still works and considering the other API did not work anymore I've published this right now as 3.0.0. This new version gives a lot of random 404 error from Yahoo, this is logged as #45.

@Benny- Benny- closed this as completed May 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants