Commit dbead218 authored by Nicolas Delaby's avatar Nicolas Delaby

Use Zope log levels.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@34185 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 95dbae14
from logging import ERROR
# -*- coding: utf-8 -*-
from zLOG import ERROR
from UserDict import UserDict
from Products.PageTemplates.PageTemplateFile import PageTemplateFile
......
# -*- coding: utf-8 -*-
from AccessControl.Role import RoleManager
from AccessControl import ClassSecurityInfo
from Acquisition import Implicit
......@@ -39,7 +40,7 @@ from zope.interface import implements
__revision__ = '$Id: TransformEngine.py 6255 2006-04-11 15:29:29Z hannosch $'
from logging import DEBUG
from zLOG import DEBUG
class TransformTool(UniqueObject, ActionProviderBase, Folder):
......
# -*- coding: utf-8 -*-
### Register Transforms
### This is interesting because we don't expect all transforms to be
### available on all platforms. To do this we allow things to fail at
......@@ -11,7 +12,7 @@
### implement the transform, if register needs to fail for now it
### should raise an ImportError as well (dumb, I know)
from logging import DEBUG, ERROR
from zLOG import DEBUG, ERROR
from Products.PortalTransforms.utils import log
from Products.PortalTransforms.libtransforms.utils import MissingBinary
modules = [
......
# -*- coding: utf-8 -*-
import logging
from zLOG import ERROR
from HTMLParser import HTMLParser, HTMLParseError
import re
from cgi import escape
......@@ -251,7 +251,7 @@ class SafeHTML:
def convert(self, orig, data, **kwargs):
# note if we need an upgrade.
if not self.config.has_key('disable_transform'):
log(logging.ERROR, 'PortalTransforms safe_html transform needs to be '
log(ERROR, 'PortalTransforms safe_html transform needs to be '
'updated. Please re-install the PortalTransforms product to fix.')
# if we have a config that we don't want to delete
......
# -*- coding: utf-8 -*-
"""some common utilities
"""
import logging
from time import time
from types import UnicodeType, StringType
......@@ -13,10 +12,10 @@ class TransformException(Exception):
FB_REGISTRY = None
# logging function
from zLOG import LOG
from zLOG import LOG, INFO
#logger = logging.getLogger('PortalTransforms')
def log(message, severity=logging.INFO):
def log(message, severity=INFO):
LOG('PortalTransforms', severity, message)
#logger.log(severity, message)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment