This is a python 3 version of the script created by: Dr. Pawel Lachowicz, QuantAtRisk.com Sydney, Australia (ABN 58 495 201 605) +61 450935406 Link to his article: http://www.quantatrisk.com/2014/01/14/hacking-google-finance-in-real-time-for-algorithmic-traders/ and a follow up article: http://www.quantatrisk.com/2015/05/07/hacking-google-finance-in-pre-market-trading-python/
The translation was trivial: urllib.request was used instead of urllib2