Switch from url lib to requests

by switching form url lib to the requests library. You make this code also work in Python 2.7