Page MenuHomePhabricator

test: Add edge case of pruning up to index height
AbandonedPublic

Authored by PiRK on Mar 8 2022, 15:02.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Summary

This adds a test for an edge case that caused an intermittent bug for Bitcoin Core. The bug should not affect Bitcoin ABC, as the fix was squashed with the feature in D11145.

The number of blocks to generate and to prune had to be adjusted for the test to work, because we can fit more block per blk?????.dat file (no witness data in our coinbase transaction) and pruning removes blocks from entire files at once.

This concludes backport of core#23365
https://github.com/bitcoin/bitcoin/pull/23365/commits/9600ea01450b0d39be90eb2971c1ac5c9b69a66e

Depends on D11146

Test Plan

ninja check-functional

Diff Detail

Event Timeline

PiRK requested review of this revision.Mar 8 2022, 15:02

Tail of the build log:

Build 'Bitcoin ABC Diffs / Diff Testing' #43667, branch 'refs/tags/phabricator/diff/32635'
Triggered 2022-03-08 15:02:12 by 'Phabricator Staging (phabricator-staging)'
Started 2022-03-08 15:02:14 on agent 'buildagent1'
Finished 2022-03-08 15:02:23 with status FAILURE 'Snapshot dependency failed to start: Automated Deployments / Bitcoin ABC Infra / Bitcoin-ABC Infra Checkout'
VCS revisions: 'BitcoinABC_BitcoinAbcStaging' (Git, instance id 5): 'N/A' (checkout rules: '+:. => ./bitcoin-abc')
TeamCity URL https://build.bitcoinabc.org/viewLog.html?buildId=364192&buildTypeId=BitcoinABC_BitcoinAbcStaging 
TeamCity server version is 2019.2.4 (build 72059), server timezone: GMT (UTC)

[15:02:12]E: bt15 (running for 11s)
[15:02:12]i: TeamCity server version is 2019.2.4 (build 72059)
[15:02:12] : Collecting changes in 2 VCS roots
[15:02:12] :	 [Collecting changes in 2 VCS roots] VCS Root details
[15:02:12] :		 [VCS Root details] "Bitcoin ABC Staging" {instance id=5, parent internal id=3, parent id=BitcoinABC_BitcoinAbcStaging, description: "ssh://vcs@reviews.bitcoinabc.org:2221/source/bitcoin-abc-staging.git#refs/heads/master"}
[15:02:12] :		 [VCS Root details] "abc-infrastructure" {instance id=7, parent internal id=7, parent id=AutomatedDeployments_BitcoinAbcDeveloperTools_AbcInfrastructure, description: "ssh://vcs@reviews.bitcoinabc.org:2221/source/infrastructure.git#refs/heads/master"}
[15:02:14] : The build is removed from the queue to be prepared for the start
[15:02:23]W: This build has not been started because some of the builds it depends on failed to start
[15:02:23]E: Snapshot dependency "Automated Deployments / Bitcoin ABC Infra / Bitcoin-ABC Infra Checkout" failed
[15:02:23] : Build finished

Tail of the build log:

Build 'Bitcoin ABC Diffs / Diff Testing' #43670, branch 'refs/tags/phabricator/diff/32635'
Triggered 2022-03-08 15:02:12 by 'Phabricator Staging (phabricator-staging)'
Started 2022-03-08 15:02:17 on agent 'buildagent3'
Finished 2022-03-08 15:02:25 with status FAILURE 'Snapshot dependency failed to start: Automated Deployments / Bitcoin ABC Infra / Bitcoin-ABC Infra Checkout'
VCS revisions: 'BitcoinABC_BitcoinAbcStaging' (Git, instance id 5): 'N/A' (checkout rules: '+:. => ./bitcoin-abc')
TeamCity URL https://build.bitcoinabc.org/viewLog.html?buildId=364198&buildTypeId=BitcoinABC_BitcoinAbcStaging 
TeamCity server version is 2019.2.4 (build 72059), server timezone: GMT (UTC)

[15:02:12]E: bt15 (running for 13s)
[15:02:12]i: TeamCity server version is 2019.2.4 (build 72059)
[15:02:12] : Collecting changes in 2 VCS roots
[15:02:12] :	 [Collecting changes in 2 VCS roots] VCS Root details
[15:02:12] :		 [VCS Root details] "Bitcoin ABC Staging" {instance id=5, parent internal id=3, parent id=BitcoinABC_BitcoinAbcStaging, description: "ssh://vcs@reviews.bitcoinabc.org:2221/source/bitcoin-abc-staging.git#refs/heads/master"}
[15:02:12] :		 [VCS Root details] "abc-infrastructure" {instance id=7, parent internal id=7, parent id=AutomatedDeployments_BitcoinAbcDeveloperTools_AbcInfrastructure, description: "ssh://vcs@reviews.bitcoinabc.org:2221/source/infrastructure.git#refs/heads/master"}
[15:02:17] : The build is removed from the queue to be prepared for the start
[15:02:25]W: This build has not been started because some of the builds it depends on failed to start
[15:02:25]E: Snapshot dependency "Automated Deployments / Bitcoin ABC Infra / Bitcoin-ABC Infra Checkout" failed
[15:02:25] : Build finished

