You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL: https://query1.finance.yahoo.com/v7/finance/download/BLK?period1=1104537600&period2=1401580800&interval=1d&events=history&crumb=jValG4P3fLj
at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1876)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1474)
at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:480)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(HttpsURLConnectionImpl.java:338)
at com.zavtech.morpheus.util.http.HttpClient$DefaultClient.execute(HttpClient.java:133)
... 10 more
Hey chadworth, apologies but the Yahoo adapter is currently broken as it was written a few years ago and Yahoo has discontinued some of the services on which it depends (hence why the adapter is not available on Maven Central at this moment). I do plan to address the issues in the next few weeks and will post a reply here when it is working again. Be aware however that when it is fixed it can break at anytime as it relies on screen scrapping and other non-supported apis in Yahoo Finance which are subject to change without notice. So the adapter is fine for research purposes, but I would not rely on it for production. If you are looking for end of day close prices, you can use the Quandl adapter and the WIKI price source: https://www.quandl.com/data/WIKI-Wiki-EOD-Stock-Prices
Activity
Zavster commentedon Aug 17, 2017
Hey chadworth, apologies but the Yahoo adapter is currently broken as it was written a few years ago and Yahoo has discontinued some of the services on which it depends (hence why the adapter is not available on Maven Central at this moment). I do plan to address the issues in the next few weeks and will post a reply here when it is working again. Be aware however that when it is fixed it can break at anytime as it relies on screen scrapping and other non-supported apis in Yahoo Finance which are subject to change without notice. So the adapter is fine for research purposes, but I would not rely on it for production. If you are looking for end of day close prices, you can use the Quandl adapter and the WIKI price source: https://www.quandl.com/data/WIKI-Wiki-EOD-Stock-Prices
chadworth commentedon Aug 17, 2017
Yep. We could call the library below which seems to be kept up-to-date with Yahoo:
https://github.com/sstrickx/yahoofinance-api
Zavster commentedon Aug 17, 2017
Thanks for the pointer, I'll take a look at that
chadworth commentedon Aug 27, 2017
I found they have a new JSON api that works much better. I sent a PR for it here: https://github.com/sstrickx/yahoofinance-api/pull/96/files
You might want to just copy in the code from this PR
Zavster commentedon Oct 2, 2017
This has been fixed in the latest release which is now on Maven Central. The documentation can be found at the link: http://www.zavtech.com/morpheus/docs/providers/yahoo/