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

Wallet::get_address should return an Result #996

Closed
LLFourn opened this issue May 28, 2023 · 5 comments · Fixed by #1028
Closed

Wallet::get_address should return an Result #996

LLFourn opened this issue May 28, 2023 · 5 comments · Fixed by #1028
Assignees
Milestone

Comments

@LLFourn
Copy link
Contributor

LLFourn commented May 28, 2023

Since the persistent backend is fallible. There are expect("TODO") in there now which seem to have slipped through the cracks. It would be good to differentiate between those calls that are fallible and those that are infallible.
I think AddressIndex should go in favor of different methods that return different addresses since the error cases seem to be different.

I think with an infallible persistence backend we can have new_address but if it's fallible then it should be try_new_address and return a Result.

cc @notmandatory. IIRC you were thinking about how to redesign this.

@nondiremanuel
Copy link

Is this part of 1.0 version or should I assign it to maintenance?

@LLFourn LLFourn added this to the 1.0.0 milestone Jun 7, 2023
@LLFourn
Copy link
Contributor Author

LLFourn commented Jun 7, 2023

Thanks i put 1.0.0 on now.

@nondiremanuel nondiremanuel moved this to In Progress in BDK Jun 14, 2023
@nondiremanuel nondiremanuel removed this from the 1.0.0 milestone Jun 19, 2023
@nondiremanuel
Copy link

@LLFourn FYI I removed the 1.0.0 milestone both from this and from the #1005 issue since we are using the Project "BDK 1.0" for issues / PRs related in general to 1.0 version. We use the milestones (alpha.1, alpha.2 ...) to signal the "sub-version" in which the specific ticket will eventually be delivered in

@LLFourn LLFourn added this to the 1.0.0-alpha.1 milestone Jul 5, 2023
@LLFourn
Copy link
Contributor Author

LLFourn commented Jul 5, 2023

This should be fixed before 1.0.0-alpha.1. at least the expect("TODO") bits. A redesign can come in a further release so we just need a small quick fix for now.

@notmandatory
Copy link
Member

Removed from alpha.1, can see if able to get enough review for alpha.2.

@notmandatory notmandatory added this to the 1.0.0-alpha.3 milestone Nov 12, 2023
@notmandatory notmandatory moved this from In Progress to Needs Review in BDK Nov 12, 2023
@github-project-automation github-project-automation bot moved this from Needs Review to Done in BDK Nov 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants