Chialisp file extensions (#14996)

* Rename chialisp file extensions

* Add pre-commit check for .clvm files

* Delete sha256tree files

* remove hash files in favor of central dictionary

* Add check for missing files like hex and hash entries

* Enhance clsp pre-commit check

* Actually check hash matches

* Update tools/manage_clvm.py

Co-authored-by: Kyle Altendorf <sda@fstab.net>

* Update tools/manage_clvm.py

Co-authored-by: Kyle Altendorf <sda@fstab.net>

* Fix Windows file writing

* Fix setup.py package_data fields

* Load hash dict at runtime

* Move away from exception pattern

* Bad equality check

* Minor fixes

* remove trailing whitespace fix

---------

Co-authored-by: Kyle Altendorf <sda@fstab.net>
This commit is contained in:
Matt Hauff 2023-04-18 09:27:17 -07:00 committed by GitHub
parent d9be2004c7
commit e5b94d34a0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
176 changed files with 712 additions and 673 deletions

View File

@ -23,7 +23,7 @@ repos:
hooks:
- id: check-yaml
- id: end-of-file-fixer
exclude: ".*?(.hex|.clvm|.clib)"
exclude: ".*?(.hex|.clsp|.clvm|.clib)"
- id: trailing-whitespace
- id: check-merge-conflict
- id: check-ast
@ -31,7 +31,7 @@ repos:
- repo: local
hooks:
- id: clvm_hex
name: .clvm.hex files
name: .clsp.hex files
entry: ./activated.py python tools/manage_clvm.py check
language: python
pass_filenames: false

View File

@ -2,6 +2,6 @@ from __future__ import annotations
from chia.wallet.puzzles.load_clvm import load_clvm_maybe_recompile
P2_SINGLETON_MOD = load_clvm_maybe_recompile("p2_singleton.clvm")
SINGLETON_TOP_LAYER_MOD = load_clvm_maybe_recompile("singleton_top_layer.clvm")
SINGLETON_LAUNCHER = load_clvm_maybe_recompile("singleton_launcher.clvm")
P2_SINGLETON_MOD = load_clvm_maybe_recompile("p2_singleton.clsp")
SINGLETON_TOP_LAYER_MOD = load_clvm_maybe_recompile("singleton_top_layer.clsp")
SINGLETON_LAUNCHER = load_clvm_maybe_recompile("singleton_launcher.clsp")

View File

@ -12,15 +12,15 @@ from chia.wallet.puzzles.rom_bootstrap_generator import get_generator
GENERATOR_MOD = get_generator()
DECOMPRESS_BLOCK = load_clvm_maybe_recompile("block_program_zero.clvm", package_or_requirement="chia.wallet.puzzles")
DECOMPRESS_PUZZLE = load_clvm_maybe_recompile("decompress_puzzle.clvm", package_or_requirement="chia.wallet.puzzles")
DECOMPRESS_BLOCK = load_clvm_maybe_recompile("block_program_zero.clsp", package_or_requirement="chia.wallet.puzzles")
DECOMPRESS_PUZZLE = load_clvm_maybe_recompile("decompress_puzzle.clsp", package_or_requirement="chia.wallet.puzzles")
# DECOMPRESS_CSE = load_clvm_maybe_recompile(
# "decompress_coin_spend_entry.clvm",
# "decompress_coin_spend_entry.clsp",
# package_or_requirement="chia.wallet.puzzles",
# )
DECOMPRESS_CSE_WITH_PREFIX = load_clvm_maybe_recompile(
"decompress_coin_spend_entry_with_prefix.clvm", package_or_requirement="chia.wallet.puzzles"
"decompress_coin_spend_entry_with_prefix.clsp", package_or_requirement="chia.wallet.puzzles"
)
log = logging.getLogger(__name__)

View File

@ -27,7 +27,7 @@ from chia.wallet.puzzles.rom_bootstrap_generator import get_generator
GENERATOR_MOD = get_generator()
DESERIALIZE_MOD = load_serialized_clvm_maybe_recompile(
"chialisp_deserialisation.clvm", package_or_requirement="chia.wallet.puzzles"
"chialisp_deserialisation.clsp", package_or_requirement="chia.wallet.puzzles"
)
log = logging.getLogger(__name__)

View File

@ -21,10 +21,10 @@ from chia.wallet.puzzles.singleton_top_layer import puzzle_for_singleton
log = logging.getLogger(__name__)
# "Full" is the outer singleton, with the inner puzzle filled in
SINGLETON_MOD = load_clvm_maybe_recompile("singleton_top_layer.clvm")
POOL_WAITING_ROOM_MOD = load_clvm_maybe_recompile("pool_waitingroom_innerpuz.clvm")
POOL_MEMBER_MOD = load_clvm_maybe_recompile("pool_member_innerpuz.clvm")
P2_SINGLETON_MOD = load_clvm_maybe_recompile("p2_singleton_or_delayed_puzhash.clvm")
SINGLETON_MOD = load_clvm_maybe_recompile("singleton_top_layer.clsp")
POOL_WAITING_ROOM_MOD = load_clvm_maybe_recompile("pool_waitingroom_innerpuz.clsp")
POOL_MEMBER_MOD = load_clvm_maybe_recompile("pool_member_innerpuz.clsp")
P2_SINGLETON_MOD = load_clvm_maybe_recompile("p2_singleton_or_delayed_puzhash.clsp")
POOL_OUTER_MOD = SINGLETON_MOD
POOL_MEMBER_HASH = POOL_MEMBER_MOD.get_tree_hash()

View File

@ -4,7 +4,7 @@ import enum
from typing import Any
# See chia/wallet/puzzles/condition_codes.clvm
# See chia/wallet/puzzles/condition_codes.clib
class ConditionOpcode(bytes, enum.Enum):
# AGG_SIG is ascii "1"

View File

@ -14,10 +14,10 @@ from chia.wallet.puzzles.load_clvm import load_clvm_maybe_recompile
ACS_MU = Program.to(11) # returns the third argument a.k.a the full solution
ACS_MU_PH = ACS_MU.get_tree_hash()
SINGLETON_TOP_LAYER_MOD = load_clvm_maybe_recompile("singleton_top_layer_v1_1.clvm")
SINGLETON_LAUNCHER = load_clvm_maybe_recompile("singleton_launcher.clvm")
GRAFTROOT_DL_OFFERS = load_clvm_maybe_recompile("graftroot_dl_offers.clvm")
P2_PARENT = load_clvm_maybe_recompile("p2_parent.clvm")
SINGLETON_TOP_LAYER_MOD = load_clvm_maybe_recompile("singleton_top_layer_v1_1.clsp")
SINGLETON_LAUNCHER = load_clvm_maybe_recompile("singleton_launcher.clsp")
GRAFTROOT_DL_OFFERS = load_clvm_maybe_recompile("graftroot_dl_offers.clsp")
P2_PARENT = load_clvm_maybe_recompile("p2_parent.clsp")
def create_host_fullpuz(innerpuz: Union[Program, bytes32], current_root: bytes32, genesis_id: bytes32) -> Program:

View File

@ -19,9 +19,9 @@ from chia.wallet.singleton import (
)
from chia.wallet.util.curry_and_treehash import calculate_hash_of_quoted_mod_hash, curry_and_treehash
DID_INNERPUZ_MOD = load_clvm_maybe_recompile("did_innerpuz.clvm")
DID_INNERPUZ_MOD = load_clvm_maybe_recompile("did_innerpuz.clsp")
DID_INNERPUZ_MOD_HASH = DID_INNERPUZ_MOD.get_tree_hash()
INTERMEDIATE_LAUNCHER_MOD = load_clvm_maybe_recompile("nft_intermediate_launcher.clvm")
INTERMEDIATE_LAUNCHER_MOD = load_clvm_maybe_recompile("nft_intermediate_launcher.clsp")
def create_innerpuz(

View File

@ -11,7 +11,7 @@ from chia.wallet.puzzle_drivers import PuzzleInfo, Solver
from chia.wallet.puzzles.load_clvm import load_clvm_maybe_recompile
from chia.wallet.uncurried_puzzle import UncurriedPuzzle, uncurry_puzzle
NFT_STATE_LAYER_MOD = load_clvm_maybe_recompile("nft_state_layer.clvm")
NFT_STATE_LAYER_MOD = load_clvm_maybe_recompile("nft_state_layer.clsp")
NFT_STATE_LAYER_MOD_HASH = NFT_STATE_LAYER_MOD.get_tree_hash()

View File

@ -11,7 +11,7 @@ from chia.util.streamable import Streamable, streamable
from chia.wallet.lineage_proof import LineageProof
from chia.wallet.puzzles.load_clvm import load_clvm_maybe_recompile
LAUNCHER_PUZZLE = load_clvm_maybe_recompile("singleton_launcher.clvm")
LAUNCHER_PUZZLE = load_clvm_maybe_recompile("singleton_launcher.clsp")
IN_TRANSACTION_STATUS = "IN_TRANSACTION"
DEFAULT_STATUS = "DEFAULT"

View File

@ -18,26 +18,26 @@ from chia.wallet.puzzles.p2_delegated_puzzle_or_hidden_puzzle import solution_fo
from chia.wallet.util.address_type import AddressType
log = logging.getLogger(__name__)
SINGLETON_TOP_LAYER_MOD = load_clvm_maybe_recompile("singleton_top_layer_v1_1.clvm")
LAUNCHER_PUZZLE = load_clvm_maybe_recompile("singleton_launcher.clvm")
NFT_STATE_LAYER_MOD = load_clvm_maybe_recompile("nft_state_layer.clvm")
SINGLETON_TOP_LAYER_MOD = load_clvm_maybe_recompile("singleton_top_layer_v1_1.clsp")
LAUNCHER_PUZZLE = load_clvm_maybe_recompile("singleton_launcher.clsp")
NFT_STATE_LAYER_MOD = load_clvm_maybe_recompile("nft_state_layer.clsp")
LAUNCHER_PUZZLE_HASH = LAUNCHER_PUZZLE.get_tree_hash()
SINGLETON_MOD_HASH = SINGLETON_TOP_LAYER_MOD.get_tree_hash()
NFT_STATE_LAYER_MOD_HASH = NFT_STATE_LAYER_MOD.get_tree_hash()
NFT_METADATA_UPDATER = load_clvm_maybe_recompile("nft_metadata_updater_default.clvm")
NFT_OWNERSHIP_LAYER = load_clvm_maybe_recompile("nft_ownership_layer.clvm")
NFT_METADATA_UPDATER = load_clvm_maybe_recompile("nft_metadata_updater_default.clsp")
NFT_OWNERSHIP_LAYER = load_clvm_maybe_recompile("nft_ownership_layer.clsp")
NFT_OWNERSHIP_LAYER_HASH = NFT_OWNERSHIP_LAYER.get_tree_hash()
NFT_TRANSFER_PROGRAM_DEFAULT = load_clvm_maybe_recompile(
"nft_ownership_transfer_program_one_way_claim_with_royalties.clvm",
"nft_ownership_transfer_program_one_way_claim_with_royalties.clsp",
)
STANDARD_PUZZLE_MOD = load_clvm_maybe_recompile("p2_delegated_puzzle_or_hidden_puzzle.clvm")
INTERMEDIATE_LAUNCHER_MOD = load_clvm_maybe_recompile("nft_intermediate_launcher.clvm")
STANDARD_PUZZLE_MOD = load_clvm_maybe_recompile("p2_delegated_puzzle_or_hidden_puzzle.clsp")
INTERMEDIATE_LAUNCHER_MOD = load_clvm_maybe_recompile("nft_intermediate_launcher.clsp")
def create_nft_layer_puzzle_with_curry_params(
metadata: Program, metadata_updater_hash: bytes32, inner_puzzle: Program
) -> Program:
"""Curries params into nft_state_layer.clvm
"""Curries params into nft_state_layer.clsp
Args to curry:
NFT_STATE_LAYER_MOD_HASH

View File

@ -11,7 +11,7 @@ from chia.wallet.puzzle_drivers import PuzzleInfo, Solver
from chia.wallet.puzzles.load_clvm import load_clvm_maybe_recompile
from chia.wallet.uncurried_puzzle import UncurriedPuzzle, uncurry_puzzle
OWNERSHIP_LAYER_MOD = load_clvm_maybe_recompile("nft_ownership_layer.clvm")
OWNERSHIP_LAYER_MOD = load_clvm_maybe_recompile("nft_ownership_layer.clsp")
def match_ownership_layer_puzzle(puzzle: UncurriedPuzzle) -> Tuple[bool, List[Program]]:

View File

@ -11,7 +11,7 @@ from chia.wallet.puzzles.load_clvm import load_clvm_maybe_recompile
from chia.wallet.puzzles.singleton_top_layer_v1_1 import SINGLETON_LAUNCHER_HASH, SINGLETON_MOD_HASH
from chia.wallet.uncurried_puzzle import UncurriedPuzzle
TRANSFER_PROGRAM_MOD = load_clvm_maybe_recompile("nft_ownership_transfer_program_one_way_claim_with_royalties.clvm")
TRANSFER_PROGRAM_MOD = load_clvm_maybe_recompile("nft_ownership_transfer_program_one_way_claim_with_royalties.clsp")
def match_transfer_program_puzzle(puzzle: UncurriedPuzzle) -> Tuple[bool, List[Program]]:

View File

@ -10,9 +10,9 @@ from chia.util.ints import uint16
from chia.wallet.puzzles.load_clvm import load_clvm_maybe_recompile
log = logging.getLogger(__name__)
SINGLETON_TOP_LAYER_MOD = load_clvm_maybe_recompile("singleton_top_layer_v1_1.clvm")
NFT_MOD = load_clvm_maybe_recompile("nft_state_layer.clvm")
NFT_OWNERSHIP_LAYER = load_clvm_maybe_recompile("nft_ownership_layer.clvm")
SINGLETON_TOP_LAYER_MOD = load_clvm_maybe_recompile("singleton_top_layer_v1_1.clsp")
NFT_MOD = load_clvm_maybe_recompile("nft_state_layer.clsp")
NFT_OWNERSHIP_LAYER = load_clvm_maybe_recompile("nft_ownership_layer.clsp")
_T_UncurriedNFT = TypeVar("_T_UncurriedNFT", bound="UncurriedNFT")

View File

@ -1 +0,0 @@
f0a38c8efe58895ae527c65c37f700a4238504691b83990e5dd91bd8b3c30eae

View File

@ -1 +0,0 @@
624c5d5704d0decadfc0503e71bbffb6cdfe45025bce7cf3e6864d1eafe8f65e

View File

@ -2,7 +2,6 @@ from __future__ import annotations
from chia.wallet.puzzles.load_clvm import load_clvm_maybe_recompile
CAT_MOD = load_clvm_maybe_recompile("cat_v2.clvm", package_or_requirement=__name__)
LOCK_INNER_PUZZLE = load_clvm_maybe_recompile("lock.inner.puzzle.clvm", package_or_requirement=__name__)
CAT_MOD = load_clvm_maybe_recompile("cat_v2.clsp", package_or_requirement=__name__)
CAT_MOD_HASH = CAT_MOD.get_tree_hash()

View File

@ -106,8 +106,8 @@
;;;;; start library code
(include condition_codes.clvm)
(include curry-and-treehash.clinc)
(include condition_codes.clib)
(include curry-and-treehash.clib)
(include cat_truths.clib)
(include utility_macros.clib)

View File

@ -1 +0,0 @@
37bef360ee858133b69d595a906dc45d01af50379dad515eb9518abb7c1d2a7a

View File

@ -1 +0,0 @@
94ec19077f9a34e0b11ad2456af0170f4cc03f11230ca42e3f82e6e644ac4f5d

View File

@ -1,5 +1,5 @@
(mod (LAUNCHER_PH MINT_NUMBER MINT_TOTAL)
(include condition_codes.clvm)
(include condition_codes.clib)
(list
(list CREATE_COIN LAUNCHER_PH 1)
(list CREATE_COIN_ANNOUNCEMENT (sha256 MINT_NUMBER MINT_TOTAL)))

View File

@ -1 +0,0 @@
7a32d2d9571d3436791c0ad3d7fcfdb9c43ace2b0f0ff13f98d29f0cc093f445

View File

@ -1 +0,0 @@
9d98ed08770d31be4bd1bde4705dab388db5e7e9c349f5a76fc3c347aa3a0b79

View File

@ -1 +0,0 @@
92aa4bc8060a8836355a1884075141b4791ce1b67ae6092bb166b2845954bc89

View File

@ -1 +0,0 @@
fe94c58f1117afe315e0450daca1c62460ec1a1c439cd4018d79967a5d7d1370

View File

@ -1,4 +1,4 @@
; This is a "limitations_program" for use with cat.clvm.
; This is a "limitations_program" for use with cat.clsp.
(mod (
PUBKEY
Truths
@ -12,7 +12,7 @@
)
)
(include condition_codes.clvm)
(include condition_codes.clib)
(defun sha256tree1 (TREE)
(if (l TREE)

View File

@ -1 +0,0 @@
999c3696e167f8a79d938adc11feba3a3dcb39ccff69a426d570706e7b8ec399

View File

@ -0,0 +1,43 @@
{
"block_program_zero": "f0a38c8efe58895ae527c65c37f700a4238504691b83990e5dd91bd8b3c30eae",
"calculate_synthetic_public_key": "624c5d5704d0decadfc0503e71bbffb6cdfe45025bce7cf3e6864d1eafe8f65e",
"cat_v2": "37bef360ee858133b69d595a906dc45d01af50379dad515eb9518abb7c1d2a7a",
"chialisp_deserialisation": "94ec19077f9a34e0b11ad2456af0170f4cc03f11230ca42e3f82e6e644ac4f5d",
"create_nft_launcher_from_did": "7a32d2d9571d3436791c0ad3d7fcfdb9c43ace2b0f0ff13f98d29f0cc093f445",
"decompress_coin_spend_entry": "9d98ed08770d31be4bd1bde4705dab388db5e7e9c349f5a76fc3c347aa3a0b79",
"decompress_coin_spend_entry_with_prefix": "92aa4bc8060a8836355a1884075141b4791ce1b67ae6092bb166b2845954bc89",
"decompress_puzzle": "fe94c58f1117afe315e0450daca1c62460ec1a1c439cd4018d79967a5d7d1370",
"delegated_tail": "999c3696e167f8a79d938adc11feba3a3dcb39ccff69a426d570706e7b8ec399",
"did_innerpuz": "33143d2bef64f14036742673afd158126b94284b4530a28c354fac202b0c910e",
"everything_with_signature": "1720d13250a7c16988eaf530331cefa9dd57a76b2c82236bec8bbbff91499b89",
"genesis_by_coin_id": "493afb89eed93ab86741b2aa61b8f5de495d33ff9b781dfc8919e602b2afa150",
"genesis_by_puzzle_hash": "de5a6e06d41518be97ff6365694f4f89475dda773dede267caa33da63b434e36",
"graftroot_dl_offers": "0893e36a88c064fddfa6f8abdb42c044584a98cb4273b80cccc83b4867b701a1",
"nft_intermediate_launcher": "7a32d2d9571d3436791c0ad3d7fcfdb9c43ace2b0f0ff13f98d29f0cc093f445",
"nft_metadata_updater_default": "fe8a4b4e27a2e29a4d3fc7ce9d527adbcaccbab6ada3903ccf3ba9a769d2d78b",
"nft_metadata_updater_updateable": "0b1ffba1601777c06b78ab38636e9624f2f8da73be9b36e0ce17c8d8ef3bad9f",
"nft_ownership_layer": "c5abea79afaa001b5427dfa0c8cf42ca6f38f5841b78f9b3c252733eb2de2726",
"nft_ownership_transfer_program_one_way_claim_with_royalties": "025dee0fb1e9fa110302a7e9bfb6e381ca09618e2778b0184fa5c6b275cfce1f",
"nft_state_layer": "a04d9f57764f54a43e4030befb4d80026e870519aaa66334aef8304f5d0393c2",
"notification": "b8b9d8ffca6d5cba5422ead7f477ecfc8f6aaaa1c024b8c3aeb1956b24a0ab1e",
"p2_conditions": "1c77d7d5efde60a7a1d2d27db6d746bc8e568aea1ef8586ca967a0d60b83cc36",
"p2_delegated_conditions": "0ff94726f1a8dea5c3f70d3121945190778d3b2b3fcda3735a1f290977e98341",
"p2_delegated_puzzle": "542cde70d1102cd1b763220990873efc8ab15625ded7eae22cc11e21ef2e2f7c",
"p2_delegated_puzzle_or_hidden_puzzle": "e9aaa49f45bad5c889b86ee3341550c155cfdd10c3a6757de618d20612fffd52",
"p2_m_of_n_delegate_direct": "0f199d5263ac1a62b077c159404a71abd3f9691cc57520bf1d4c5cb501504457",
"p2_parent": "b10ce2d0b18dcf8c21ddfaf55d9b9f0adcbf1e0beb55b1a8b9cad9bbff4e5f22",
"p2_puzzle_hash": "13e29a62b42cd2ef72a79e4bacdc59733ca6310d65af83d349360d36ec622363",
"p2_singleton": "40f828d8dd55603f4ff9fbf6b73271e904e69406982f4fbefae2c8dcceaf9834",
"p2_singleton_or_delayed_puzhash": "adb656e0211e2ab4f42069a4c5efc80dc907e7062be08bf1628c8e5b6d94d25b",
"pool_member_innerpuz": "a8490702e333ddd831a3ac9c22d0fa26d2bfeaf2d33608deb22f0e0123eb0494",
"pool_waitingroom_innerpuz": "a317541a765bf8375e1c6e7c13503d0d2cbf56cacad5182befe947e78e2c0307",
"rom_bootstrap_generator": "161bade1f822dcd62ab712ebaf30f3922a301e48a639e4295c5685f8bece7bd9",
"settlement_payments": "cfbfdeed5c4ca2de3d0bf520b9cb4bb7743a359bd2e6a188d19ce7dffc21d3e7",
"settlement_payments_old": "bae24162efbd568f89bc7a340798a6118df0189eb9e3f8697bcea27af99f8f79",
"sha256tree_module": "eb4ead6576048c9d730b5ced00646c7fdd390649cfdf48a00de1590cdd8ee18f",
"singleton_launcher": "eff07522495060c066f66f32acc2a77e3a3e737aca8baea4d1a64ea4cdc13da9",
"singleton_top_layer": "24e044101e57b3d8c908b8a38ad57848afd29d3eecc439dba45f4412df4954fd",
"singleton_top_layer_v1_1": "7faa3253bfddd1e0decb0906b2dc6247bbc4cf608f58345d173adb63e8b47c9f",
"test_generator_deserialize": "52add794fc76e89512e4a063c383418bda084c8a78c74055abe80179e4a7832c",
"test_multiple_generator_input_arguments": "156dafbddc3e1d3bfe1f2a84e48e5e46b287b8358bf65c3c091c93e855fbfc5b"
}

View File

@ -24,8 +24,8 @@
;MOD_HASH, MY_PUBKEY, RECOVERY_DID_LIST_HASH are curried into the puzzle
;EXAMPLE SOLUTION (0xcafef00d 0x12341234 0x923bf9a7856b19d335a65f12d68957d497e1f0c16c0e14baf6d120e60753a1ce 2 1 100 (q "source code") 0xdeadbeef 0xcafef00d ((0xdadadada 0xdad5dad5 200) () (0xfafafafa 0xfaf5faf5 200)) 0xfadeddab (0x22222222 0x33333333 0x44444444))
(include condition_codes.clvm)
(include curry-and-treehash.clinc)
(include condition_codes.clib)
(include curry-and-treehash.clib)
; takes a lisp tree and returns the hash of it
(defun sha256tree1 (TREE)
@ -52,7 +52,7 @@
; return the full puzzlehash for a singleton with the innerpuzzle curried in
; puzzle-hash-of-curried-function is imported from curry-and-treehash.clinc
; puzzle-hash-of-curried-function is imported from curry-and-treehash.clib
(defun-inline calculate_full_puzzle_hash (SINGLETON_STRUCT inner_puzzle_hash)
(puzzle-hash-of-curried-function (f SINGLETON_STRUCT)
inner_puzzle_hash

View File

@ -1 +0,0 @@
33143d2bef64f14036742673afd158126b94284b4530a28c354fac202b0c910e

View File

@ -1,4 +1,4 @@
; This is a "limitations_program" for use with cat.clvm.
; This is a "limitations_program" for use with cat.clsp.
(mod (
PUBKEY
Truths
@ -9,7 +9,7 @@
_
)
(include condition_codes.clvm)
(include condition_codes.clib)
(list (list AGG_SIG_ME PUBKEY delta)) ; Careful with a delta of zero, the bytecode is 80 not 00
)

View File

@ -1 +0,0 @@
1720d13250a7c16988eaf530331cefa9dd57a76b2c82236bec8bbbff91499b89

View File

@ -1 +0,0 @@
493afb89eed93ab86741b2aa61b8f5de495d33ff9b781dfc8919e602b2afa150

View File

@ -1,4 +1,4 @@
; This is a "limitations_program" for use with cat.clvm.
; This is a "limitations_program" for use with cat.clsp.
;
; This checker allows new CATs to be created if their parent has a particular puzzle hash
(mod (

View File

@ -1 +0,0 @@
de5a6e06d41518be97ff6365694f4f89475dda773dede267caa33da63b434e36

View File

@ -11,9 +11,9 @@
inner_solution
)
(include condition_codes.clvm)
(include condition_codes.clib)
(include merkle_utils.clib)
(include curry-and-treehash.clinc)
(include curry-and-treehash.clib)
(defmacro assert items
(if (r items)

View File

@ -1 +0,0 @@
0893e36a88c064fddfa6f8abdb42c044584a98cb4273b80cccc83b4867b701a1

View File

@ -82,8 +82,8 @@ def load_serialized_clvm(
clvm_filename, package_or_requirement=__name__, include_standard_libraries: bool = False, recompile: bool = True
) -> SerializedProgram:
"""
This function takes a .clvm file in the given package and compiles it to a
.clvm.hex file if the .hex file is missing or older than the .clvm file, then
This function takes a .clsp file in the given package and compiles it to a
.clsp.hex file if the .hex file is missing or older than the .clsp file, then
returns the contents of the .hex file as a `Program`.
clvm_filename: file name

View File

@ -1,2 +0,0 @@
; a trivial puzzle used as the core of a lock puzzle
(mod args (q ()))

View File

@ -1 +0,0 @@
ff01ff8080

View File

@ -1 +0,0 @@
f3a579254623f8094e07af862df2e45c9db5592b4105d34a256dd6c498416288

View File

@ -1,5 +1,5 @@
(mod (LAUNCHER_PH MINT_NUMBER MINT_TOTAL)
(include condition_codes.clvm)
(include condition_codes.clib)
(list
(list CREATE_COIN LAUNCHER_PH 1)
(list CREATE_COIN_ANNOUNCEMENT (sha256 MINT_NUMBER MINT_TOTAL)))

View File

@ -1 +0,0 @@
7a32d2d9571d3436791c0ad3d7fcfdb9c43ace2b0f0ff13f98d29f0cc093f445

View File

@ -1 +0,0 @@
fe8a4b4e27a2e29a4d3fc7ce9d527adbcaccbab6ada3903ccf3ba9a769d2d78b

View File

@ -1 +0,0 @@
0b1ffba1601777c06b78ab38636e9624f2f8da73be9b36e0ce17c8d8ef3bad9f

View File

@ -6,8 +6,8 @@
inner_solution
)
(include condition_codes.clvm)
(include curry-and-treehash.clinc)
(include condition_codes.clib)
(include curry-and-treehash.clib)
(include utility_macros.clib)
(defconstant NEW_OWNER_CONDITION -10)

View File

@ -1 +0,0 @@
c5abea79afaa001b5427dfa0c8cf42ca6f38f5841b78f9b3c252733eb2de2726

View File

@ -10,13 +10,13 @@
; This is a transfer program - which must return (new_owner, Optional[new_transfer_program], conditions)
(include condition_codes.clvm)
(include curry-and-treehash.clinc)
(include condition_codes.clib)
(include curry-and-treehash.clib)
(defconstant TEN_THOUSAND 10000)
;; return the full puzzlehash for a singleton with the innerpuzzle curried in
; puzzle-hash-of-curried-function is imported from curry-and-treehash.clinc
; puzzle-hash-of-curried-function is imported from curry-and-treehash.clib
(defun-inline calculate_full_puzzle_hash (SINGLETON_STRUCT inner_puzzle_hash)
(puzzle-hash-of-curried-function (f SINGLETON_STRUCT)
inner_puzzle_hash

View File

@ -1 +0,0 @@
025dee0fb1e9fa110302a7e9bfb6e381ca09618e2778b0184fa5c6b275cfce1f

View File

@ -6,8 +6,8 @@
inner_solution
)
(include condition_codes.clvm)
(include curry-and-treehash.clinc)
(include condition_codes.clib)
(include curry-and-treehash.clib)
(include utility_macros.clib)
(defun-inline nft_state_layer_puzzle_hash (NFT_STATE_LAYER_MOD_HASH METADATA METADATA_UPDATER_PUZZLE_HASH inner_puzzle_hash)

View File

@ -1 +0,0 @@
a04d9f57764f54a43e4030befb4d80026e870519aaa66334aef8304f5d0393c2

View File

@ -2,6 +2,6 @@
TARGET
AMOUNT
)
(include condition_codes.clvm)
(include condition_codes.clib)
(list (list CREATE_COIN TARGET AMOUNT) (list CREATE_COIN_ANNOUNCEMENT ()))
)

View File

@ -1 +0,0 @@
b8b9d8ffca6d5cba5422ead7f477ecfc8f6aaaa1c024b8c3aeb1956b24a0ab1e

View File

@ -1 +0,0 @@
1c77d7d5efde60a7a1d2d27db6d746bc8e568aea1ef8586ca967a0d60b83cc36

View File

@ -16,7 +16,7 @@ from chia.types.blockchain_format.program import Program
from .load_clvm import load_clvm_maybe_recompile
MOD = load_clvm_maybe_recompile("p2_conditions.clvm")
MOD = load_clvm_maybe_recompile("p2_conditions.clsp")
def puzzle_for_conditions(conditions) -> Program:

View File

@ -1,7 +1,7 @@
(mod
(public_key conditions)
(include condition_codes.clvm)
(include condition_codes.clib)
;; hash a tree
;; This is used to calculate a puzzle hash given a puzzle program.

View File

@ -1 +0,0 @@
0ff94726f1a8dea5c3f70d3121945190778d3b2b3fcda3735a1f290977e98341

View File

@ -12,7 +12,7 @@ from chia.types.blockchain_format.program import Program
from .load_clvm import load_clvm_maybe_recompile
MOD = load_clvm_maybe_recompile("p2_delegated_conditions.clvm")
MOD = load_clvm_maybe_recompile("p2_delegated_conditions.clsp")
def puzzle_for_pk(public_key: Program) -> Program:

View File

@ -2,7 +2,7 @@
(public_key delegated_puzzle delegated_puzzle_solution)
(include condition_codes.clvm)
(include condition_codes.clib)
;; hash a tree
;; This is used to calculate a puzzle hash given a puzzle program.

View File

@ -1 +0,0 @@
542cde70d1102cd1b763220990873efc8ab15625ded7eae22cc11e21ef2e2f7c

View File

@ -19,7 +19,7 @@ from chia.types.blockchain_format.program import Program
from . import p2_conditions
from .load_clvm import load_clvm_maybe_recompile
MOD = load_clvm_maybe_recompile("p2_delegated_puzzle.clvm")
MOD = load_clvm_maybe_recompile("p2_delegated_puzzle.clsp")
def puzzle_for_pk(public_key: bytes) -> Program:

View File

@ -47,7 +47,7 @@
)
)
(include condition_codes.clvm)
(include condition_codes.clib)
;; hash a tree
;; This is used to calculate a puzzle hash given a puzzle program.

Some files were not shown because too many files have changed in this diff Show More