In 2017 SegWit soft fork introduced consensus limit on script size MAX_STANDARD_P2WSH_SCRIPT_SIZE=10000
. With P2WSH, one could seemingly use the same script structure ("envelope") OP_FALSE OP_IF <data> OP_ENDIF
to store up to ~10Kb of data in witness. Even though taproot removed the 10Kb restriction, the vast majority of inscriptions are under that limit currently. Why did they become popular now and why the popularity is commonly associated with taproot?
-
@Poseidon OP_RETURN is a different storage solution and has 80 bytes limit– DeLorean88Commented May 10, 2023 at 6:30
2 Answers
With P2WSH, one could seemingly use the same script structure ("envelope") OP_FALSE OP_IF OP_ENDIF to store up to ~10Kb of data in witness
This is incorrect. The maximum standard witness script size for P2WSH is 3600
bytes.
-
Thanks for your answer. Where is that limit specified (code or bip)? Commented May 9, 2023 at 16:12
-
3Follow the link. :) Note this is a standardness rule specific to Bitcoin Core, not a Bitcoin consensus rule. Commented May 9, 2023 at 16:14
-
Aw... GPT-4 strikes again... i.postimg.cc/pX8YR9C1/Screenshot-2023-05-09-181726.png🤷♂️ Commented May 9, 2023 at 16:18
-
2Haha. I wonder why people keep using a tool with such a high false positive rate. It's literally even worse than sub-optimal search engines: you won't find what you're looking for but at least they'll admit it instead of making something up. Commented May 9, 2023 at 16:21
There's really no reason inscriptions couldn't have been done with SegWit v0. The only difference would be that large inscriptions would have to be split across multiple inputs, making the construction slightly more expensive. Pre-SegWit you'd have to use a different transaction field for inscriptions and you couldn't use the witness discount, but methods of embedding arbitrary data in the chain have existed basically since the beginning of Bitcoin.
The lifting of that 10,000 byte script size limit, coupled with the fact that the currently used inscription standard requires that Taproot be used, is the likely reason it's associated with (and sometimes wrongly blamed for) inscriptions.