git://git.onelab.eu
/
plcapi.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Setting tag plcapi-5.4-2
[plcapi.git]
/
apache
/
ModPython.py
diff --git
a/apache/ModPython.py
b/apache/ModPython.py
index
07a0fda
..
c091894
100644
(file)
--- a/
apache/ModPython.py
+++ b/
apache/ModPython.py
@@
-13,7
+13,7
@@
import traceback
import xmlrpclib
from mod_python import apache
import xmlrpclib
from mod_python import apache
-from PLC.
Debug import log
+from PLC.
Logger import logger
from PLC.API import PLCAPI
api = PLCAPI()
from PLC.API import PLCAPI
api = PLCAPI()
@@
-56,8
+56,6
@@
def handler(req):
return apache.OK
return apache.OK
- except Exception, err:
- # Log error in /var/log/httpd/(ssl_)?error_log
- t = "[" + time.ctime() + "] [error]"
- print >> log, t, err, traceback.format_exc()
+ except Exception as err:
+ logger.exception("INTERNAL ERROR !!")
return apache.HTTP_INTERNAL_SERVER_ERROR
return apache.HTTP_INTERNAL_SERVER_ERROR