GithubHelp home page GithubHelp logo

benny- / yahoo-ticker-symbol-downloader Goto Github PK

View Code? Open in Web Editor NEW
244.0 244.0 87.0 747 KB

A web scraper for ticker symbols from yahoo finance

Home Page: https://pypi.python.org/pypi/Yahoo-ticker-downloader/

License: Other

Python 100.00%
exchange-web-services finance python yahoo-finance-api

yahoo-ticker-symbol-downloader's People

Contributors

aidan-n avatar alanbertadev avatar algonell avatar benny- avatar istzustand avatar jharker avatar kamgha avatar mgiustiniani avatar revenazb avatar totallybullshit avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

yahoo-ticker-symbol-downloader's Issues

Request session is pickled

A requests.Session() is pickled. This might cause problems if the request module is upgraded.

It should not be pickled.

I couldn't download stocks

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

Error 404

I have tried to download the stocks symbol and the currency but i am getting this error. It seems that the url adresss change.

Traceback (most recent call last):
File "C:\Users\myname\AppData\Local\Programs\Python\Python35\Scripts\YahooTickerDownloader.py", line 161, in
main()
File "C:\Users\myname\AppData\Local\Programs\Python\Python35\Scripts\YahooTickerDownloader.py", line 111, in main
downloadEverything(downloader, tickerType, args.insecure, args.sleep, args.pandantic)
File "C:\Users\myname\AppData\Local\Programs\Python\Python35\Scripts\YahooTickerDownloader.py", line 50, in downloadEverything
symbols = downloader.nextRequest(insecure, pandantic)
File "c:\users\myname\appdata\local\programs\python\python35\lib\site-packages\ytd\SymbolDownloader.py", line 113, in nextRequest
html = self._fetchHtml(insecure)
File "c:\users\myname\appdata\local\programs\python\python35\lib\site-packages\ytd\SymbolDownloader.py", line 56, in _fetchHtml
resp.raise_for_status()
File "c:\users\myname\appdata\local\programs\python\python35\lib\site-packages\requests\models.py", line 909, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: Not Found for url: https://finance.yahoo.com/lookup/C?m=ALL&s=a&t=C&bypass=true&b=0

Searchterms in null

From #50 :

Saving downloader to disk...
Downloader successfully saved.

req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 1 of 5. Sleep period: 5 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 2 of 5. Sleep period: 25 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 3 of 5. Sleep period: 125 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 4 of 5. Sleep period: 625 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 5 of 5. Sleep period: 3125 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
A exception occurred while downloading. Suspending downloader to disk
Successfully saved download state
Try removing {type}.pickle file if this error persists
Issues can be reported on https://github.com/Benny-/Yahoo-ticker-symbol-downloader/issues

Traceback (most recent call last):
File "/home/mountainers/.local/bin/YahooTickerDownloader.py", line 170, in
main()
File "/home/mountainers/.local/bin/YahooTickerDownloader.py", line 111, in main
downloadEverything(downloader, tickerType, args.insecure, args.sleep, args.pandantic)
File "/home/mountainers/.local/bin/YahooTickerDownloader.py", line 40, in downloadEverything
symbols = downloader.nextRequest(insecure, pandantic)
File "/home/mountainers/.local/lib/python3.6/site-packages/ytd/SimpleSymbolDownloader.py", line 95, in nextRequest
json = self._fetch(insecure)
File "/home/mountainers/.local/lib/python3.6/site-packages/ytd/SimpleSymbolDownloader.py", line 65, in _fetch
resp.raise_for_status()
File "/home/mountainers/.local/lib/python3.6/site-packages/requests/models.py", line 940, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 503 Server Error: Service Unavailable for url: https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true

Parse error when parsing stocks.pickle file

Hi, first of all thanks for this utility. It is pretty damn useful and easy to use. I am getting a parse error when generating CSV file from the PICKLE file. Please see the logs below.

Logs:

Checking if we can resume a old download session
Downloader found on disk, resuming
The downloader has already finished downloading everything

