[Zope-CVS] CVS: Products/Ape/lib/apelib/core - exceptions.py:1.2.2.1 gateways.py:1.5.2.1
Shane Hathaway
shane@zope.com
Tue, 24 Jun 2003 17:39:13 -0400
Update of /cvs-repository/Products/Ape/lib/apelib/core
In directory cvs.zope.org:/tmp/cvs-serv2045/core
Modified Files:
Tag: ape-newconf-branch
exceptions.py gateways.py
Log Message:
Reduced the number of things necessary to configure in a mapper.
This change centered around removing the arguments to the constructor
in zope2.basemapper. They were making it hard to write a
configuration vocabulary.
Removed the app_key argument through the use of a read-only gateway
instead of a fixed persistent mapping, and removed the
stored_keychains argument by always storing keychains. The filesystem
version of the folder items gateway doesn't actually store the
keychains, but it can verify that when the keychains are loaded again
they will be the same as they were at storage time.
=== Products/Ape/lib/apelib/core/exceptions.py 1.2 => 1.2.2.1 ===
--- Products/Ape/lib/apelib/core/exceptions.py:1.2 Tue Apr 29 18:11:50 2003
+++ Products/Ape/lib/apelib/core/exceptions.py Tue Jun 24 17:38:43 2003
@@ -25,6 +25,12 @@
class DeserializationError(MappingError):
"""Error during deserialization"""
+class StoreError(MappingError):
+ """Error while storing"""
+
+class LoadError(MappingError):
+ """Error while loading"""
+
class NoStateFoundError(MappingError):
"""No state is there to load"""
=== Products/Ape/lib/apelib/core/gateways.py 1.5 => 1.5.2.1 ===
--- Products/Ape/lib/apelib/core/gateways.py:1.5 Mon May 19 15:32:33 2003
+++ Products/Ape/lib/apelib/core/gateways.py Tue Jun 24 17:38:43 2003
@@ -19,7 +19,7 @@
import time
from interfaces import IGateway
-from exceptions import NoStateFoundError
+import exceptions
class CompositeGateway:
@@ -111,7 +111,7 @@
try:
return self.data[keychain]
except KeyError:
- raise NoStateFoundError(keychain)
+ raise exceptions.NoStateFoundError(keychain)
def store(self, event, data):
h = time.time()