Commit 9fa60d05 authored by matt@zope.com's avatar matt@zope.com

Commit removal of autoimport and amplify error msg on version

parent a8c331a6
......@@ -84,8 +84,8 @@
##############################################################################
"""Mounted database support
$Id: TemporaryFolder.py,v 1.1 2001/11/01 20:18:12 matt Exp $"""
__version__='$Revision: 1.1 $'[11:-2]
$Id: TemporaryFolder.py,v 1.2 2001/11/13 21:44:33 matt Exp $"""
__version__='$Revision: 1.2 $'[11:-2]
import Globals
from Globals import HTMLFile
......@@ -151,18 +151,3 @@ class MountedTemporaryFolder(MountPoint, OFS.SimpleItem.Item):
folder.title = self.title
folder.icon = "misc_/TemporaryFolder/tempfolder.gif"
importdir = os.path.join(Globals.data_dir,self.id+"Imports")
#conn = folder._p_jar # Can we do that yet?
conn = root._p_jar
try:
for file in os.listdir(importdir):
if file[-5:] == ".zexp":
id = file[:-5]
# Import this!
ob = conn.importFile(os.path.join(importdir, file))
folder._setObject(id, ob)
except OSError: pass # (no such dir)
......@@ -88,10 +88,10 @@ A storage implementation which uses RAM to persist objects, much like
MappingStorage, but unlike MappingStorage needs not be packed to get rid of
non-cyclic garbage. This is a ripoff of Jim's Packless bsddb3 storage.
$Id: TemporaryStorage.py,v 1.1 2001/11/01 20:18:12 matt Exp $
$Id: TemporaryStorage.py,v 1.2 2001/11/13 21:44:33 matt Exp $
"""
__version__ ='$Revision: 1.1 $'[11:-2]
__version__ ='$Revision: 1.2 $'[11:-2]
from zLOG import LOG
from struct import pack, unpack
......@@ -169,8 +169,11 @@ class TemporaryStorage(BaseStorage, ConflictResolvingStorage):
def store(self, oid, serial, data, version, transaction):
if transaction is not self._transaction:
raise POSException.StorageTransactionError(self, transaction)
if version:
raise POSException.Unsupported, "Versions aren't supported"
raise POSException.Unsupported, ("TemporaryStorage is incompatible "
"with versions",)
self._lock_acquire()
try:
......
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