Exporting Stock symbols
Traceback (most recent call last):
File "/usr/local/bin/YahooTickerDownloader.py", line 5, in
pkg_resources.run_script('Yahoo-ticker-downloader==0.8.1', 'YahooTickerDownloader.py')
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources.py", line 492, in run_script
self.require(requires)[0].run_script(script_name, ns)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources.py", line 1357, in run_script
exec_(script_code, namespace, namespace)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources.py", line 47, in exec_
exec("""exec code in globs, locs""")
File "", line 1, in
File "/Library/Python/2.7/site-packages/Yahoo_ticker_downloader-0.8.1-py2.7.egg/EGG-INFO/scripts/YahooTickerDownloader.py", line 147, in

File "/Library/Python/2.7/site-packages/Yahoo_ticker_downloader-0.8.1-py2.7.egg/EGG-INFO/scripts/YahooTickerDownloader.py", line 135, in main

UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 3593: ordinal not in range(128)
xxx-MacBook-Pro:Yahoo-ticker-symbol-downloader-master xxx$

Please let me know if you need any other information.

download stock info error

Traceback (most recent call last):
File "D:\Anaconda3\Scripts\YahooTickerDownloader.py", line 161, in
main()
File "D:\Anaconda3\Scripts\YahooTickerDownloader.py", line 111, in main
downloadEverything(downloader, tickerType, args.insecure, args.sleep, args.p
andantic)
File "D:\Anaconda3\Scripts\YahooTickerDownloader.py", line 50, in downloadEver
ything
symbols = downloader.nextRequest(insecure, pandantic)
File "D:\Anaconda3\lib\site-packages\ytd\SymbolDownloader.py", line 113, in ne
xtRequest
html = self._fetchHtml(insecure)
File "D:\Anaconda3\lib\site-packages\ytd\SymbolDownloader.py", line 56, in _fe
tchHtml
resp.raise_for_status()
File "D:\Anaconda3\lib\site-packages\requests\models.py", line 893, in raise_f
or_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: Not Found for url: https://fina
nce.yahoo.com/lookup/E?s=a&t=E&m=ALL&b=0&bypass=true

Which markets are included? Fail to build reppy dependecy on OSX

Hi Benny, thanks for your script.
I have the same issues while installing reppy and I used the old version of yahoo ticker download as I read in other post.

I would like to ask you if the script in Europe is limited to germany and france?
Would it be possible to download more EU countries?? Spain, Italy, Portugal, Netherlands, Belgium, Finland, Austria for instance?

Thanks a lot!

Unclear how to get csv format

I was confused when I saw that the output that I ended up with was a .pickle object, because the description of the package said that it outputs .json, .yaml and .xls files in addition to .csv. I ended up reading the pickle object into python and doing some data manipulation to get it out as a .csv. Is there another way to go about it?

import pandas as pd
import numpy as np

ytd = pickle.load(open('stocks.pickle', 'rb'))
names = ytd.symbols.keys()
namesarr = numpy.asarray(names)
df = pd.DataFrame(namesarr,columns=['ticker'])
df.to_csv('stocks.csv')

Export not working for excel nor yaml, but for json

Hi,

I keep receiving this message when doing
python YahooTickerDownloader.py -e
Exporting generic symbols
Could not export .xlsx due to a internal error

Do you know what could be causing this issue?

thanks

Program ends with exception

Hi,

I typed YahooTickerDownloader.py without any options, it ran for some time and then logged with the following exception:

Got 0 downloaded generic symbols:
Progress: Query 2719/41750.
16124 unique generic entries collected so far.

req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=ek7?device=console&returnMeta=true
Got 8 downloaded generic symbols:
Got 8 downloaded generic symbols:
A exception occurred while downloading. Suspending downloader to disk
Successfully saved download state
Try removing {type}.pickle file if this error persists
Issues can be reported on https://github.com/Benny-/Yahoo-ticker-symbol-downloader/issues

