Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for "Missing processor address" error #398

Merged
merged 2 commits into from
Apr 22, 2024

Conversation

samholmes
Copy link
Contributor

@samholmes samholmes commented Apr 20, 2024

CHANGELOG

Does this branch warrant an entry to the CHANGELOG?

  • Yes
  • No

Dependencies

none

Description

none

New baselet upgrade removes the requirement for a partition argument for
`dumpData` on each baselet type. If a partition arg is not provided then
all data in the baselet instance is returned.
If scriptPubkeyByPath is written to before addressByScriptPubkey, there
is a chance that the write to addressByScriptPubkey fails or is
interrupted, causing the processor data to be incorrect (an index on
data that was never written). This appears to the user as an infamous
"Missing processor address...during initialization" error message.

We hopefully fix the issue and error for good with this change. The
change includes moving the write to scriptPubkeyByPath at the end of
the `saveAddress` processor routine. We do this with a update variable
which we declare at the start of the routine and define it only when
the update to the scriptPubkeyByPath table is necessary.

In addition to this, we reworked some of the control-flow of this
routine and modified the conditions in the control-flow for better
readability. It's important this code is maintainable and easy to
reason about.
@samholmes samholmes force-pushed the sam/investigate-missing-processor-address-error branch from 8e1af16 to 83c1412 Compare April 22, 2024 18:48
@samholmes samholmes enabled auto-merge April 22, 2024 18:49
@samholmes samholmes merged commit 116798f into master Apr 22, 2024
2 checks passed
@swansontec swansontec deleted the sam/investigate-missing-processor-address-error branch April 24, 2024 21:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants