Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/borg/cache.py
Original file line number Diff line number Diff line change
Expand Up @@ -801,7 +801,7 @@ def write_archive_index(archive_id, chunk_idx):

def read_archive_index(archive_id, archive_name):
archive_chunk_idx_path = mkpath(archive_id)
logger.info("Reading cached archive chunk index for %s ...", archive_name)
logger.debug("Reading cached archive chunk index for %s ...", archive_name)
try:
try:
# Attempt to load compact index first
Expand Down Expand Up @@ -869,14 +869,14 @@ def create_master_idx(chunk_idx):
if archive_id not in cached_ids:
# Do not make this an else branch; the FileIntegrityError exception handler
# above can remove *archive_id* from *cached_ids*.
logger.info('Fetching and building archive index for %s ...', archive_name)
logger.debug('Fetching and building archive index for %s ...', archive_name)
archive_chunk_idx = ChunkIndex()
fetch_and_build_idx(archive_id, decrypted_repository, archive_chunk_idx)
logger.info("Merging into master chunks index ...")
logger.debug("Merging into master chunks index ...")
chunk_idx.merge(archive_chunk_idx)
else:
chunk_idx = chunk_idx or ChunkIndex(usable=master_index_capacity)
logger.info('Fetching archive index for %s ...', archive_name)
logger.debug('Fetching archive index for %s ...', archive_name)
fetch_and_build_idx(archive_id, decrypted_repository, chunk_idx)
if not self.do_cache:
fetch_missing_csize(chunk_idx)
Expand Down
2 changes: 1 addition & 1 deletion src/borg/testsuite/archiver.py
Original file line number Diff line number Diff line change
Expand Up @@ -5112,7 +5112,7 @@ def test_chunks_archive(self):
config.write(fd)

# Cache sync notices corrupted archive chunks, but automatically recovers.
out = self.cmd('create', '-v', self.repository_location + '::test3', 'input', exit_code=1)
out = self.cmd('create', '--debug', self.repository_location + '::test3', 'input', exit_code=1)
assert 'Reading cached archive chunk index for test1' in out
assert 'Cached archive chunk index of test1 is corrupted' in out
assert 'Fetching and building archive index for test1' in out
Expand Down
Loading