http error 301 for urlopen

Wenhuan Yu yuwenhuan at
Mon Nov 8 02:30:23 CET 2010

I tried to open a link with urlopen:

import urllib2
alink = ""
f = urllib2.urlopen(alink)

and got the followinig error:

urllib2.HTTPError: HTTP Error 301: The HTTP server returned a redirect error
t would lead to an infinite loop.
The last 30x error message was:
Moved Permanently

I can open the link in browser. Any way to get solve this? Thanks.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Python-list mailing list