Commit cc5ad248 authored by Jeremy Hylton's avatar Jeremy Hylton

Change test for None oid in invalidate() to assert.

Reindent MUCH_RING_CHECKING test.
parent b731a65d
......@@ -13,7 +13,7 @@
##############################################################################
"""Database connection support
$Id: Connection.py,v 1.68 2002/06/12 15:30:05 jeremy Exp $"""
$Id: Connection.py,v 1.69 2002/06/12 19:40:47 jeremy Exp $"""
from cPickleCache import PickleCache, MUCH_RING_CHECKING
from POSException import ConflictError, ReadConflictError
......@@ -32,10 +32,10 @@ from types import StringType, ClassType
global_code_timestamp = 0
if MUCH_RING_CHECKING:
# To get rid of this warning, change the define inside
# cPickleCache.c and recompile.
LOG('ZODB',WARNING,
'Using cPickleCache with low performance (but extra debugging checks)')
# To get rid of this warning, change the define inside
# cPickleCache.c and recompile.
LOG('ZODB',WARNING,
'Using cPickleCache with low performance (but extra debugging checks)')
del MUCH_RING_CHECKING
def updateCodeTimestamp():
......@@ -225,8 +225,8 @@ class Connection(ExportImport.ExportImport):
if object is self:
self._cache.invalidate(self._invalidated)
else:
if object._p_oid is not None:
self._cache.invalidate(object._p_oid)
assert object._p_oid is not None
self._cache.invalidate(object._p_oid)
def cacheFullSweep(self, dt=0):
self._cache.full_sweep(dt)
......
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