Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

v1.17: skip unrecognized keys in Blockstore special-column iterators #33617

Merged

Conversation

CriesofCarrots
Copy link
Contributor

@CriesofCarrots CriesofCarrots commented Oct 10, 2023

Problem

In v1.18, #33419 will deprecate the existing special-column keys, and start using new ones without the primary indexes. We want nodes to be able to upgrade and downgrade between minor releases as needed. But currently, when a node hits a key of the wrong length, it will panic.

Summary of Changes

Add a very abbreviated version of the ColumnIndexDeprecation trait to enable the LedgerColumn::iter_current_index_filtered() method
Implement ColumnIndexDeprecation for the TransactionStatus and AddressSignatures columns. (While #33419 also implements the trait for the TransactionMemo column, there isn't anywhere calling the iter() method against that column, so nothing that will panic on the new keys.)

@codecov
Copy link

codecov bot commented Oct 10, 2023

Codecov Report

Merging #33617 (4de996a) into v1.17 (542b53e) will decrease coverage by 0.1%.
The diff coverage is 85.2%.

@@            Coverage Diff            @@
##            v1.17   #33617     +/-   ##
=========================================
- Coverage    81.8%    81.7%   -0.1%     
=========================================
  Files         804      804             
  Lines      217987   218002     +15     
=========================================
- Hits       178319   178280     -39     
- Misses      39668    39722     +54     

Copy link
Contributor

@steviez steviez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants