robertmartin8 / MachineLearningStocks

Using python and scikit-learn to make stock predictions
MIT License
1.74k stars 506 forks source link

syntax error - download_historical_prices.py #11

Closed alphaaurigae closed 6 years ago

alphaaurigae commented 6 years ago

ubuntu 16.04

✘-1 ~/MachineLearningStocks [master|✚ 1…21968] 
05:02 $ python download_historical_prices.py
  File "download_historical_prices.py", line 35
    print(f"{len(missing_tickers)} tickers are missing: \n {missing_tickers} ")
                                                                             ^
SyntaxError: invalid syntax
robertmartin8 commented 6 years ago

@alphaaurigae Hi, thanks for raising this issue (and apologies for the slow response).

Can I check what version of python you are using? I'm not getting this error on my system – I think the problem might be that python versions before 3.6 doesn't support f-strings. I'm pretty sure that updating your python to 3.6 should fix the issue. I notice that the readme doesn't specify the python version for this project, so I have amended it to include a quick note.

Please let me know if you're still having issues,

Robert

alphaaurigae commented 6 years ago

Python 3.5.2 , current on 16.04 with apt-get repositories. 18.04 comes with python3 3.6.3-0 https://launchpad.net/ubuntu/bionic/+package/python3 https://www.ubuntu.com/info/release-end-of-life

So your repo is just fine and i need to upgrade ... Thanks for help!