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

P2TR support #7

Merged
merged 3 commits into from
Dec 6, 2023
Merged

P2TR support #7

merged 3 commits into from
Dec 6, 2023

Conversation

octobocto
Copy link
Collaborator

  • proto: add taproot to script types
  • src: maybe add taproot support

@torkelrogstad
Copy link
Collaborator

Would love some tests here

@@ -95,6 +95,7 @@ data class Script(private val script: ScriptType) {
// operators, and replace this `when` block with something that returns
// a list of operators. For another day.
ScriptType.SCRIPT_TYPE_WPKH_NESTED -> "sh(wpkh"
ScriptType.SCRIPT_TYPE_P2TR -> "p2tr"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

have no idea if this is correct (or how to test it)

@torkelrogstad
Copy link
Collaborator

Test vectors look good, but they're failing

@octobocto
Copy link
Collaborator Author

octobocto commented Nov 30, 2023

Test vectors look good, but they're failing

I'm very sure they're correct, but I think the taproot method is wrong. How can I figure out what operator to call?

wrong:

ScriptType.SCRIPT_TYPE_P2TR -> "sh(tr"

also wrong:

ScriptType.SCRIPT_TYPE_P2TR -> "tr"

@octobocto octobocto force-pushed the 2023-11-23-taproot branch 4 times, most recently from f302835 to 369eb4a Compare November 30, 2023 08:29
@torkelrogstad torkelrogstad changed the title 2023 11 23 taproot P2TR support Dec 6, 2023
@torkelrogstad torkelrogstad merged commit 52b1306 into master Dec 6, 2023
2 checks passed
@octobocto
Copy link
Collaborator Author

BADABOM!

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.

None yet

2 participants