no more display data when Page is not found
This commit is contained in:
parent
91cf1fa6a0
commit
351622debc
1 changed files with 5 additions and 5 deletions
|
|
@ -314,11 +314,11 @@ class BaseBrowser(mechanize.Browser):
|
||||||
# Not found
|
# Not found
|
||||||
if not pageCls:
|
if not pageCls:
|
||||||
self.page = None
|
self.page = None
|
||||||
r = result.read()
|
#data = result.read()
|
||||||
if isinstance(r, unicode):
|
#if isinstance(data, unicode):
|
||||||
r = r.encode('iso-8859-15', 'replace')
|
# data = data.encode('utf-8')
|
||||||
print r
|
#print data
|
||||||
warning('Ho my fucking god, there isn\'t any page named %s' % result.geturl())
|
warning('Oh my fucking god, there isn\'t any page corresponding to URL %s' % result.geturl())
|
||||||
return
|
return
|
||||||
|
|
||||||
debug('[user_id=%s] Went on %s' % (self.username, result.geturl()))
|
debug('[user_id=%s] Went on %s' % (self.username, result.geturl()))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue