Log message for revision 41222:
  deprecated zLOG
  

Changed:
  U   Zope/branches/2.9/doc/CHANGES.txt
  U   Zope/branches/2.9/lib/python/zLOG/__init__.py

-=-
Modified: Zope/branches/2.9/doc/CHANGES.txt
===================================================================
--- Zope/branches/2.9/doc/CHANGES.txt   2006-01-08 14:36:43 UTC (rev 41221)
+++ Zope/branches/2.9/doc/CHANGES.txt   2006-01-08 14:40:14 UTC (rev 41222)
@@ -22,6 +22,13 @@
 
    - Collector #1233: port ZOPE_CONFIG patch from Zope 2.7 to Zope 2.8
 
+  after 2.9.0 
+
+    Bugs fixed
+
+      - officially deprecated the zLOG module (to be removed in Zope 2.11).
+        Use the logging module of Python instead.
+
   Zope 2.9.0 (2006/01/09)
 
     Bugs fixed

Modified: Zope/branches/2.9/lib/python/zLOG/__init__.py
===================================================================
--- Zope/branches/2.9/lib/python/zLOG/__init__.py       2006-01-08 14:36:43 UTC 
(rev 41221)
+++ Zope/branches/2.9/lib/python/zLOG/__init__.py       2006-01-08 14:40:14 UTC 
(rev 41222)
@@ -77,6 +77,8 @@
 somewhere else.
 
 """
+
+import warnings
 from EventLogger import log_write, log_time, severity_string
 from traceback import format_exception
 
@@ -131,6 +133,13 @@
                  error is reraised.
 
     """
+
+    warnings.warn('The zLOG package is deprecated and will be removed in '
+                  'Zope 2.11. Use the Python logging module instead.',
+                  DeprecationWarning,
+                  stacklevel=2) 
+
+
     log_write(subsystem, severity, summary, detail, error)
     if reraise and error:
         raise error[0], error[1], error[2]

_______________________________________________
Zope-Checkins maillist  -  Zope-Checkins@zope.org
http://mail.zope.org/mailman/listinfo/zope-checkins

Reply via email to