summaryrefslogtreecommitdiff
path: root/addons/web/controllers/main.py
diff options
context:
space:
mode:
authorDenis Ledoux <dle@odoo.com>2015-05-20 11:09:05 +0200
committerDenis Ledoux <dle@odoo.com>2015-05-20 11:09:05 +0200
commitdb3e5716b3977719d0bd9a65f615cc8475078f81 (patch)
tree5a3a0c0a40f0f853df3ccf1cf1bd8265c14f445f /addons/web/controllers/main.py
parentac92551406c333dc6829126e4c2fc6f0f1c613f9 (diff)
[FIX] ir_attachment: write traceback to logs when upload fail
When the upload of an attachment failed, e.g. for access rights reasons, the traceback wasn't written or returned anywhere, preventing the easy debugging. opw-640242
Diffstat (limited to 'addons/web/controllers/main.py')
-rw-r--r--addons/web/controllers/main.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/addons/web/controllers/main.py b/addons/web/controllers/main.py
index 3ebbfb02af6..8b3a21fdee8 100644
--- a/addons/web/controllers/main.py
+++ b/addons/web/controllers/main.py
@@ -1168,6 +1168,7 @@ class Binary(http.Controller):
}
except Exception:
args = {'error': "Something horrible happened"}
+ _logger.exception("Fail to upload attachment %s" % ufile.filename)
return out % (simplejson.dumps(callback), simplejson.dumps(args))
@http.route([