import urlparse from six.moves (python3 compatibility fix)