code stringlengths 0 94.8k | repo_name stringclasses 1
value | path stringlengths 14 57 | language stringclasses 1
value | license stringclasses 1
value | size int64 0 94.8k |
|---|---|---|---|---|---|
# Configuration file for the Sphinx documentation builder.
#
# For the full list of built-in configuration values, see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html
# -- Project information -----------------------------------------------------
# https://www.sphinx-doc.org/en/master... | algorandfoundation/algokit-utils-py | docs/source/conf.py | Python | MIT | 2,144 |
algorandfoundation/algokit-utils-py | legacy_v2_tests/__init__.py | Python | MIT | 0 | |
from typing import Literal
import beaker
import pyteal
from beaker.lib.storage import BoxMapping
class State:
greeting = beaker.GlobalStateValue(pyteal.TealType.bytes)
last = beaker.LocalStateValue(pyteal.TealType.bytes, default=pyteal.Bytes("unset"))
box = BoxMapping(pyteal.abi.StaticBytes[Literal[4]], ... | algorandfoundation/algokit-utils-py | legacy_v2_tests/app_client_test.py | Python | MIT | 5,773 |
import beaker
import pyteal
app = beaker.Application("MultiUnderscoreApp")
@app.external
def some_value(*, output: pyteal.abi.Uint64) -> pyteal.Expr:
return output.set(pyteal.Tmpl.Int("TMPL_SOME_VALUE"))
@app.update(bare=True, authorize=beaker.Authorize.only_creator())
def update() -> pyteal.Expr:
return p... | algorandfoundation/algokit-utils-py | legacy_v2_tests/app_multi_underscore_template_var.py | Python | MIT | 655 |
import inspect
import math
import random
import subprocess
from pathlib import Path
from typing import TYPE_CHECKING
from uuid import uuid4
import algosdk.transaction
import pytest
from dotenv import load_dotenv
from algokit_utils import (
DELETABLE_TEMPLATE_NAME,
UPDATABLE_TEMPLATE_NAME,
Account,
App... | algorandfoundation/algokit-utils-py | legacy_v2_tests/conftest.py | Python | MIT | 6,720 |
from typing import TYPE_CHECKING
from algokit_utils import get_account
from legacy_v2_tests.conftest import get_unique_name
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
def test_account_can_be_called_twice(algod_client: "AlgodClient") -> None:
account_name = get_unique_name()
account... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_account.py | Python | MIT | 452 |
import pytest
from algokit_utils import AppDeployMetaData
@pytest.mark.parametrize(
"app_note_json",
[
b'ALGOKIT_DEPLOYER:j{"name":"VotingRoundApp","version":"1.0","deletable":true,"updatable":true}',
b'ALGOKIT_DEPLOYER:j{"name":"VotingRoundApp","version":"1.0","deletable":true}',
],
)
de... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app.py | Python | MIT | 456 |
import pytest
from algokit_utils import (
DeploymentFailedError,
get_next_version,
)
@pytest.mark.parametrize(
("current", "expected_next"),
[
("1", "2"),
("v1", "v2"),
("v1-alpha", "v2-alpha"),
("1.0", "1.1"),
("v1.0", "v1.1"),
("v1.0-alpha", "v1.1-alp... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client.py | Python | MIT | 717 |
from collections.abc import Generator
from hashlib import sha256
from pathlib import Path
from typing import TYPE_CHECKING
from unittest.mock import Mock, patch
import pytest
from algosdk.atomic_transaction_composer import (
AccountTransactionSigner,
AtomicTransactionComposer,
TransactionWithSigner,
)
from... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_call.py | Python | MIT | 12,318 |
import base64
from typing import TYPE_CHECKING
import pytest
from algokit_utils import (
Account,
ApplicationClient,
ApplicationSpecification,
)
from legacy_v2_tests.conftest import is_opted_in
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
from algosdk.v2client.indexer import I... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_clear_state.py | Python | MIT | 1,870 |
from typing import TYPE_CHECKING
import pytest
from algokit_utils import (
Account,
ApplicationClient,
ApplicationSpecification,
LogicError,
)
from legacy_v2_tests.conftest import check_output_stability, is_opted_in
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
from algosdk... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_close_out.py | Python | MIT | 1,986 |
import dataclasses
from typing import TYPE_CHECKING
import pytest
from algosdk.atomic_transaction_composer import AccountTransactionSigner, AtomicTransactionComposer, TransactionSigner
from algosdk.transaction import ApplicationCallTxn, GenericSignedTransaction, OnComplete, Transaction
from algokit_utils import (
... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_create.py | Python | MIT | 9,250 |
from typing import TYPE_CHECKING
import pytest
from algokit_utils import (
Account,
ApplicationClient,
ApplicationSpecification,
LogicError,
)
from legacy_v2_tests.conftest import check_output_stability
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
from algosdk.v2client.ind... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_delete.py | Python | MIT | 1,463 |
from typing import TYPE_CHECKING
import pytest
from algokit_utils import (
ABICreateCallArgs,
Account,
ApplicationClient,
ApplicationSpecification,
TransferParameters,
transfer,
)
from legacy_v2_tests.conftest import get_unique_name, read_spec
if TYPE_CHECKING:
from algosdk.v2client.algod... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_deploy.py | Python | MIT | 1,988 |
from typing import TYPE_CHECKING
import pytest
from algokit_utils import (
Account,
ApplicationClient,
ApplicationSpecification,
LogicError,
)
from legacy_v2_tests.conftest import check_output_stability, is_opted_in
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
from algosdk... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_opt_in.py | Python | MIT | 1,854 |
import base64
from typing import TYPE_CHECKING
from algosdk.atomic_transaction_composer import AccountTransactionSigner
from algokit_utils import (
ApplicationClient,
ApplicationSpecification,
)
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
def test_app_client_prepare_with_no_existin... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_prepare.py | Python | MIT | 1,804 |
from typing import TYPE_CHECKING
from algokit_utils import (
Account,
ApplicationClient,
DefaultArgumentDict,
)
from legacy_v2_tests.conftest import read_spec
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
def test_resolve(algod_client: "AlgodClient", creator: Account) -> None:
... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_resolve.py | Python | MIT | 2,011 |
import base64
import contextlib
from typing import TYPE_CHECKING, Any
import pytest
from algosdk.atomic_transaction_composer import AccountTransactionSigner, TransactionSigner
from algokit_utils import (
ApplicationClient,
ApplicationSpecification,
get_sender_from_signer,
)
if TYPE_CHECKING:
from alg... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_signer_sender.py | Python | MIT | 2,264 |
from typing import TYPE_CHECKING
import pytest
import algokit_utils
from legacy_v2_tests.conftest import get_unique_name, read_spec
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
from algosdk.v2client.indexer import IndexerClient
def test_create_with_all_template_values_on_initialize(
... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_template_values.py | Python | MIT | 4,446 |
from typing import TYPE_CHECKING
import pytest
from algokit_utils import (
Account,
ApplicationClient,
ApplicationSpecification,
LogicError,
)
from legacy_v2_tests.conftest import check_output_stability
if TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
from algosdk.v2client.ind... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_app_client_update.py | Python | MIT | 1,748 |
import re
from typing import TYPE_CHECKING
import pytest
from algokit_utils import (
Account,
EnsureBalanceParameters,
TransferAssetParameters,
create_kmd_wallet_account,
ensure_funded,
transfer_asset,
)
from algokit_utils.asset import opt_in, opt_out
if TYPE_CHECKING:
from algosdk.kmd im... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_asset.py | Python | MIT | 7,263 |
import json
from typing import TYPE_CHECKING
from unittest.mock import Mock
import pytest
from algosdk.atomic_transaction_composer import (
AccountTransactionSigner,
AtomicTransactionComposer,
TransactionWithSigner,
)
from algosdk.transaction import PaymentTxn
from algokit_utils._debugging import (
Pe... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_debug_utils.py | Python | MIT | 5,847 |
from algokit_utils import (
replace_template_variables,
)
from algokit_utils._legacy_v2.deploy import strip_comments
from legacy_v2_tests.conftest import check_output_stability
def test_template_substitution() -> None:
program = """
test TMPL_INT // TMPL_INT
test TMPL_INT
no change
test TMPL_STR // TMPL_STR
T... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_deploy.py | Python | MIT | 1,870 |
import logging
import re
import time
from collections.abc import Generator
from enum import Enum
from unittest.mock import Mock, patch
import pytest
from algokit_utils import (
Account,
ApplicationClient,
ApplicationSpecification,
DeploymentFailedError,
LogicError,
OnSchemaBreak,
OnUpdate,... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_deploy_scenarios.py | Python | MIT | 15,254 |
import json
import pytest
from pytest_httpx import HTTPXMock
from algokit_utils.dispenser_api import (
DISPENSER_ASSETS,
DispenserApiConfig,
DispenserAssetName,
TestNetDispenserApiClient,
)
class TestDispenserApiTestnetClient:
def test_fund_account_with_algos_with_auth_token(self, httpx_mock: HT... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_dispenser_api_client.py | Python | MIT | 3,042 |
import os
from unittest import mock
from algokit_utils import (
get_algod_client,
get_algonode_config,
get_default_localnet_config,
get_indexer_client,
)
DEFAULT_TOKEN = "a" * 64
def test_localnet_algod() -> None:
algod_client = get_algod_client(get_default_localnet_config("algod"))
health_r... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_network_clients.py | Python | MIT | 1,403 |
from typing import TYPE_CHECKING
import algosdk
import httpx
import pytest
from algosdk.atomic_transaction_composer import AccountTransactionSigner
from algosdk.transaction import PaymentTxn
from algosdk.util import algos_to_microalgos
from pytest_httpx import HTTPXMock
from algokit_utils import (
Account,
En... | algorandfoundation/algokit-utils-py | legacy_v2_tests/test_transfer.py | Python | MIT | 15,970 |
"""AlgoKit Python Utilities - a set of utilities for building solutions on Algorand
This module provides commonly used utilities and types at the root level for convenience.
For more specific functionality, import directly from the relevant submodules:
from algokit_utils.accounts import KmdAccountManager
from... | algorandfoundation/algokit-utils-py | src/algokit_utils/__init__.py | Python | MIT | 1,039 |
import base64
import json
import logging
import typing
from dataclasses import dataclass, field
from datetime import datetime, timezone
from pathlib import Path
from algosdk.atomic_transaction_composer import (
AtomicTransactionComposer,
EmptySigner,
SimulateAtomicTransactionResponse,
)
from algosdk.encodi... | algorandfoundation/algokit-utils-py | src/algokit_utils/_debugging.py | Python | MIT | 11,703 |
"""AlgoKit Python Utilities (Legacy V2) - a set of utilities for building solutions on Algorand
This module provides commonly used utilities and types at the root level for convenience.
For more specific functionality, import directly from the relevant submodules:
from algokit_utils.accounts import KmdAccountMana... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/__init__.py | Python | MIT | 4,689 |
from dataclasses import dataclass
from algosdk.account import address_from_private_key
from algosdk.atomic_transaction_composer import AccountTransactionSigner
from algosdk.transaction import SuggestedParams
from algosdk.v2client.algod import AlgodClient
from typing_extensions import deprecated
from algokit_utils._le... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/_ensure_funded.py | Python | MIT | 6,931 |
import dataclasses
import logging
from typing import TYPE_CHECKING
import algosdk.transaction
from algosdk.account import address_from_private_key
from algosdk.atomic_transaction_composer import AccountTransactionSigner
from algosdk.transaction import AssetTransferTxn, PaymentTxn, SuggestedParams
from typing_extension... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/_transfer.py | Python | MIT | 6,256 |
import logging
import os
from typing import TYPE_CHECKING, Any
from algosdk.account import address_from_private_key
from algosdk.mnemonic import from_private_key, to_private_key
from algosdk.util import algos_to_microalgos
from typing_extensions import deprecated
from algokit_utils._legacy_v2._transfer import Transfe... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/account.py | Python | MIT | 8,224 |
from __future__ import annotations
import base64
import copy
import json
import logging
import re
import typing
from math import ceil
from pathlib import Path
from typing import Any, Literal, cast, overload
import algosdk
from algosdk import transaction
from algosdk.abi import ABIType, Method, Returns
from algosdk.ac... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/application_client.py | Python | MIT | 59,536 |
from algokit_utils.applications.app_spec.arc32 import (
AppSpecStateDict,
CallConfig,
DefaultArgumentDict,
DefaultArgumentType,
MethodConfigDict,
MethodHints,
OnCompleteActionName,
)
from algokit_utils.applications.app_spec.arc32 import Arc32Contract as ApplicationSpecification
__all__ = [
... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/application_specification.py | Python | MIT | 521 |
import logging
from enum import Enum, auto
from algosdk.atomic_transaction_composer import AtomicTransactionComposer, TransactionWithSigner
from algosdk.constants import TX_GROUP_LIMIT
from algosdk.transaction import AssetTransferTxn
from algosdk.v2client.algod import AlgodClient
from typing_extensions import deprecat... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/asset.py | Python | MIT | 7,594 |
"""
This module contains common classes and methods that are reused in more than one file.
"""
import base64
import typing
from algosdk.source_map import SourceMap
from algokit_utils._legacy_v2.deploy import strip_comments
if typing.TYPE_CHECKING:
from algosdk.v2client.algod import AlgodClient
class Program:
... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/common.py | Python | MIT | 823 |
import base64
import dataclasses
import json
import logging
import re
from collections.abc import Iterable, Mapping, Sequence
from typing import TYPE_CHECKING, TypeAlias, TypedDict
import algosdk
from algosdk import transaction
from algosdk.atomic_transaction_composer import AtomicTransactionComposer, TransactionSigne... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/deploy.py | Python | MIT | 32,777 |
from typing_extensions import deprecated
from algokit_utils.errors.logic_error import LogicError as NewLogicError
from algokit_utils.errors.logic_error import parse_logic_error
__all__ = [
"LogicError",
"parse_logic_error",
]
@deprecated("Use algokit_utils.models.error.LogicError instead")
class LogicError(... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/logic_error.py | Python | MIT | 345 |
import dataclasses
from collections.abc import Sequence
from typing import Any, Generic, Protocol, TypeAlias, TypedDict, TypeVar
from algosdk import transaction
from algosdk.abi import Method
from algosdk.atomic_transaction_composer import (
AtomicTransactionResponse,
SimulateAtomicTransactionResponse,
Tra... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/models.py | Python | MIT | 7,403 |
import dataclasses
import os
from typing import Literal
from urllib import parse
from algosdk.kmd import KMDClient
from algosdk.v2client.algod import AlgodClient
from algosdk.v2client.indexer import IndexerClient
from typing_extensions import deprecated
__all__ = [
"AlgoClientConfig",
"AlgoClientConfigs",
... | algorandfoundation/algokit-utils-py | src/algokit_utils/_legacy_v2/network_clients.py | Python | MIT | 5,660 |
import warnings
warnings.warn(
"""The legacy v2 account module is deprecated and will be removed in a future version.
Use `SigningAccount` abstraction from `algokit_utils.models` instead or
classes compliant with `TransactionSignerAccountProtocol` obtained from `AccountManager`.
""",
DeprecationWarning... | algorandfoundation/algokit-utils-py | src/algokit_utils/account.py | Python | MIT | 410 |
from algokit_utils.accounts.account_manager import * # noqa: F403
from algokit_utils.accounts.kmd_account_manager import * # noqa: F403
| algorandfoundation/algokit-utils-py | src/algokit_utils/accounts/__init__.py | Python | MIT | 138 |
import os
from collections.abc import Callable
from dataclasses import dataclass
from typing import Any
import algosdk
from algosdk import mnemonic
from algosdk.atomic_transaction_composer import TransactionSigner
from algosdk.mnemonic import to_private_key
from algosdk.transaction import LogicSigAccount as AlgosdkLog... | algorandfoundation/algokit-utils-py | src/algokit_utils/accounts/account_manager.py | Python | MIT | 39,369 |
from collections.abc import Callable
from typing import Any, cast
from algosdk.kmd import KMDClient
from algokit_utils.clients.client_manager import ClientManager
from algokit_utils.config import config
from algokit_utils.models.account import SigningAccount
from algokit_utils.models.amount import AlgoAmount
from alg... | algorandfoundation/algokit-utils-py | src/algokit_utils/accounts/kmd_account_manager.py | Python | MIT | 6,342 |
import copy
import time
import typing_extensions
from algosdk.atomic_transaction_composer import TransactionSigner
from algosdk.kmd import KMDClient
from algosdk.transaction import SuggestedParams
from algosdk.v2client.algod import AlgodClient
from algosdk.v2client.indexer import IndexerClient
from algokit_utils.acco... | algorandfoundation/algokit-utils-py | src/algokit_utils/algorand.py | Python | MIT | 10,554 |
import warnings
warnings.warn(
"""The legacy v2 application_client module is deprecated and will be removed in a future version.
Use `AppClient` abstraction from `algokit_utils.applications` instead.
""",
DeprecationWarning,
stacklevel=2,
)
from algokit_utils._legacy_v2.application_client import * # ... | algorandfoundation/algokit-utils-py | src/algokit_utils/application_client.py | Python | MIT | 337 |
import warnings
from typing_extensions import deprecated
warnings.warn(
"""The legacy v2 application_specification module is deprecated and will be removed in a future version.
Use `from algokit_utils.applications.app_spec.arc32 import ...` to access Arc32 app spec instead.
By default, the ARC52Contract i... | algorandfoundation/algokit-utils-py | src/algokit_utils/application_specification.py | Python | MIT | 1,416 |
from algokit_utils.applications.abi import * # noqa: F403
from algokit_utils.applications.app_client import * # noqa: F403
from algokit_utils.applications.app_deployer import * # noqa: F403
from algokit_utils.applications.app_factory import * # noqa: F403
from algokit_utils.applications.app_manager import * # noqa... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/__init__.py | Python | MIT | 452 |
from __future__ import annotations
from dataclasses import dataclass
from typing import TYPE_CHECKING, Any, TypeAlias
import algosdk
from algosdk.abi.method import Method as AlgorandABIMethod
from algosdk.atomic_transaction_composer import ABIResult
from algokit_utils.applications.app_spec.arc56 import Arc56Contract... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/abi.py | Python | MIT | 10,087 |
from __future__ import annotations
import base64
import copy
import json
import os
from collections.abc import Sequence
from dataclasses import asdict, dataclass, fields
from typing import TYPE_CHECKING, Any, Generic, Literal, TypedDict, TypeVar
import algosdk
from algosdk.source_map import SourceMap
from algosdk.tra... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/app_client.py | Python | MIT | 83,432 |
import base64
import dataclasses
import json
from dataclasses import asdict, dataclass
from typing import Literal
from algosdk.logic import get_application_address
from algosdk.v2client.indexer import IndexerClient
from algokit_utils.applications.abi import ABIReturn
from algokit_utils.applications.app_manager import... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/app_deployer.py | Python | MIT | 23,099 |
import base64
import dataclasses
from collections.abc import Callable, Sequence
from dataclasses import asdict, dataclass
from typing import Any, Generic, TypeVar
from algosdk.atomic_transaction_composer import TransactionSigner
from algosdk.source_map import SourceMap
from algosdk.transaction import OnComplete, Trans... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/app_factory.py | Python | MIT | 33,425 |
import base64
from collections.abc import Mapping
from typing import Any, cast
import algosdk
import algosdk.atomic_transaction_composer
import algosdk.box_reference
from algosdk.atomic_transaction_composer import AccountTransactionSigner
from algosdk.box_reference import BoxReference as AlgosdkBoxReference
from algos... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/app_manager.py | Python | MIT | 17,661 |
from algokit_utils.applications.app_spec.arc32 import * # noqa: F403
from algokit_utils.applications.app_spec.arc56 import * # noqa: F403
| algorandfoundation/algokit-utils-py | src/algokit_utils/applications/app_spec/__init__.py | Python | MIT | 140 |
import base64
import dataclasses
import json
from enum import IntFlag
from pathlib import Path
from typing import Any, Literal, TypeAlias, TypedDict
from algosdk.abi import Contract
from algosdk.abi.method import MethodDict
from algosdk.transaction import StateSchema
__all__ = [
"AppSpecStateDict",
"Arc32Cont... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/app_spec/arc32.py | Python | MIT | 7,523 |
from __future__ import annotations
import base64
import json
from base64 import b64encode
from collections.abc import Callable, Sequence
from dataclasses import asdict, dataclass
from enum import Enum
from typing import Any, Literal, overload
import algosdk
from algosdk.abi import Method as AlgosdkMethod
from algoki... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/app_spec/arc56.py | Python | MIT | 31,727 |
from enum import Enum
# NOTE: this is moved to a separate file to avoid circular imports
class OnSchemaBreak(Enum):
"""Action to take if an Application's schema has breaking changes"""
Fail = 0
"""Fail the deployment"""
ReplaceApp = 2
"""Create a new Application and delete the old Application in... | algorandfoundation/algokit-utils-py | src/algokit_utils/applications/enums.py | Python | MIT | 1,257 |
import warnings
warnings.warn(
"""The legacy v2 asset module is deprecated and will be removed in a future version.
Replacements for opt_in/opt_out functionality:
1. Using TransactionComposer:
composer.add_asset_opt_in(AssetOptInParams(
sender=account.address,
asset_id=123
))
composer.add_... | algorandfoundation/algokit-utils-py | src/algokit_utils/asset.py | Python | MIT | 874 |
from algokit_utils.assets.asset_manager import * # noqa: F403
| algorandfoundation/algokit-utils-py | src/algokit_utils/assets/__init__.py | Python | MIT | 63 |
from collections.abc import Callable
from dataclasses import dataclass
import algosdk
from algosdk.atomic_transaction_composer import AccountTransactionSigner, TransactionSigner
from algosdk.v2client import algod
from algokit_utils.models.account import SigningAccount
from algokit_utils.models.amount import AlgoAmoun... | algorandfoundation/algokit-utils-py | src/algokit_utils/assets/asset_manager.py | Python | MIT | 14,132 |
from typing import NoReturn
def deprecated_import_error(old_path: str, new_path: str) -> NoReturn:
"""Helper to create consistent deprecation error messages"""
raise ImportError(
f"WARNING: The module '{old_path}' has been removed in algokit-utils v3. "
f"Please update your imports to use '{ne... | algorandfoundation/algokit-utils-py | src/algokit_utils/beta/_utils.py | Python | MIT | 1,839 |
from typing import Any
from algokit_utils.beta._utils import handle_getattr
def __getattr__(name: str) -> Any: # noqa: ANN401
"""Handle deprecated imports of parameter classes"""
handle_getattr(name)
| algorandfoundation/algokit-utils-py | src/algokit_utils/beta/account_manager.py | Python | MIT | 213 |
from typing import Any
from algokit_utils.beta._utils import handle_getattr
def __getattr__(name: str) -> Any: # noqa: ANN401
"""Handle deprecated imports of parameter classes"""
handle_getattr(name)
| algorandfoundation/algokit-utils-py | src/algokit_utils/beta/algorand_client.py | Python | MIT | 213 |
from typing import Any
from algokit_utils.beta._utils import handle_getattr
def __getattr__(name: str) -> Any: # noqa: ANN401
"""Handle deprecated imports of parameter classes"""
handle_getattr(name)
| algorandfoundation/algokit-utils-py | src/algokit_utils/beta/client_manager.py | Python | MIT | 213 |
from typing import Any
from algokit_utils.beta._utils import handle_getattr
def __getattr__(name: str) -> Any: # noqa: ANN401
"""Handle deprecated imports of parameter classes"""
handle_getattr(name)
| algorandfoundation/algokit-utils-py | src/algokit_utils/beta/composer.py | Python | MIT | 213 |
from algokit_utils.clients.client_manager import * # noqa: F403
from algokit_utils.clients.dispenser_api_client import * # noqa: F403
| algorandfoundation/algokit-utils-py | src/algokit_utils/clients/__init__.py | Python | MIT | 136 |
from __future__ import annotations
import os
from dataclasses import dataclass
from typing import TYPE_CHECKING, Literal, TypeVar
from urllib import parse
import algosdk
from algosdk.atomic_transaction_composer import TransactionSigner
from algosdk.kmd import KMDClient
from algosdk.source_map import SourceMap
from al... | algorandfoundation/algokit-utils-py | src/algokit_utils/clients/client_manager.py | Python | MIT | 25,683 |
import contextlib
import enum
import os
from dataclasses import dataclass
import httpx
from algokit_utils.config import config
__all__ = [
"DISPENSER_ACCESS_TOKEN_KEY",
"DISPENSER_ASSETS",
"DISPENSER_REQUEST_TIMEOUT",
"DispenserApiConfig",
"DispenserAsset",
"DispenserAssetName",
"Dispense... | algorandfoundation/algokit-utils-py | src/algokit_utils/clients/dispenser_api_client.py | Python | MIT | 6,045 |
import warnings
warnings.warn(
"The legacy v2 common module is deprecated and will be removed in a future version. "
"Refer to `CompiledTeal` class from `algokit_utils` instead.",
DeprecationWarning,
stacklevel=2,
)
from algokit_utils._legacy_v2.common import * # noqa: F403, E402
| algorandfoundation/algokit-utils-py | src/algokit_utils/common.py | Python | MIT | 300 |
import logging
import os
from collections.abc import Callable
from pathlib import Path
from typing import Any
# Environment variable to override the project root
ALGOKIT_PROJECT_ROOT = os.getenv("ALGOKIT_PROJECT_ROOT")
ALGOKIT_CONFIG_FILENAME = ".algokit.toml"
class AlgoKitLogger:
def __init__(self) -> None:
... | algorandfoundation/algokit-utils-py | src/algokit_utils/config.py | Python | MIT | 7,029 |
import warnings
warnings.warn(
"The legacy v2 deploy module is deprecated and will be removed in a future version. "
"Refer to `AppFactory` and `AppDeployer` abstractions from `algokit_utils` module instead.",
DeprecationWarning,
stacklevel=2,
)
from algokit_utils._legacy_v2.deploy import * # noqa: F... | algorandfoundation/algokit-utils-py | src/algokit_utils/deploy.py | Python | MIT | 330 |
import warnings
warnings.warn(
"The legacy v2 dispenser api module is deprecated and will be removed in a future version. "
"Import from 'algokit_utils.clients.dispenser_api_client' instead.",
DeprecationWarning,
stacklevel=2,
)
from algokit_utils.clients.dispenser_api_client import * # noqa: F403, E... | algorandfoundation/algokit-utils-py | src/algokit_utils/dispenser_api.py | Python | MIT | 324 |
from algokit_utils.errors.logic_error import * # noqa: F403
| algorandfoundation/algokit-utils-py | src/algokit_utils/errors/__init__.py | Python | MIT | 61 |
import base64
import re
from collections.abc import Callable
from copy import copy
from typing import TYPE_CHECKING, TypedDict
from algosdk.atomic_transaction_composer import (
SimulateAtomicTransactionResponse,
)
from algokit_utils.models.simulate import SimulationTrace
if TYPE_CHECKING:
from algosdk.source... | algorandfoundation/algokit-utils-py | src/algokit_utils/errors/logic_error.py | Python | MIT | 4,104 |
import warnings
warnings.warn(
"The legacy v2 logic error module is deprecated and will be removed in a future version. "
"Use 'from algokit_utils.errors import LogicError' instead.",
DeprecationWarning,
stacklevel=2,
)
from algokit_utils.errors.logic_error import * # noqa: F403, E402
| algorandfoundation/algokit-utils-py | src/algokit_utils/logic_error.py | Python | MIT | 305 |
from algokit_utils._legacy_v2.models import * # noqa: F403
from algokit_utils.models.account import * # noqa: F403
from algokit_utils.models.amount import * # noqa: F403
from algokit_utils.models.application import * # noqa: F403
from algokit_utils.models.network import * # noqa: F403
from algokit_utils.models.sim... | algorandfoundation/algokit-utils-py | src/algokit_utils/models/__init__.py | Python | MIT | 465 |
import dataclasses
import algosdk
import algosdk.atomic_transaction_composer
from algosdk.atomic_transaction_composer import AccountTransactionSigner, LogicSigTransactionSigner, TransactionSigner
from algosdk.transaction import LogicSigAccount as AlgosdkLogicSigAccount
from algosdk.transaction import Multisig, Multisi... | algorandfoundation/algokit-utils-py | src/algokit_utils/models/account.py | Python | MIT | 6,014 |
from __future__ import annotations
from decimal import Decimal
from typing import overload
import algosdk
from typing_extensions import Self
__all__ = ["ALGORAND_MIN_TX_FEE", "AlgoAmount", "algo", "micro_algo", "transaction_fees"]
class AlgoAmount:
"""Wrapper class to ensure safe, explicit conversion between µ... | algorandfoundation/algokit-utils-py | src/algokit_utils/models/amount.py | Python | MIT | 9,411 |
from dataclasses import dataclass
from typing import TYPE_CHECKING
import algosdk
from algosdk.source_map import SourceMap
if TYPE_CHECKING:
pass
__all__ = [
"AppCompilationResult",
"AppInformation",
"AppSourceMaps",
"AppState",
"CompiledTeal",
]
@dataclass(kw_only=True, frozen=True)
class ... | algorandfoundation/algokit-utils-py | src/algokit_utils/models/application.py | Python | MIT | 1,288 |
import dataclasses
__all__ = [
"AlgoClientConfigs",
"AlgoClientNetworkConfig",
]
@dataclasses.dataclass
class AlgoClientNetworkConfig:
"""Connection details for connecting to an {py:class}`algosdk.v2client.algod.AlgodClient` or
{py:class}`algosdk.v2client.indexer.IndexerClient`"""
server: str
... | algorandfoundation/algokit-utils-py | src/algokit_utils/models/network.py | Python | MIT | 723 |
from dataclasses import dataclass
__all__ = ["SimulationTrace"]
@dataclass
class SimulationTrace:
app_budget_added: int | None
app_budget_consumed: int | None
failure_message: str | None
exec_trace: dict[str, object]
| algorandfoundation/algokit-utils-py | src/algokit_utils/models/simulate.py | Python | MIT | 236 |
import base64
from collections.abc import Mapping
from dataclasses import dataclass
from enum import IntEnum
from typing import TypeAlias
from algosdk.atomic_transaction_composer import AccountTransactionSigner
from algosdk.box_reference import BoxReference as AlgosdkBoxReference
__all__ = [
"BoxIdentifier",
... | algorandfoundation/algokit-utils-py | src/algokit_utils/models/state.py | Python | MIT | 1,478 |
from typing import Any, Literal, TypedDict, TypeVar
import algosdk
__all__ = [
"Arc2TransactionNote",
"BaseArc2Note",
"JsonFormatArc2Note",
"SendParams",
"StringFormatArc2Note",
"TransactionNote",
"TransactionNoteData",
"TransactionWrapper",
]
# Define specific types for different fo... | algorandfoundation/algokit-utils-py | src/algokit_utils/models/transaction.py | Python | MIT | 3,052 |
import warnings
warnings.warn(
"The legacy v2 network clients module is deprecated and will be removed in a future version.",
DeprecationWarning,
stacklevel=2,
)
from algokit_utils._legacy_v2.network_clients import * # noqa: F403, E402
| algorandfoundation/algokit-utils-py | src/algokit_utils/network_clients.py | Python | MIT | 251 |
from algokit_utils.protocols.account import * # noqa: F403
from algokit_utils.protocols.typed_clients import * # noqa: F403
| algorandfoundation/algokit-utils-py | src/algokit_utils/protocols/__init__.py | Python | MIT | 126 |
from typing import Protocol, runtime_checkable
from algosdk.atomic_transaction_composer import TransactionSigner
__all__ = ["TransactionSignerAccountProtocol"]
@runtime_checkable
class TransactionSignerAccountProtocol(Protocol):
"""An account that has a transaction signer.
Implemented by SigningAccount, Log... | algorandfoundation/algokit-utils-py | src/algokit_utils/protocols/account.py | Python | MIT | 624 |
from __future__ import annotations
from typing import TYPE_CHECKING, Any, Generic, Protocol, TypeVar
from algosdk.atomic_transaction_composer import TransactionSigner
from algosdk.source_map import SourceMap
from typing_extensions import Self
from algokit_utils.models import SendParams
if TYPE_CHECKING:
from al... | algorandfoundation/algokit-utils-py | src/algokit_utils/protocols/typed_clients.py | Python | MIT | 3,322 |
from algokit_utils.transactions.transaction_composer import * # noqa: F403
from algokit_utils.transactions.transaction_creator import * # noqa: F403
from algokit_utils.transactions.transaction_sender import * # noqa: F403
| algorandfoundation/algokit-utils-py | src/algokit_utils/transactions/__init__.py | Python | MIT | 225 |
from __future__ import annotations
import base64
import json
import re
from copy import deepcopy
from dataclasses import dataclass
from typing import TYPE_CHECKING, Any, TypedDict, Union, cast
import algosdk
import algosdk.atomic_transaction_composer
import algosdk.v2client.models
from algosdk import logic, transacti... | algorandfoundation/algokit-utils-py | src/algokit_utils/transactions/transaction_composer.py | Python | MIT | 94,794 |
from collections.abc import Callable
from typing import TypeVar
from algosdk.transaction import Transaction
from algokit_utils.transactions.transaction_composer import (
AppCallMethodCallParams,
AppCallParams,
AppCreateMethodCallParams,
AppCreateParams,
AppDeleteMethodCallParams,
AppDeletePara... | algorandfoundation/algokit-utils-py | src/algokit_utils/transactions/transaction_creator.py | Python | MIT | 6,167 |
from collections.abc import Callable
from dataclasses import dataclass
from typing import Any, Generic, TypeVar
import algosdk
import algosdk.atomic_transaction_composer
from algosdk.transaction import Transaction
from typing_extensions import Self
from algokit_utils.applications.abi import ABIReturn
from algokit_uti... | algorandfoundation/algokit-utils-py | src/algokit_utils/transactions/transaction_sender.py | Python | MIT | 22,769 |
algorandfoundation/algokit-utils-py | tests/__init__.py | Python | MIT | 0 | |
algorandfoundation/algokit-utils-py | tests/accounts/__init__.py | Python | MIT | 0 | |
import algosdk
import pytest
from algokit_utils import SigningAccount
from algokit_utils.algorand import AlgorandClient
from algokit_utils.models.amount import AlgoAmount
from tests.conftest import get_unique_name
@pytest.fixture
def algorand() -> AlgorandClient:
return AlgorandClient.default_localnet()
@pytes... | algorandfoundation/algokit-utils-py | tests/accounts/test_account_manager.py | Python | MIT | 3,459 |
algorandfoundation/algokit-utils-py | tests/applications/__init__.py | Python | MIT | 0 | |
import base64
import json
import random
from pathlib import Path
from typing import Any
import algosdk
import pytest
from algosdk.atomic_transaction_composer import TransactionSigner, TransactionWithSigner
from algokit_utils._legacy_v2.application_specification import ApplicationSpecification
from algokit_utils.algor... | algorandfoundation/algokit-utils-py | tests/applications/test_app_client.py | Python | MIT | 26,174 |
from pathlib import Path
import algosdk
import pytest
from algosdk.logic import get_application_address
from algosdk.transaction import OnComplete
from algokit_utils.algorand import AlgorandClient
from algokit_utils.applications.app_client import (
AppClient,
AppClientMethodCallCreateParams,
AppClientMeth... | algorandfoundation/algokit-utils-py | tests/applications/test_app_factory.py | Python | MIT | 19,701 |
import pytest
from algokit_utils.algorand import AlgorandClient
from algokit_utils.applications.app_manager import AppManager
from algokit_utils.models.account import SigningAccount
from algokit_utils.models.amount import AlgoAmount
from tests.conftest import check_output_stability
@pytest.fixture
def algorand() -> ... | algorandfoundation/algokit-utils-py | tests/applications/test_app_manager.py | Python | MIT | 2,528 |
import json
from pathlib import Path
from algokit_utils.applications.app_spec.arc56 import Arc56Contract
from tests.conftest import check_output_stability
from tests.utils import load_app_spec
TEST_ARC32_SPEC_FILE_PATH = Path(__file__).parent.parent / "artifacts" / "hello_world" / "app_spec.arc32.json"
TEST_ARC56_SPE... | algorandfoundation/algokit-utils-py | tests/applications/test_arc56.py | Python | MIT | 1,418 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.