[Zope-CVS] CVS: Packages/zpkgtools/zpkgtools - __init__.py:1.2 cvsloader.py:1.13 include.py:1.13

Fred L. Drake, Jr. fred at zope.com
Wed Mar 31 01:02:05 EST 2004


Update of /cvs-repository/Packages/zpkgtools/zpkgtools
In directory cvs.zope.org:/tmp/cvs-serv21250/zpkgtools

Modified Files:
	__init__.py cvsloader.py include.py 
Log Message:
use a shared base exception for everything but the ZConfig-lite implementation


=== Packages/zpkgtools/zpkgtools/__init__.py 1.1 => 1.2 ===
--- Packages/zpkgtools/zpkgtools/__init__.py:1.1	Fri Mar  5 15:42:25 2004
+++ Packages/zpkgtools/zpkgtools/__init__.py	Wed Mar 31 01:02:03 2004
@@ -12,3 +12,7 @@
 #
 ##############################################################################
 """Zope packaging utilities."""
+
+
+class Error(Exception):
+    """Base class for exceptions raised by zpkgtools."""


=== Packages/zpkgtools/zpkgtools/cvsloader.py 1.12 => 1.13 ===
--- Packages/zpkgtools/zpkgtools/cvsloader.py:1.12	Mon Mar 29 14:18:15 2004
+++ Packages/zpkgtools/zpkgtools/cvsloader.py	Wed Mar 31 01:02:03 2004
@@ -22,15 +22,17 @@
 import urllib
 import urlparse
 
+from zpkgtools import Error
 
-class CvsLoadingError(Exception):
+
+class CvsLoadingError(Error):
     """Raised when there was some error loading from CVS."""
 
     def __init__(self, cvsurl, exitcode):
         self.cvsurl = cvsurl
         self.exitcode = exitcode
-        Exception.__init__(self, ("could not load from %s (cvs exit code %d)"
-                                  % (cvsurl.getUrl(), exitcode)))
+        Error.__init__(self, ("could not load from %s (cvs exit code %d)"
+                              % (cvsurl.getUrl(), exitcode)))
 
 
 _cvs_url_match = re.compile(


=== Packages/zpkgtools/zpkgtools/include.py 1.12 => 1.13 ===
--- Packages/zpkgtools/zpkgtools/include.py:1.12	Tue Mar 30 22:44:28 2004
+++ Packages/zpkgtools/zpkgtools/include.py	Wed Mar 31 01:02:03 2004
@@ -21,6 +21,8 @@
 import urllib
 import urllib2
 
+from zpkgtools import Error
+
 from zpkgtools import cvsloader
 
 
@@ -29,7 +31,7 @@
 EXCLUDE_PATTERNS = ["*.py[cdo]", "*.s[ol]"]
 
 
-class InclusionError(Exception):
+class InclusionError(Error):
     pass
 
 




More information about the Zope-CVS mailing list