[Checkins] SVN: ZConfig/trunk/ Preparing release 3.0.1

Stephen Richter cvs-admin at zope.org
Wed Feb 13 16:38:38 UTC 2013


Log message for revision 129335:
  Preparing release 3.0.1

Changed:
  U   ZConfig/trunk/CHANGES.txt
  U   ZConfig/trunk/ZConfig/cfgparser.py
  U   ZConfig/trunk/ZConfig/schema.py
  U   ZConfig/trunk/ZConfig/tests/test_schema.py
  U   ZConfig/trunk/setup.py

-=-
Modified: ZConfig/trunk/CHANGES.txt
===================================================================
--- ZConfig/trunk/CHANGES.txt	2013-02-13 15:27:41 UTC (rev 129334)
+++ ZConfig/trunk/CHANGES.txt	2013-02-13 16:38:38 UTC (rev 129335)
@@ -2,12 +2,14 @@
 Change History for ZConfig
 ==========================
 
-3.0.1 (unreleased)
+3.0.1 (2013-02-13)
 ------------------
 
-- Nothing changed yet.
+- Removed an accidentally left `pdb` statement from the code.
 
+- Fix a bug in Python 3 with the custom string `repr()` function.
 
+
 3.0.0 (2013-02-13)
 ------------------
 

Modified: ZConfig/trunk/ZConfig/cfgparser.py
===================================================================
--- ZConfig/trunk/ZConfig/cfgparser.py	2013-02-13 15:27:41 UTC (rev 129334)
+++ ZConfig/trunk/ZConfig/cfgparser.py	2013-02-13 16:38:38 UTC (rev 129335)
@@ -113,10 +113,7 @@
         return prevsection
 
     def handle_key_value(self, section, rest):
-        try:
-            m = _keyvalue_rx.match(rest)
-        except:
-            import pdb; pdb.set_trace()
+        m = _keyvalue_rx.match(rest)
         if not m:
             self.error("malformed configuration data")
         key, value = m.group('key', 'value')

Modified: ZConfig/trunk/ZConfig/schema.py
===================================================================
--- ZConfig/trunk/ZConfig/schema.py	2013-02-13 15:27:41 UTC (rev 129334)
+++ ZConfig/trunk/ZConfig/schema.py	2013-02-13 16:38:38 UTC (rev 129335)
@@ -14,6 +14,7 @@
 """Parser for ZConfig schemas."""
 
 import os
+import sys
 import xml.sax
 
 import ZConfig
@@ -34,7 +35,7 @@
 
 
 def _srepr(ob):
-    if isinstance(ob, type(u'')):
+    if isinstance(ob, type(u'')) and sys.version_info[0] < 3:
         # drop the leading "u" from a unicode repr
         return repr(ob)[1:]
     else:

Modified: ZConfig/trunk/ZConfig/tests/test_schema.py
===================================================================
--- ZConfig/trunk/ZConfig/tests/test_schema.py	2013-02-13 15:27:41 UTC (rev 129334)
+++ ZConfig/trunk/ZConfig/tests/test_schema.py	2013-02-13 16:38:38 UTC (rev 129335)
@@ -42,6 +42,7 @@
 class SchemaTestCase(TestHelper, unittest.TestCase):
     """Tests of the basic schema support itself."""
 
+
     def test_minimal_schema(self):
         schema = self.load_schema_text("<schema/>")
         self.assertEqual(len(schema), 0)
@@ -1074,7 +1075,12 @@
             </schema>
             """)
 
+    def test_srepr(self):
+        from ZConfig.schema import _srepr
+        self.assertEqual(_srepr('foo'), "'foo'")
+        self.assertEqual(_srepr(u'foo'), "'foo'")
 
+
 def test_suite():
     return unittest.makeSuite(SchemaTestCase)
 

Modified: ZConfig/trunk/setup.py
===================================================================
--- ZConfig/trunk/setup.py	2013-02-13 15:27:41 UTC (rev 129334)
+++ ZConfig/trunk/setup.py	2013-02-13 16:38:38 UTC (rev 129335)
@@ -18,7 +18,7 @@
 
 options = dict(
     name="ZConfig",
-    version='3.0.1.dev0',
+    version='3.0.1',
     author="Fred L. Drake, Jr.",
     author_email="fred at zope.com",
     maintainer="Zope Foundation and Contributors",



More information about the checkins mailing list