Traceback (most recent call last):
File "C:\ProgramData\Anaconda3\envs\ml_finance\Scripts\YahooTickerDownloader.py", line 170, in
main()
File "C:\ProgramData\Anaconda3\envs\ml_finance\Scripts\YahooTickerDownloader.py", line 111, in main
downloadEverything(downloader, tickerType, args.insecure, args.sleep, args.pandantic)
File "C:\ProgramData\Anaconda3\envs\ml_finance\Scripts\YahooTickerDownloader.py", line 41, in downloadEverything
print("Got " + str(len(symbols)) + " downloaded " + downloader.type + " symbols:")
OSError: raw write() returned invalid length 70 (should have been between 0 and 35)

UnicodeEncodeError

First of all, thank you so much for developing this great tool. There is simply no other tools that do it better and simpler. As I use it to download symbols, I notice that it sometimes yields errors such as

UnicodeEncodeError: 'ascii' codec can't encode character '\xe9' in position 30: ordinal not in range(128)

That leads me to another question: if I finish the first batch run of the downloader, meaning all queries are done once, can I simply run it again and hope that it can pick up those missing ones?

Hostname doesn't match

I'm getting the following Traceback when I run the script

Traceback (most recent call last): File "c:/Python27/Scripts/YahooTickerDownloader.py", line 144, in <module> main() File "c:/Python27/Scripts/YahooTickerDownloader.py", line 101, in main downloadEverything(downloader, tickerType, args.insecure) File "c:/Python27/Scripts/YahooTickerDownloader.py", line 46, in downloadEverything symbols = downloader.nextRequest(insecure) File "c:\python27\lib\site-packages\ytd\SymbolDownloader.py", line 88, in nextRequest html = self._fetchHtml(insecure) File "c:\python27\lib\site-packages\ytd\SymbolDownloader.py", line 40, in _fetchHtml resp = self.rsession.send(req) File "c:\python27\lib\site-packages\requests\sessions.py", line 576, in send r = adapter.send(request, **kwargs) File "c:\python27\lib\site-packages\requests\adapters.py", line 447, in send raise SSLError(e, request=request) requests.exceptions.SSLError: hostname 'finance.yahoo.com' doesn't match u'www.yahoo.com'

I'm not sure why it tries to match finance.yahoo.com with u'www.yahoo.com'. It obviously shouldn't match and I haven't been able to debug it.

a little suggestion

Hi.
I'm new to this git and programming stuff, so please bear with me :)

if I query stocks I'm getting 22049 symbols from 9 exchanges. Since I'd love to have more I fiddled a bit around and got your tool to get 28094 symbols from 66 exchanges.

All I had to do was in the ytd/SymbolDownloader.py add " 'm' : 'all' " to params.

This now enables me to filter for stocks which are traded e.g. in Frankfurt which I find awesome ;)

dunno if you want to drop that line but I thought I'd share my idea (:

edith says: I'll try this branching and pull request stuff... let"s see...
edit2: I made a mistake. I was formerly pulling from de.finance.yahoo. Now back at finance.yahoo I get 105539 stocks from 69 exchanges. Still about 9k missing.

Yahoo returns funny things sometimes

Compare the following two HTML files:
https://bennyjacobs.nl/issues/yahoo-finance/A1.html
https://bennyjacobs.nl/issues/yahoo-finance/A2.html

Both can be returned when fetching https://finance.yahoo.com/lookup/M?bypass=true&s=ma&b=148&m=ALL&t=m

Something like A1.html is returned sometimes. Its content is absolutely funny. It lists at item offset 148 while at the same item telling there are only 56 items in the list. And it lists totally different items.

This corrupts the results between runs. And one point you might have a few more results while another time you have a few less.

Here is another pair of HTML files:
https://bennyjacobs.nl/issues/yahoo-finance/B1.html
https://bennyjacobs.nl/issues/yahoo-finance/B2.html
Both returned by fetching https://finance.yahoo.com/lookup/B?s=c&b=360&m=ALL&t=B&bypass=true

