MCPcopy
hub / github.com/borgbackup/borg / write_chunk

Method write_chunk

src/borg/archive.py:412–418  ·  view source on GitHub ↗
(self, chunk)

Source from the content-addressed store, hash-verified

410 self.stats = stats
411
412 def write_chunk(self, chunk):
413 id_, _ = self.cache.add_chunk(
414 self.key.id_hash(chunk), {}, chunk, stats=self.stats, wait=False, ro_type=ROBJ_ARCHIVE_STREAM
415 )
416 logger.debug(f"writing item metadata stream chunk {bin_to_hex(id_)}")
417 self.cache.repository.async_response(wait=False)
418 return id_
419
420
421def get_item_uid_gid(item, *, numeric, uid_forced=None, gid_forced=None, uid_default=0, gid_default=0):

Callers

nothing calls this directly

Calls 5

bin_to_hexFunction · 0.85
debugMethod · 0.80
add_chunkMethod · 0.45
id_hashMethod · 0.45
async_responseMethod · 0.45

Tested by

no test coverage detected