mirror of
https://github.com/Chia-Network/chia-blockchain.git
synced 2026-08-24 02:24:23 -05:00
* Enable PEP604 Ruff rules * Fix harcoded signature in test * Hack CLVMStreamable test with note to fast follow
32 lines
770 B
Python
32 lines
770 B
Python
from __future__ import annotations
|
|
|
|
from dataclasses import dataclass
|
|
from typing import Any
|
|
|
|
from chia_rs import CoinSpend
|
|
from chia_rs.sized_bytes import bytes32
|
|
from chia_rs.sized_ints import uint32
|
|
|
|
from chia.types.blockchain_format.coin import Coin
|
|
from chia.wallet.lineage_proof import LineageProof
|
|
|
|
|
|
@dataclass(frozen=True)
|
|
class SingletonRecord:
|
|
"""
|
|
These are values that correspond to a singleton in the WalletSingletonStore
|
|
"""
|
|
|
|
coin: Coin
|
|
singleton_id: bytes32
|
|
wallet_id: uint32
|
|
parent_coinspend: CoinSpend
|
|
inner_puzzle_hash: bytes32 | None
|
|
pending: bool
|
|
removed_height: int
|
|
lineage_proof: LineageProof
|
|
custom_data: Any | None
|
|
|
|
def name(self) -> bytes32: # pragma: no cover
|
|
return self.coin.name()
|