eliangcs / pystock-crawler

(UNMAINTAINED) Crawl and parse financial reports (XBRL) from SEC EDGAR, and daily stock prices from Yahoo Finance
MIT License
311 stars 100 forks source link

install issue #20

Closed andyyuan78 closed 9 years ago

andyyuan78 commented 9 years ago

ubgpu@ubgpu:~/github/pystock-crawler$ pystock-crawler -h File "/usr/local/bin/pystock-crawler", line 209 print 'pystock-crawler %s' % pystock_crawler.version ^ SyntaxError: invalid syntax Error in sys.excepthook: Traceback (most recent call last): File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 53, in apport_excepthook if not enabled(): File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 24, in enabled import re File "/usr/lib/python3.4/re.py", line 324, in import copyreg File "/usr/local/lib/python2.7/dist-packages/copyreg/init.py", line 7, in raise ImportError('This package should not be accessible on Python 3. ' ImportError: This package should not be accessible on Python 3. Either you are trying to run from the python-future src folder or your installation of python-future is corrupted.

Original exception was: File "/usr/local/bin/pystock-crawler", line 209 print 'pystock-crawler %s' % pystock_crawler.version ^ SyntaxError: invalid syntax ubgpu@ubgpu:~/github/pystock-crawler$ ubgpu@ubgpu:~/github/pystock-crawler$

eliangcs commented 9 years ago

Python 3 is not supported. Please use Python 2.7.x.

andyyuan78 commented 9 years ago

A little wired

ubgpu@ubgpu:~/github/pystock-crawler$ ll /usr/bin/python lrwxrwxrwx 1 root root 9 3月 23 02:18 /usr/bin/python -> python2.7* ubgpu@ubgpu:~/github/pystock-crawler$ echo $PYTHONPATH /usr/local/lib/python2.7/dist-packages ubgpu@ubgpu:~/github/pystock-crawler$

eliangcs commented 9 years ago

From the paths in the error message you provided, it seems you're mixing Python 2 and 3. You should try cleaning up your Python installation. Try pyenv (https://github.com/yyuu/pyenv) perhaps?