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

TODO: added op_checksigadd to op_codes #95

Closed
wants to merge 1 commit into from

Conversation

AdvaitPote
Copy link
Contributor

@AdvaitPote AdvaitPote commented Apr 25, 2024

As per the newly added TODO, I have added OP_CHECKSIGADD to op_codes.

@karask
Copy link
Owner

karask commented Apr 26, 2024

Hi @AdvaitPote,

Unfortunately this is not that simple. That opcode is only valid for taproot. There are other differences as well. They all need to be group appropriately and checked only for tapscripts.

@AdvaitPote
Copy link
Contributor Author

Yes, you did mention in the TODO that some other tapscript changes would need to be made. So would these opcodes need to be added elsewhere along with some tapscript functionalities? Unfortunately, in all of the courses we took and our assignment, Taproot was out of scope so I am not much aware of the same. I was thinking we would add these opcodes to script.py and then add those same tapscript reading features in the Script class itself.

@karask
Copy link
Owner

karask commented Apr 27, 2024

I believe it would be cleaner if completely new dicitionaries should be used for tapscript (if the changes are many it could be a new file tapscript.py, otherwise it could go into script). Then if the specific tx's output is segwit v1 consult the new dictionary for the opcodes, otherwise use the current dictionaries.

@AdvaitPote
Copy link
Contributor Author

Makes sense! Making a new Tapscript class or a tapscript.py would be helpful too because as more updates will be made, managing them in a separate file would be more convenient.

@karask
Copy link
Owner

karask commented May 27, 2024

I am closing this for. Re-open if you want to work on it.

@karask karask closed this May 27, 2024
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