repo
stringlengths
7
90
file_url
stringlengths
81
315
file_path
stringlengths
4
228
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 14:38:15
2026-01-05 02:33:18
truncated
bool
2 classes
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/default_root.py
flax/util/default_root.py
from __future__ import annotations import os from pathlib import Path DEFAULT_ROOT_PATH = Path(os.path.expanduser(os.getenv("FLAX_ROOT", "~/.flax/mainnet"))).resolve() DEFAULT_KEYS_ROOT_PATH = Path(os.path.expanduser(os.getenv("FLAX_KEYS_ROOT", "~/.flax_keys"))).resolve()
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/__init__.py
flax/util/__init__.py
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/lru_cache.py
flax/util/lru_cache.py
from __future__ import annotations from collections import OrderedDict from typing import Generic, Optional, TypeVar K = TypeVar("K") V = TypeVar("V") class LRUCache(Generic[K, V]): def __init__(self, capacity: int): self.cache: OrderedDict[K, V] = OrderedDict() self.capacity = capacity def...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/cached_bls.py
flax/util/cached_bls.py
from __future__ import annotations import functools from typing import Dict, List, Optional, Sequence from blspy import AugSchemeMPL, G1Element, G2Element, GTElement from flax.types.blockchain_format.sized_bytes import bytes32, bytes48 from flax.util.hash import std_hash from flax.util.lru_cache import LRUCache de...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/inline_executor.py
flax/util/inline_executor.py
from __future__ import annotations from concurrent.futures import Executor, Future from typing import Callable, TypeVar _T = TypeVar("_T") class InlineExecutor(Executor): _closing: bool = False def submit(self, fn: Callable[..., _T], *args, **kwargs) -> Future[_T]: # type: ignore if self._closing:...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/ints.py
flax/util/ints.py
from __future__ import annotations from flax.util.struct_stream import StructStream, parse_metadata_from_name @parse_metadata_from_name class int8(StructStream): pass @parse_metadata_from_name class uint8(StructStream): pass @parse_metadata_from_name class int16(StructStream): pass @parse_metadata_...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/db_version.py
flax/util/db_version.py
from __future__ import annotations import sqlite3 import aiosqlite async def lookup_db_version(db: aiosqlite.Connection) -> int: try: cursor = await db.execute("SELECT * from database_version") row = await cursor.fetchone() if row is not None and row[0] == 2: return 2 ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/prev_transaction_block.py
flax/util/prev_transaction_block.py
from __future__ import annotations from typing import Tuple from flax.consensus.block_record import BlockRecord from flax.consensus.blockchain_interface import BlockchainInterface from flax.util.ints import uint128 def get_prev_transaction_block( curr: BlockRecord, blocks: BlockchainInterface, total_ite...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/significant_bits.py
flax/util/significant_bits.py
from __future__ import annotations def truncate_to_significant_bits(input_x: int, num_significant_bits: int) -> int: """ Truncates the number such that only the top num_significant_bits contain 1s. and the rest of the number is 0s (in binary). Ignores decimals and leading zeroes. For example, -0b01111...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/block_cache.py
flax/util/block_cache.py
from __future__ import annotations import logging from typing import Dict, List, Optional from flax.consensus.block_record import BlockRecord from flax.consensus.blockchain_interface import BlockchainInterface from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.blockchain_format.sub_epoch_sum...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/log_exceptions.py
flax/util/log_exceptions.py
from contextlib import contextmanager import logging import traceback @contextmanager def log_exceptions(log: logging.Logger, *, consume: bool = False): try: yield except Exception as e: log.error(f"Caught Exception: {e}. Traceback: {traceback.format_exc()}") if not consume: ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/safe_cancel_task.py
flax/util/safe_cancel_task.py
from __future__ import annotations import asyncio import logging from typing import Optional def cancel_task_safe(task: Optional[asyncio.Task], log: Optional[logging.Logger] = None): if task is not None: try: task.cancel() except Exception as e: if log is not None: ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/ws_message.py
flax/util/ws_message.py
from secrets import token_bytes from typing import Any, Dict, Optional from flax.util.json_util import dict_to_json_str from typing_extensions import TypedDict # Messages must follow this format # Message = { "command" "command_name", # "data" : {...}, # "request_id": "bytes_32", # ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/full_block_utils.py
flax/util/full_block_utils.py
from __future__ import annotations import io from dataclasses import dataclass from typing import Callable, List, Optional, Tuple from blspy import G1Element, G2Element from chia_rs import serialized_length from chiabip158 import PyBIP158 from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/vdf_prover.py
flax/util/vdf_prover.py
from __future__ import annotations from typing import Tuple from chiavdf import prove from flax.consensus.constants import ConsensusConstants from flax.types.blockchain_format.classgroup import ClassgroupElement from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.blockchain_format.vdf import...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/util/file_keyring.py
flax/util/file_keyring.py
from __future__ import annotations import base64 import contextlib import os import shutil import sys import threading from dataclasses import asdict, dataclass, field from hashlib import pbkdf2_hmac from pathlib import Path from secrets import token_bytes from typing import Any, Dict, Iterator, Optional, Union impor...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/plot_sync/receiver.py
flax/plot_sync/receiver.py
from __future__ import annotations import logging import time from dataclasses import dataclass, field from typing import Any, Awaitable, Callable, Collection, Dict, List, Optional from typing_extensions import Protocol from flax.plot_sync.delta import Delta, PathListDelta, PlotListDelta from flax.plot_sync.exceptio...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/plot_sync/util.py
flax/plot_sync/util.py
from __future__ import annotations from enum import IntEnum from typing import TypeVar from typing_extensions import Protocol from flax.protocols.harvester_protocol import PlotSyncIdentifier class Constants: message_timeout: int = 10 class State(IntEnum): idle = 0 loaded = 1 removed = 2 inval...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/plot_sync/exceptions.py
flax/plot_sync/exceptions.py
from __future__ import annotations from typing import Any from flax.plot_sync.util import ErrorCodes, State from flax.protocols.harvester_protocol import PlotSyncIdentifier from flax.server.ws_connection import NodeType from flax.util.ints import uint64 class PlotSyncException(Exception): def __init__(self, mes...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/plot_sync/sender.py
flax/plot_sync/sender.py
from __future__ import annotations import asyncio import logging import time import traceback from dataclasses import dataclass from pathlib import Path from typing import Any, Generic, Iterable, List, Optional, Tuple, Type, TypeVar from typing_extensions import Protocol from flax.plot_sync.exceptions import Already...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/plot_sync/delta.py
flax/plot_sync/delta.py
from __future__ import annotations from dataclasses import dataclass, field from typing import Dict, List, Union from flax.protocols.harvester_protocol import Plot @dataclass class DeltaType: additions: Union[Dict[str, Plot], List[str]] removals: List[str] def __str__(self) -> str: return f"+{l...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/plot_sync/__init__.py
flax/plot_sync/__init__.py
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/timelord/timelord.py
flax/timelord/timelord.py
from __future__ import annotations import asyncio import dataclasses import io import logging import multiprocessing import os import random import time import traceback from concurrent.futures import ProcessPoolExecutor from typing import Any, Callable, Dict, List, Optional, Set, Tuple from chiavdf import create_dis...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
true
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/timelord/iters_from_block.py
flax/timelord/iters_from_block.py
from __future__ import annotations from typing import Optional, Tuple, Union from flax.consensus.pot_iterations import calculate_ip_iters, calculate_iterations_quality, calculate_sp_iters from flax.types.blockchain_format.reward_chain_block import RewardChainBlock, RewardChainBlockUnfinished from flax.types.blockchai...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/timelord/timelord_state.py
flax/timelord/timelord_state.py
from __future__ import annotations import logging from typing import List, Optional, Tuple, Union from flax.consensus.constants import ConsensusConstants from flax.protocols import timelord_protocol from flax.timelord.iters_from_block import iters_from_block from flax.timelord.types import Chain, StateType from flax....
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/timelord/timelord_launcher.py
flax/timelord/timelord_launcher.py
import asyncio import logging import pathlib import signal import time import os from typing import Dict, List, Optional import pkg_resources from flax.util.flax_logging import initialize_logging from flax.util.config import load_config from flax.util.default_root import DEFAULT_ROOT_PATH from flax.util.network impor...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/timelord/__init__.py
flax/timelord/__init__.py
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/timelord/types.py
flax/timelord/types.py
from __future__ import annotations from enum import Enum class Chain(Enum): CHALLENGE_CHAIN = 1 REWARD_CHAIN = 2 INFUSED_CHALLENGE_CHAIN = 3 BLUEBOX = 4 class IterationType(Enum): SIGNAGE_POINT = 1 INFUSION_POINT = 2 END_OF_SUBSLOT = 3 class StateType(Enum): PEAK = 1 END_OF_SU...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/timelord/timelord_api.py
flax/timelord/timelord_api.py
from __future__ import annotations import logging import time from typing import Callable, Optional from flax.protocols import timelord_protocol from flax.timelord.timelord import Chain, IterationType, Timelord, iters_from_block from flax.util.api_decorators import api_request from flax.util.ints import uint64 log =...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/seeder/crawler_api.py
flax/seeder/crawler_api.py
from __future__ import annotations from typing import Optional import flax.server.ws_connection as ws from flax.protocols import full_node_protocol, wallet_protocol from flax.seeder.crawler import Crawler from flax.server.outbound_message import Message from flax.server.server import FlaxServer from flax.util.api_dec...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/seeder/crawl_store.py
flax/seeder/crawl_store.py
import asyncio import dataclasses import ipaddress import logging import random import time from typing import List, Dict import aiosqlite from flax.seeder.peer_record import PeerRecord, PeerReliability log = logging.getLogger(__name__) class CrawlStore: crawl_db: aiosqlite.Connection last_timestamp: int ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/seeder/dns_server.py
flax/seeder/dns_server.py
import asyncio import ipaddress import logging import random import signal import traceback from pathlib import Path from typing import Any, Dict, List import aiosqlite from dnslib import A, AAAA, SOA, NS, MX, CNAME, RR, DNSRecord, QTYPE, DNSHeader from flax.util.flax_logging import initialize_logging from flax.util....
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/seeder/peer_record.py
flax/seeder/peer_record.py
from __future__ import annotations import math import time from dataclasses import dataclass from flax.util.ints import uint32, uint64 from flax.util.streamable import Streamable, streamable @streamable @dataclass(frozen=True) class PeerRecord(Streamable): peer_id: str ip_address: str port: uint32 c...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/seeder/__init__.py
flax/seeder/__init__.py
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/seeder/start_crawler.py
flax/seeder/start_crawler.py
from __future__ import annotations import logging import pathlib import sys from multiprocessing import freeze_support from typing import Dict, Optional from flax.consensus.constants import ConsensusConstants from flax.consensus.default_constants import DEFAULT_CONSTANTS from flax.rpc.crawler_rpc_api import CrawlerRp...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/seeder/crawler.py
flax/seeder/crawler.py
import asyncio import logging import time import traceback import ipaddress from collections import defaultdict from pathlib import Path from typing import Any, Callable, Dict, List, Optional, Tuple import aiosqlite import flax.server.ws_connection as ws from flax.consensus.constants import ConsensusConstants from fl...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/lineage_proof.py
flax/wallet/lineage_proof.py
from dataclasses import dataclass from typing import Optional, Any, List from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.blockchain_format.program import Program from flax.util.ints import uint64 from flax.util.streamable import Streamable, streamable @streamable @dataclass(frozen=True) ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/notification_manager.py
flax/wallet/notification_manager.py
from __future__ import annotations import dataclasses import logging from typing import Any, Dict, List, Optional, Set from blspy import G2Element from flax.protocols.wallet_protocol import CoinState from flax.types.announcement import Announcement from flax.types.blockchain_format.coin import Coin from flax.types.b...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_user_store.py
flax/wallet/wallet_user_store.py
from __future__ import annotations from typing import List, Optional from flax.util.db_wrapper import DBWrapper2, execute_fetchone from flax.util.ints import uint32 from flax.wallet.util.wallet_types import WalletType from flax.wallet.wallet_info import WalletInfo class WalletUserStore: """ WalletUserStore ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_node.py
flax/wallet/wallet_node.py
import asyncio import dataclasses import logging import multiprocessing import random import sys import time import traceback from pathlib import Path from typing import Any, Callable, Dict, Iterator, List, Optional, Set, Tuple from blspy import AugSchemeMPL, PrivateKey, G2Element, G1Element from packaging.version imp...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
true
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/transaction_sorting.py
flax/wallet/transaction_sorting.py
from __future__ import annotations import enum class SortKey(enum.Enum): CONFIRMED_AT_HEIGHT = "ORDER BY confirmed_at_height {ASC}" RELEVANCE = "ORDER BY confirmed {ASC}, confirmed_at_height {DESC}, created_at_time {DESC}" def ascending(self) -> str: return self.value.format(ASC="ASC", DESC="DES...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_node_api.py
flax/wallet/wallet_node_api.py
from flax.protocols import full_node_protocol, introducer_protocol, wallet_protocol from flax.server.outbound_message import NodeType from flax.server.ws_connection import WSFlaxConnection from flax.types.mempool_inclusion_status import MempoolInclusionStatus from flax.util.api_decorators import api_request, peer_requi...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/block_record.py
flax/wallet/block_record.py
from __future__ import annotations from dataclasses import dataclass from typing import List from flax.types.blockchain_format.coin import Coin from flax.types.header_block import HeaderBlock from flax.util.streamable import Streamable, streamable @streamable @dataclass(frozen=True) class HeaderBlockRecord(Streamab...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_pool_store.py
flax/wallet/wallet_pool_store.py
import logging from typing import List, Tuple from flax.types.coin_spend import CoinSpend from flax.util.db_wrapper import DBWrapper2 from flax.util.ints import uint32 log = logging.getLogger(__name__) class WalletPoolStore: db_wrapper: DBWrapper2 @classmethod async def create(cls, wrapper: DBWrapper2)...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/trade_manager.py
flax/wallet/trade_manager.py
from __future__ import annotations import dataclasses import logging import time import traceback from typing import Any, Dict, List, Optional, Set, Tuple, Union from typing_extensions import Literal from flax.data_layer.data_layer_wallet import DataLayerWallet from flax.protocols.wallet_protocol import CoinState fr...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
true
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/derivation_record.py
flax/wallet/derivation_record.py
from __future__ import annotations from dataclasses import dataclass from blspy import G1Element from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.ints import uint32 from flax.wallet.util.wallet_types import WalletType @dataclass(frozen=True) class DerivationRecord: """ These are ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_action.py
flax/wallet/wallet_action.py
from __future__ import annotations from dataclasses import dataclass from typing import Optional from flax.util.ints import uint32 from flax.wallet.util.wallet_types import WalletType @dataclass(frozen=True) class WalletAction: """ This object represents the wallet action as it is stored in the database. ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/secret_key_store.py
flax/wallet/secret_key_store.py
from __future__ import annotations from typing import Dict, Optional from blspy import G1Element, PrivateKey GROUP_ORDER = 0x73EDA753299D7D483339D80809A1D80553BDA402FFFE5BFEFFFFFFFF00000001 class SecretKeyStore: _pk2sk: Dict[G1Element, PrivateKey] def __init__(self): self._pk2sk = {} def save...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/uncurried_puzzle.py
flax/wallet/uncurried_puzzle.py
from __future__ import annotations from dataclasses import dataclass from flax.types.blockchain_format.program import Program @dataclass(frozen=True) class UncurriedPuzzle: mod: Program args: Program def uncurry_puzzle(puzzle: Program) -> UncurriedPuzzle: return UncurriedPuzzle(*puzzle.uncurry())
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/payment.py
flax/wallet/payment.py
from dataclasses import dataclass from typing import List from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.blockchain_format.program import Program from flax.util.ints import uint64 # This class is supposed to correspond to a CREATE_COIN condition @dataclass(frozen=True) class Payment: ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet.py
flax/wallet/wallet.py
from __future__ import annotations import logging import time from typing import Any, Dict, List, Optional, Set, TYPE_CHECKING, Tuple from blspy import G1Element, G2Element, AugSchemeMPL from flax.consensus.cost_calculator import NPCResult from flax.full_node.bundle_tools import simple_solution_generator from flax.fu...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_transaction_store.py
flax/wallet/wallet_transaction_store.py
from __future__ import annotations import dataclasses import time from typing import Dict, List, Optional, Tuple from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.mempool_inclusion_status import MempoolInclusionStatus from flax.util.db_wrapper import DBWrapper2 from flax.util.errors import ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_nft_store.py
flax/wallet/wallet_nft_store.py
from __future__ import annotations import json import logging from sqlite3 import Row from typing import List, Optional, Type, TypeVar, Union from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.program import Program from flax.types.blockchain_format.sized_bytes import bytes32 from fl...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_coin_store.py
flax/wallet/wallet_coin_store.py
from typing import List, Optional, Set, Dict import sqlite3 from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.db_wrapper import DBWrapper2, execute_fetchone from flax.util.ints import uint32, uint64 from flax.wallet.util.wallet_types import ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_info.py
flax/wallet/wallet_info.py
from __future__ import annotations from dataclasses import dataclass from typing import List from flax.util.ints import uint8, uint32 from flax.util.streamable import Streamable, streamable @streamable @dataclass(frozen=True) class WalletInfo(Streamable): """ This object represents the wallet data as it is ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/flaxlisp.py
flax/wallet/flaxlisp.py
from __future__ import annotations def sexp(*argv): return f'({f" ".join([str(arg) for arg in argv])})' def cons(a, b): return sexp("c", a, b) def first(obj): return sexp("f", obj) def rest(obj): return sexp("r", obj) def nth(obj, *path): if not path: return obj if path[0] < 0:...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/derive_keys.py
flax/wallet/derive_keys.py
from typing import List, Optional, Tuple, Set from blspy import AugSchemeMPL, PrivateKey, G1Element from flax.consensus.coinbase import create_puzzlehash_for_pk from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.ints import uint32 # EIP 2334 bls key derivation # https://eips.ethereum.org/EIP...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/puzzle_drivers.py
flax/wallet/puzzle_drivers.py
from __future__ import annotations from dataclasses import dataclass from typing import Any, Dict, List, Optional from clvm.casts import int_from_bytes from clvm.SExp import SExp from clvm_tools.binutils import assemble, type_for_atom from ir.Type import Type from flax.types.blockchain_format.program import Program ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_protocol.py
flax/wallet/wallet_protocol.py
from __future__ import annotations from typing import TYPE_CHECKING, List, Optional, Set from blspy import G1Element from typing_extensions import Protocol from flax.server.ws_connection import WSFlaxConnection from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.sized_bytes import by...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/coin_selection.py
flax/wallet/coin_selection.py
from __future__ import annotations import logging import random from typing import Dict, List, Optional, Set from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.ints import uint64, uint128 from flax.wallet.wallet_coin_record import WalletCoinR...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/key_val_store.py
flax/wallet/key_val_store.py
from __future__ import annotations from typing import Any from flax.util.db_wrapper import DBWrapper2 class KeyValStore: """ Multipurpose persistent key-value store """ db_wrapper: DBWrapper2 @classmethod async def create(cls, db_wrapper: DBWrapper2): self = cls() self.db_w...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/sign_coin_spends.py
flax/wallet/sign_coin_spends.py
import inspect from typing import List, Any import blspy from blspy import AugSchemeMPL from flax.types.coin_spend import CoinSpend from flax.types.spend_bundle import SpendBundle from flax.util.condition_tools import conditions_dict_for_solution, pkm_pairs_for_conditions_dict async def sign_coin_spends( coin_s...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/__init__.py
flax/wallet/__init__.py
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_puzzle_store.py
flax/wallet/wallet_puzzle_store.py
from __future__ import annotations import asyncio import logging from typing import Dict, List, Optional, Set, Tuple from blspy import G1Element from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.db_wrapper import DBWrapper2, execute_fetchone from flax.util.ints import uint32 from flax.util....
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/driver_protocol.py
flax/wallet/driver_protocol.py
from __future__ import annotations from typing import Optional from typing_extensions import Protocol from flax.types.blockchain_format.program import Program from flax.types.blockchain_format.sized_bytes import bytes32 from flax.wallet.puzzle_drivers import PuzzleInfo, Solver from flax.wallet.uncurried_puzzle impor...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_state_manager.py
flax/wallet/wallet_state_manager.py
import aiosqlite import asyncio import json import logging import multiprocessing.context import time from collections import defaultdict from pathlib import Path from secrets import token_bytes from typing import Any, Callable, Dict, Iterator, List, Optional, Set, Tuple from blspy import G1Element, PrivateKey from f...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
true
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/notification_store.py
flax/wallet/notification_store.py
from __future__ import annotations import dataclasses import logging from typing import List, Optional, Tuple from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.db_wrapper import DBWrapper2 from flax.util.ints import uint32, uint64 @dataclasses.dataclass(frozen=True) class Notification: ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/trade_record.py
flax/wallet/trade_record.py
from dataclasses import dataclass from typing import List, Optional, Tuple, Dict, Any from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.ints import uint8, uint32, uint64 from flax.util.streamable import Streamable, streamable from flax.wallet...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_coin_record.py
flax/wallet/wallet_coin_record.py
from __future__ import annotations from dataclasses import dataclass from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.ints import uint32 from flax.wallet.util.wallet_types import WalletType @dataclass(frozen=True) class WalletCoinRecord: ...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_interested_store.py
flax/wallet/wallet_interested_store.py
from typing import List, Tuple, Optional from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.db_wrapper import DBWrapper2 from flax.util.ints import uint32 class WalletInterestedStore: """ Stores coin ids that we are interested in receiving """ db_wrapper: DBWrapper2 @cl...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/transaction_record.py
flax/wallet/transaction_record.py
from dataclasses import dataclass from typing import Generic, List, Optional, Tuple, TypeVar, Dict from flax.consensus.coinbase import pool_parent_id, farmer_parent_id from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.mempool_inclusion_statu...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_retry_store.py
flax/wallet/wallet_retry_store.py
from __future__ import annotations from typing import List, Optional, Tuple from chia_rs import CoinState from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.db_wrapper import DBWrapper2 from flax.util.ints import uint32 class WalletRetryStore: """ Persistent coin states that we hav...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_blockchain.py
flax/wallet/wallet_blockchain.py
import logging from typing import Dict, Optional, Tuple, List from flax.consensus.block_header_validation import validate_finished_header_block from flax.consensus.block_record import BlockRecord from flax.consensus.blockchain import ReceiveBlockResult from flax.consensus.blockchain_interface import BlockchainInterface...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/wallet_weight_proof_handler.py
flax/wallet/wallet_weight_proof_handler.py
import asyncio import logging import tempfile from concurrent.futures.process import ProcessPoolExecutor from multiprocessing.context import BaseContext from typing import IO, List, Tuple, Optional from flax.consensus.block_record import BlockRecord from flax.consensus.constants import ConsensusConstants from flax.ful...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/outer_puzzles.py
flax/wallet/outer_puzzles.py
from __future__ import annotations from enum import Enum from typing import Dict, Optional from flax.types.blockchain_format.program import Program from flax.types.blockchain_format.sized_bytes import bytes32 from flax.wallet.cat_wallet.cat_outer_puzzle import CATOuterPuzzle from flax.wallet.driver_protocol import Dr...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/address_type.py
flax/wallet/util/address_type.py
from __future__ import annotations from enum import Enum from typing import Any, Dict, Set from flax.util.bech32m import bech32_decode, convertbits from flax.util.config import selected_network_address_prefix class AddressType(Enum): XFX = "xfx" NFT = "nft" DID = "did:flax:" def hrp(self, config: D...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/curry_and_treehash.py
flax/wallet/util/curry_and_treehash.py
from __future__ import annotations from hashlib import sha256 from typing import Callable, List from flax.types.blockchain_format.sized_bytes import bytes32 CurryHashFunction = Callable[..., bytes32] NULL = bytes.fromhex("") ONE = bytes.fromhex("01") TWO = bytes.fromhex("02") Q_KW = bytes.fromhex("01") A_KW = byte...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/wallet_types.py
flax/wallet/util/wallet_types.py
from __future__ import annotations from enum import IntEnum from typing import List from typing_extensions import TypedDict from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.ints import uint64 class WalletType(IntEnum): # Wallet Types STANDARD_WALLET = 0 ATOMIC_SWAP = 2 AU...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/transaction_type.py
flax/wallet/util/transaction_type.py
from __future__ import annotations from enum import IntEnum class TransactionType(IntEnum): INCOMING_TX = 0 OUTGOING_TX = 1 COINBASE_REWARD = 2 FEE_REWARD = 3 INCOMING_TRADE = 4 OUTGOING_TRADE = 5
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/compute_memos.py
flax/wallet/util/compute_memos.py
from typing import List, Dict from clvm.casts import int_from_bytes from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.program import INFINITE_COST from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.coin_spend import CoinSpend from flax.types.condition_opcod...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/compute_hints.py
flax/wallet/util/compute_hints.py
from typing import List from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.condition_opcodes import ConditionOpcode from flax.types.blockchain_format.program import INFINITE_COST from flax.types.coin_spend import CoinSpend def compute_coin_hints(cs: CoinSpend) -> List[bytes32]: _, resul...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/merkle_utils.py
flax/wallet/util/merkle_utils.py
from __future__ import annotations import hashlib from typing import Any, Dict, List, Tuple from flax.types.blockchain_format.sized_bytes import bytes32 TupleTree = Any # Union[bytes32, Tuple["TupleTree", "TupleTree"]] Proof_Tree_Type = Any # Union[bytes32, Tuple[bytes32, "Proof_Tree_Type"]] HASH_TREE_PREFIX = b...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/peer_request_cache.py
flax/wallet/util/peer_request_cache.py
from __future__ import annotations import asyncio from typing import Any, Optional, Tuple from flax.protocols.wallet_protocol import CoinState from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.header_block import HeaderBlock from flax.util.hash import std_hash from flax.util.ints import uin...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/wallet_sync_utils.py
flax/wallet/util/wallet_sync_utils.py
import asyncio from flax.protocols.shared_protocol import Capability import logging import random from typing import List, Optional, Tuple, Union, Dict from chia_rs import compute_merkle_set_root from flax.consensus.constants import ConsensusConstants from flax.protocols import wallet_protocol from flax.protocols.wa...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/__init__.py
flax/wallet/util/__init__.py
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/new_peak_queue.py
flax/wallet/util/new_peak_queue.py
from __future__ import annotations import asyncio import dataclasses from enum import IntEnum from typing import Any, List from flax.protocols.wallet_protocol import CoinStateUpdate, NewPeakWallet from flax.server.ws_connection import WSFlaxConnection from flax.types.blockchain_format.sized_bytes import bytes32 cla...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/notifications.py
flax/wallet/util/notifications.py
from __future__ import annotations from flax.types.blockchain_format.program import Program from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.ints import uint64 from flax.wallet.puzzles.load_clvm import load_clvm_maybe_recompile NOTIFICATION_MOD = load_clvm_maybe_recompile("notification.clvm...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/debug_spend_bundle.py
flax/wallet/util/debug_spend_bundle.py
from typing import List from blspy import AugSchemeMPL, G1Element from clvm import KEYWORD_FROM_ATOM from clvm_tools.binutils import disassemble as bu_disassemble from flax.types.blockchain_format.coin import Coin from flax.types.blockchain_format.program import Program, INFINITE_COST from flax.consensus.default_cons...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/merkle_tree.py
flax/wallet/util/merkle_tree.py
from __future__ import annotations import math from enum import Enum from typing import List, Optional, Tuple from clvm.casts import int_to_bytes from flax.types.blockchain_format.sized_bytes import bytes32 from flax.util.hash import std_hash ONE = int_to_bytes(1) TWO = int_to_bytes(2) def hash_a_pair(left: bytes...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/puzzle_compression.py
flax/wallet/util/puzzle_compression.py
import zlib from typing import List from flax.types.blockchain_format.program import Program from flax.wallet.puzzles.load_clvm import load_clvm_maybe_recompile from flax.wallet.puzzles import p2_delegated_puzzle_or_hidden_puzzle as standard_puzzle from flax.wallet.puzzles.cat_loader import CAT_MOD from flax.wallet.n...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/util/json_clvm_utils.py
flax/wallet/util/json_clvm_utils.py
from __future__ import annotations from typing import Any from flax.types.blockchain_format.program import Program def json_to_flaxlisp(json_data: Any) -> Any: list_for_flaxlisp = [] if isinstance(json_data, list): for value in json_data: list_for_flaxlisp.append(json_to_flaxlisp(value))...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/trading/trade_store.py
flax/wallet/trading/trade_store.py
import logging from time import perf_counter from typing import List, Optional, Tuple, Set import aiosqlite from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.mempool_inclusion_status import MempoolInclusionStatus from flax.util.db_wrapper import DBWrapper2 from flax.util.errors import Err f...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/trading/__init__.py
flax/wallet/trading/__init__.py
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/trading/trade_status.py
flax/wallet/trading/trade_status.py
from __future__ import annotations from enum import Enum class TradeStatus(Enum): PENDING_ACCEPT = 0 PENDING_CONFIRM = 1 PENDING_CANCEL = 2 CANCELLED = 3 CONFIRMED = 4 FAILED = 5
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/trading/offer.py
flax/wallet/trading/offer.py
from __future__ import annotations from dataclasses import dataclass from typing import Any, Dict, List, Optional, Set, Tuple, Union, BinaryIO from blspy import G2Element from clvm_tools.binutils import disassemble from flax.types.blockchain_format.sized_bytes import bytes32 from flax.types.blockchain_format.coin imp...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/settings/default_settings.py
flax/wallet/settings/default_settings.py
from __future__ import annotations from flax.wallet.settings.settings_objects import BackupInitialized default_backup_initialized = BackupInitialized(False, False, False, True) default_settings = {BackupInitialized.__name__: default_backup_initialized}
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/settings/user_settings.py
flax/wallet/settings/user_settings.py
from __future__ import annotations from typing import Any, Dict from flax.wallet.key_val_store import KeyValStore from flax.wallet.settings.default_settings import default_settings from flax.wallet.settings.settings_objects import BackupInitialized class UserSettings: settings: Dict[str, Any] basic_store: K...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/settings/settings_objects.py
flax/wallet/settings/settings_objects.py
from __future__ import annotations from dataclasses import dataclass from flax.util.streamable import Streamable, streamable @streamable @dataclass(frozen=True) class BackupInitialized(Streamable): """ Stores user decision regarding import of backup info """ user_initialized: bool # Stores if user...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/settings/__init__.py
flax/wallet/settings/__init__.py
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false
Flax-Network/flax-blockchain
https://github.com/Flax-Network/flax-blockchain/blob/bb8715f3155bb8011a04cc8c05b3fa8133e4c64b/flax/wallet/puzzles/p2_delegated_conditions.py
flax/wallet/puzzles/p2_delegated_conditions.py
""" Pay to delegated conditions In this puzzle program, the solution must be a signed list of conditions, which is returned literally. """ from __future__ import annotations from flax.types.blockchain_format.program import Program from .load_clvm import load_clvm_maybe_recompile MOD = load_clvm_maybe_recompile("p...
python
Apache-2.0
bb8715f3155bb8011a04cc8c05b3fa8133e4c64b
2026-01-05T07:13:52.951017Z
false