Widen blocks.header so larger block headers can be indexed - #14
Closed
kwsantiago wants to merge 1 commit into
Closed
Widen blocks.header so larger block headers can be indexed#14kwsantiago wants to merge 1 commit into
kwsantiago wants to merge 1 commit into
Conversation
Owner
|
Thanks but already implemented here 7976b28#diff-0d1d81dbd6a8a15fc2c0bf4598b3c0583c9867ce082386be775af0f978a7dfb3 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
blocks.headerisvarchar(160), which fits exactly an 80 byte header. A chain whose headers are larger cannot be indexed: every write fails withData too long for column 'header', and$updateBlocksretries the same block indefinitely.Widens the column to 512 for both fresh installs and existing databases (schema version 112). Gated on
isBitcoinlike the neighboring migrations.varcharstores only the bytes used, so mainnet is unaffected.Verified against MariaDB 10.5.21:
varchar(160)varchar(512)varchar(512)npm run test:with-dbpasses.