这是2.x转3.x问题url
2.x写法:spa
from urlparse import urlparse
3.x写法:code
from urllib.parse import urlparse
问题解决。blog