Skip to content

Fix potentially wrong logic if bdk_electrum is used with other chain sources#1956

Closed
evanlinjin wants to merge 1 commit into
bitcoindevkit:masterfrom
evanlinjin:electrum_clarify
Closed

Fix potentially wrong logic if bdk_electrum is used with other chain sources#1956
evanlinjin wants to merge 1 commit into
bitcoindevkit:masterfrom
evanlinjin:electrum_clarify

Conversation

@evanlinjin
Copy link
Copy Markdown
Member

Description

bdk_electrum may have incorrect reorg-resolution (resulting in inconsistent chain state) if it is paired with other chain sources which do not batch-fetch latest blocks.

Also refactored the chain-updating logic to be more understandable.

Notes to the reviewers

This is still WIP. Needs tests, better documentation and PR description.

Changelog notice

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature

Bugfixes:

  • This pull request breaks the existing API
  • I've added tests to reproduce the issue which are now passing
  • I'm linking the issue being fixed by this PR

@evanlinjin evanlinjin self-assigned this May 14, 2025
@evanlinjin evanlinjin added the bug Something isn't working label May 14, 2025
@evanlinjin evanlinjin moved this to In Progress in BDK Chain May 14, 2025
@evanlinjin evanlinjin changed the title Fix otentially wrong logic if used with other chain sources Fix potentially wrong logic if bdk_electrum is used with other chain sources May 14, 2025
@evanlinjin
Copy link
Copy Markdown
Member Author

No longer relevant

@evanlinjin evanlinjin closed this Jul 18, 2025
@github-project-automation github-project-automation Bot moved this from In Progress to Done in BDK Chain Jul 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

1 participant