no stdou in wsgi mode
This commit is contained in:
parent
6c3c128dc9
commit
13d41faa4f
1 changed files with 4 additions and 4 deletions
|
@ -73,14 +73,14 @@ class PosterCache(models.Model):
|
||||||
data = ox.net.readUrl(url)
|
data = ox.net.readUrl(url)
|
||||||
self.image.save(name, ContentFile(data))
|
self.image.save(name, ContentFile(data))
|
||||||
except ox.net.urllib2.HTTPError, e:
|
except ox.net.urllib2.HTTPError, e:
|
||||||
import traceback
|
#import traceback
|
||||||
print traceback.print_exc()
|
#print traceback.print_exc()
|
||||||
self.status = e.code
|
self.status = e.code
|
||||||
self.failed = True
|
self.failed = True
|
||||||
self.save()
|
self.save()
|
||||||
except ox.net.urllib2.URLError, e:
|
except ox.net.urllib2.URLError, e:
|
||||||
import traceback
|
#import traceback
|
||||||
print traceback.print_exc()
|
#print traceback.print_exc()
|
||||||
self.status = e.reason
|
self.status = e.reason
|
||||||
self.failed = True
|
self.failed = True
|
||||||
self.save()
|
self.save()
|
||||||
|
|
Loading…
Reference in a new issue