At the moment I have no solution.

'too few arguments'

Python 2.7 Anaconda
Step by step install using pip
run: YahooTickerDownloader.py stocks
error: "YahooTickerDownloader.py: error: too few arguments"

Can't download the ticker list

Hi,

I am receiveing the following error when I try to get the ticker symbols data:

╭─[email protected] ~  
╰─➤  YahooTickerDownloader.py stocks                                                                        1 ↵
Checking if we can resume a old download session
Downloader found on disk, resuming
Downloading Stock

req https://finance.yahoo.com/lookup/?s=a&r=&m=ALL&t=S&b=0
A exception occurred while downloading. Suspending downloader to disk
Successfully saved download state
Remove downloader.pickle if this error persists
Issues can be reported on https://github.com/Benny-/Yahoo-ticker-symbol-downloader/issues

Traceback (most recent call last):
  File "/usr/local/bin/YahooTickerDownloader.py", line 146, in <module>
    main()
  File "/usr/local/bin/YahooTickerDownloader.py", line 93, in main
    downloadEverything(downloader)
  File "/usr/local/bin/YahooTickerDownloader.py", line 51, in downloadEverything
    symbols = downloader.nextRequest()
  File "/usr/local/lib/python2.7/site-packages/ytd/SymbolDownloader.py", line 73, in nextRequest
    html = self._fetchHtml()
  File "/usr/local/lib/python2.7/site-packages/ytd/SymbolDownloader.py", line 36, in _fetchHtml
    resp = self.rsession.send(req)
  File "/usr/local/lib/python2.7/site-packages/requests/sessions.py", line 573, in send
    r = adapter.send(request, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/requests/adapters.py", line 431, in send
    raise SSLError(e, request=request)
requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:581)

Any idea of what is going on?

A lot of retries / Yahoo API 404's

Sometimes the Yahoo api returns a 404 with the following text:

Will be right back...
Thank you for your patience.
Our engineers are working quickly to resolve the issue.

At some times these 404's happen too often. Causing the script to exit.

Notes:
Occurs in 3.0.0

Program cannot download data

Since last week, the program is unable to access the yahoo finance data; retry 5 times the request and finally get a 404 Client error.
Is there any change in yahoo access?, how can I solve this?.
Anyone knows alternative ways for getting tickers symbols for free?
Attach the terminal output.
error.docx

How to download a list of tickers of an exchange?

Could you please provide an example on how I should write the name of the index?
Is it possible to download a list of all the tickers filtered by index right?

YahooTickerDownloader.py index='BIT' would work?

(I am not sure where to find the code of the index used by Yahoo)

Thanks

Filter multiple exhanges

it is not working for spanish tickets

Yahoo ticker dowloader.py stocks -m ES no working
Yahoo ticker dowloader.py stocks -m es no working

Yahoo ticker dowloader.py stocks -E anything work it is a bug
Yahoo ticker dowloader.py stocks -E es or -E NYQ

Coudl you suggest me any alternative to take only a market o several markets o exchange

install error

Hi Benny,
I am trying to install your module but the pip crack. Attached I will copy last part of the error message. My platform is Mac with macOS High Sierra, version 10.13.3 and use Terminal for the pip.
The message is:
creating build/temp.macosx-10.6-intel-2.7/reppy/rep-cpp/deps/url-cpp
creating build/temp.macosx-10.6-intel-2.7/reppy/rep-cpp/deps/url-cpp/src
/usr/bin/clang -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Ireppy/rep-cpp/include -Ireppy/rep-cpp/deps/url-cpp/include -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c reppy/rep-cpp/src/agent.cpp -o build/temp.macosx-10.6-intel-2.7/reppy/rep-cpp/src/agent.o -std=c++11
In file included from reppy/rep-cpp/src/agent.cpp:4:
reppy/rep-cpp/deps/url-cpp/include/url.h:8:10: fatal error: 'unordered_map' file not found
#include <unordered_map>
^
1 error generated.
error: command '/usr/bin/clang' failed with exit status 1

Incomplete list of tickers for stocks

Hello

I have Python 3.3 (on Windows 7). Several months ago I ran this python script, and I got 14935 stock tickers by running "YahooTickerDownloader.py stocks"

I ran this same script again, but now I only get around 2700 tickers. I reran the script several times, but the number of tickers is always around this number.

Do you know what the problem is? I'd like to get an updated list of tickers for stocks, but I believe there are more than 2700.

Thank you

Tyre

Getting SSL error in python 3.9

Hey, I keep getting an SSL cert error in line 100 when I try to run it with python3.9. Still works in 2.7 though, so I'm using it in that environment. Awesome program, thanks!

Unable to download stocks

$ 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
A exception occurred while downloading. Suspending downloader to disk
Successfully saved download state
Try removing {type}.pickle file if this error persists
Issues can be reported on https://github.com/Benny-/Yahoo-ticker-symbol-downloader/issues

Traceback (most recent call last):
File "C:/Users/Richard/Anaconda2/Scripts/YahooTickerDownloader.py", line 161, in
main()
File "C:/Users/Richard/Anaconda2/Scripts/YahooTickerDownloader.py", line 111, in main
downloadEverything(downloader, tickerType, args.insecure, args.sleep, args.pandantic, market)
File "C:/Users/Richard/Anaconda2/Scripts/YahooTickerDownloader.py", line 46, in downloadEverything
symbols = downloader.nextRequest(insecure, pandantic, market)
File "C:\users\richard\anaconda2\lib\site-packages\ytd\SymbolDownloader.py", line 113, in nextRequest
requests.exceptions.ReadTimeout,
AttributeError: 'module' object has no attribute 'ReadTimeout'

search term `null` returns http 503

Once the algorithm reaches the search term null the server responses with a 503. As a consequence, the downloader basically suspends forever :-(

https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true

maybe we need a list of invalid words (I could imagine that SQL keywords also make problems).

req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 1 of 5. Sleep period: 5 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 2 of 5. Sleep period: 25 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 3 of 5. Sleep period: 125 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 4 of 5. Sleep period: 625 seconds.
req https://finance.yahoo.com/_finance_doubledown/api/resource/searchassist;searchTerm=null?device=console&returnMeta=true
Retry attempt: 5 of 5. Sleep period: 3125 seconds.
^CSuspending downloader to disk as .pickle file

Please add utf8 default coding

After download, writing the files fails:
File "/home/ubuntu/.local/bin/YahooTickerDownloader.py", line 135, in main
f.write(data.csv.encode('UTF-8'))
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 1233: ordinal not in range(128)

This can be avoided by:

import sys

..
def main():
reload(sys)
sys.setdefaultencoding('utf8')

Rate of download

Benny,

Thanks for your code.

My understanding is that yahoo will only accept 2000 requests on its API per hour from an ip authenticated client.

I would like to get a comprehensive list of available ticker symbols. I feel like slowing down your script might work.

What part of your code would a I have tweak in order to bring down the number of requests your script makes to 2000 per hour?

Am I on the right path here?

Excel Export failed: row index (65536) not an int in range(65536)

Trace:

../YahooTickerDownloader.py bond -e
Exporting pickle file
Checking if we can resume a old download session
Downloader found on disk, resuming
Exporting Bond symbols
Traceback (most recent call last):
  File "../YahooTickerDownloader.py", line 161, in <module>
    main()
  File "../YahooTickerDownloader.py", line 158, in main
    f.write(data.xls)
  File "/home/benny/Private/Magic/Market/Yahoo-ticker-symbol-downloader/py3env/lib/python3.5/site-packages/tablib/formats/_xls.py", line 44, in export_set
    dset_sheet(dataset, ws)
  File "/home/benny/Private/Magic/Market/Yahoo-ticker-symbol-downloader/py3env/lib/python3.5/site-packages/tablib/formats/_xls.py", line 133, in dset_sheet
    ws.write(i, j, col)
  File "/home/benny/Private/Magic/Market/Yahoo-ticker-symbol-downloader/py3env/lib/python3.5/site-packages/tablib/packages/xlwt3/Worksheet.py", line 1002, in write
    self.row(r).write(c, label, style)
  File "/home/benny/Private/Magic/Market/Yahoo-ticker-symbol-downloader/py3env/lib/python3.5/site-packages/tablib/packages/xlwt3/Worksheet.py", line 1047, in row
    self.__rows[indx] = self.Row(indx, self)
  File "/home/benny/Private/Magic/Market/Yahoo-ticker-symbol-downloader/py3env/lib/python3.5/site-packages/tablib/packages/xlwt3/Row.py", line 40, in __init__
    raise ValueError("row index (%r) not an int in range(65536)" % rowx)
ValueError: row index (65536) not an int in range(65536)

Downloading list of stocks failed

Downloading a list of stocks using the package in Python 3.3 under Windows 7 failed with the following stack trace (same result with secure and insecure connection):

Traceback (most recent call last):
File "C:\Python33\lib\site-packages\requests-2.10.0-py3.3.egg\requests\packages\urllib3\connection.py", line 142, in _new_conn
(self.host, self.port), self.timeout, **extra_kw)
File "C:\Python33\lib\site-packages\requests-2.10.0-py3.3.egg\requests\packages\urllib3\util\connection.py", line 91, in create_connection
raise err
File "C:\Python33\lib\site-packages\requests-2.10.0-py3.3.egg\requests\packages\urllib3\util\connection.py", line 81, in create_connection
sock.connect(sa)
TimeoutError: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