Tail of the build log:

Build 'Bitcoin ABC Diffs / Diff Testing' #43669, branch 'refs/tags/phabricator/diff/32635'
Triggered 2022-03-08 15:02:12 by 'Phabricator Staging (phabricator-staging)'
Started 2022-03-08 15:02:14 on agent 'buildagent7'
Finished 2022-03-08 15:02:24 with status FAILURE 'Snapshot dependency failed to start: Automated Deployments / Bitcoin ABC Infra / Bitcoin-ABC Infra Checkout'
VCS revisions: 'BitcoinABC_BitcoinAbcStaging' (Git, instance id 5): 'N/A' (checkout rules: '+:. => ./bitcoin-abc')
TeamCity URL https://build.bitcoinabc.org/viewLog.html?buildId=364200&buildTypeId=BitcoinABC_BitcoinAbcStaging 
TeamCity server version is 2019.2.4 (build 72059), server timezone: GMT (UTC)

[15:02:12]E: bt15 (running for 12s)
[15:02:12]i: TeamCity server version is 2019.2.4 (build 72059)
[15:02:12] : Collecting changes in 2 VCS roots
[15:02:12] :	 [Collecting changes in 2 VCS roots] VCS Root details
[15:02:12] :		 [VCS Root details] "Bitcoin ABC Staging" {instance id=5, parent internal id=3, parent id=BitcoinABC_BitcoinAbcStaging, description: "ssh://vcs@reviews.bitcoinabc.org:2221/source/bitcoin-abc-staging.git#refs/heads/master"}
[15:02:12] :		 [VCS Root details] "abc-infrastructure" {instance id=7, parent internal id=7, parent id=AutomatedDeployments_BitcoinAbcDeveloperTools_AbcInfrastructure, description: "ssh://vcs@reviews.bitcoinabc.org:2221/source/infrastructure.git#refs/heads/master"}
[15:02:14] : The build is removed from the queue to be prepared for the start
[15:02:24]W: This build has not been started because some of the builds it depends on failed to start
[15:02:24]E: Snapshot dependency "Automated Deployments / Bitcoin ABC Infra / Bitcoin-ABC Infra Checkout" failed
[15:02:25] : Build finished

Tail of the build log:

Build 'Bitcoin ABC Diffs / Diff Testing' #43668, branch 'refs/tags/phabricator/diff/32635'
Triggered 2022-03-08 15:02:12 by 'Phabricator Staging (phabricator-staging)'
Started 2022-03-08 15:02:14 on agent 'buildagent2'
Finished 2022-03-08 15:02:24 with status FAILURE 'Snapshot dependency failed to start: Automated Deployments / Bitcoin ABC Infra / Bitcoin-ABC Infra Checkout'
VCS revisions: 'BitcoinABC_BitcoinAbcStaging' (Git, instance id 5): 'N/A' (checkout rules: '+:. => ./bitcoin-abc')
TeamCity URL https://build.bitcoinabc.org/viewLog.html?buildId=364196&buildTypeId=BitcoinABC_BitcoinAbcStaging 
TeamCity server version is 2019.2.4 (build 72059), server timezone: GMT (UTC)

[15:02:12]E: bt15 (running for 12s)
[15:02:12]i: TeamCity server version is 2019.2.4 (build 72059)
[15:02:12] : Collecting changes in 2 VCS roots
[15:02:12] :	 [Collecting changes in 2 VCS roots] VCS Root details
[15:02:12] :		 [VCS Root details] "Bitcoin ABC Staging" {instance id=5, parent internal id=3, parent id=BitcoinABC_BitcoinAbcStaging, description: "ssh://vcs@reviews.bitcoinabc.org:2221/source/bitcoin-abc-staging.git#refs/heads/master"}
[15:02:12] :		 [VCS Root details] "abc-infrastructure" {instance id=7, parent internal id=7, parent id=AutomatedDeployments_BitcoinAbcDeveloperTools_AbcInfrastructure, description: "ssh://vcs@reviews.bitcoinabc.org:2221/source/infrastructure.git#refs/heads/master"}
[15:02:14] : The build is removed from the queue to be prepared for the start
[15:02:24]W: This build has not been started because some of the builds it depends on failed to start
[15:02:24]E: Snapshot dependency "Automated Deployments / Bitcoin ABC Infra / Bitcoin-ABC Infra Checkout" failed
[15:02:25] : Build finished
Fabien requested changes to this revision.Mar 10 2022, 09:51
Fabien added a subscriber: Fabien.

As per your summary: you added the feature in D11145, this is where the test should be

This revision now requires changes to proceed.Mar 10 2022, 09:51