MCPcopy Index your code
hub / github.com/RustPython/RustPython / sync

Method sync

Lib/shelve.py:164–172  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

162 self.close()
163
164 def sync(self):
165 if self.writeback and self.cache:
166 self.writeback = False
167 for key, entry in self.cache.items():
168 self[key] = entry
169 self.writeback = True
170 self.cache = {}
171 if hasattr(self.dict, 'sync'):
172 self.dict.sync()
173
174
175class BsdDbShelf(Shelf):

Callers 1

closeMethod · 0.95

Calls 2

hasattrFunction · 0.85
itemsMethod · 0.45

Tested by

no test coverage detected