Pinging finance.yahoo.com does not raise any issues though!

downloading interruption

After running it for a while I got this error:

Traceback (most recent call last):
File "D:\Python27\Scripts\YahooTickerDownloader.py", line 140, in
main()
File "D:\Python27\Scripts\YahooTickerDownloader.py", line 97, in main
downloadEverything(downloader, tickerType, args.insecure)
File "D:\Python27\Scripts\YahooTickerDownloader.py", line 51, in downloadEvery
thing
print (" " + unicode(symbols[1]))
UnicodeEncodeError: 'gbk' codec can't encode character u'\xc3' in position 27: i
llegal multibyte sequence

If I restart it, it will go further before throwing another one. Is this just Yahoo issue or something else?

UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position ....

Exporting Stock symbols
Traceback (most recent call last):
File "/usr/local/bin/YahooTickerDownloader.py", line 147, in
main()
File "/usr/local/bin/YahooTickerDownloader.py", line 135, in main
f.write(data.csv.encode('UTF-8'))
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 1543: ordinal not in range(128)

TypeError: cell() takes at least 3 arguments (2 given)

Hello,

I get this error when exporting:

Exporting stocks symbols
Traceback (most recent call last):
File "C:\Python27\Scripts\YahooTickerDownloader.py", l
main()
File "C:\Python27\Scripts\YahooTickerDownloader.py", l
f.write(data.xlsx)
File "C:\Python27\lib\site-packages\tablib\formats_xl
rt_set
dset_sheet(dataset, ws, freeze_panes=freeze_panes)
File "C:\Python27\lib\site-packages\tablib\formats_xl
t_sheet
cell = ws.cell('%s%s' % (col_idx, row_number))
TypeError: cell() takes at least 3 arguments (2 given)

Any idea?
Thanks a lot

Building wheel for Yahoo-ticker-downloader failed

Is it a problem if building wheel fails during the download process? I haven't had a problem loading the downloaded stocks.pickle file using python, so I'm just wondering if there's any need for me to reinstall the package. This is the error that I get during the pip install process on a Mac OSX El Capitan:

Building wheels for collected packages: Yahoo-ticker-downloader
  Building wheel for Yahoo-ticker-downloader failed: [Errno 13] Permission denied: '/Users/Yuqi/Library/Caches/pip/wheels/bd'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.