rust-bitcoin / rust-bitcoin/rust-miniscript
Introducing `Older/After` Translation functionality
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 426
- Forks
- 200
- Avg merge
- 7d 17h
- Merged PRs (30d)
- 8
Description
In the same way as #434
Up until now, we had support for key translation (and upcoming hash translations) which provide similar analysis guarantees as before. Doing the same for older/after does change things, and some of the miniscripts analysis we are able to do might not be possible. For example:- script_size requires us knowing the serialized length of the older/after time integer parameter.
Besides associating the Older type for a generic MiniscriptKey to u32, there are following possibilities we can try to offer:
- All the miniscripts are analyzable and we always keep the
type Older -> u32association. - We introduce
Analyzabletrait, and use it to store the association as above for proper analysis. (More involving to implement, but gives us more flexibility working with generic miniscripts) - We migrate the analysis requiring
older/afterparameteru32to only supportMiniscriptKey + ToPublicKey, but we might lose some flexibility here. (easier to implement)
I'm confused here and would like to know others' view on the same.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading issue #434 and the existing key and hash translation support referenced here. Resolve which of the three listed designs should govern Older/After translation and analysis, with completion defined by implementing the chosen approach while preserving the applicable Miniscript analysis guarantees.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- blockchain
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100