[Mpuls-commits] r5234 - in base/trunk: . mpulsweb/lib

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Mon Aug 15 10:43:51 CEST 2011


Author: ludwig
Date: 2011-08-15 10:43:49 +0200 (Mon, 15 Aug 2011)
New Revision: 5234

Modified:
   base/trunk/ChangeLog
   base/trunk/mpulsweb/lib/security.py
Log:
Use error logging instead of exception logging in the checkRole
function. (Issue2241)

Modified: base/trunk/ChangeLog
===================================================================
--- base/trunk/ChangeLog	2011-08-12 15:25:09 UTC (rev 5233)
+++ base/trunk/ChangeLog	2011-08-15 08:43:49 UTC (rev 5234)
@@ -1,3 +1,9 @@
+2011-08-15  Ludwig Reiter <ludwig.reiter at intevation.de>
+
+	* mpulsweb/lib/security.py:
+	Use error logging instead of exception logging in the checkRole
+	function. (Issue2241)
+
 2011-08-12  Bernhard Herzog  <bh at intevation.de>
 
 	* mpulsweb/lib/config.py (MpulsAppConfig.build_defaults): Fix

Modified: base/trunk/mpulsweb/lib/security.py
===================================================================
--- base/trunk/mpulsweb/lib/security.py	2011-08-12 15:25:09 UTC (rev 5233)
+++ base/trunk/mpulsweb/lib/security.py	2011-08-15 08:43:49 UTC (rev 5234)
@@ -379,8 +379,8 @@
 
     def validate(func, self, *args, **kwargs):
         if not hasRole(_role):
-            log.exception('Not authorised to look at the requested document. '
-                          'Returns an HTTP Unauthorized response.')
+            log.error('Not authorised to look at the requested document. '
+                      'Returns an HTTP Unauthorized response.')
             raise HTTPUnauthorized(detail=_('You are not authorised to '
                 'look at the requested document.'))
         try:



More information about the Mpuls-commits mailing list