HTTP 応答コードを取得するために次のレシピを使用していますが、3xx を取得できません。
import urllib2
for url in ["http://entrian.com/", "http://entrian.com/does-not-exist/"]:
try:
connection = urllib2.urlopen(url)
print connection.getcode()
connection.close()
except urllib2.HTTPError, e:
print e.getcode()
urllib2 のリダイレクト処理を無効にするにはどうすればよいですか?