Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ __pycache__
# misc
*_cache
cspell.json

# misc
.DS_STORE
2 changes: 1 addition & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Run the following commands that generate a collection of documents under [`./doc
# cd into the root directory
$ cd python-sdk
# generate documentation from the google-styled docstrings
$ uv run pdoc ./packages/core/src -o ./docs/core -d google
$ uv run pdoc ./packages/core/jpyc-core-sdk -o ./docs/core -d google
```

## 🔍 UI
Expand Down
2 changes: 1 addition & 1 deletion docs/core/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="refresh" content="0; url=./src.html"/>
<meta http-equiv="refresh" content="0; url=./jpyc_core_sdk.html"/>
</head>
</html>
40 changes: 20 additions & 20 deletions docs/core/src.html → docs/core/jpyc_core_sdk.html

Large diffs are not rendered by default.

32 changes: 16 additions & 16 deletions docs/core/src/utils.html → docs/core/jpyc_core_sdk/utils.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/core/search.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions packages/core/examples/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
sys.path.append(str(Path(__file__).parents[1]))

from examples.constants import KNOWN_ACCOUNTS
from src.client import SdkClient
from src.jpyc import JPYC
from jpyc_core_sdk.client import SdkClient
from jpyc_core_sdk.jpyc import JPYC

# SDK clients
client_0 = SdkClient(
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def resolve_artifacts_file_path(contract_version: ContractVersion) -> Path:
Returns:
Path: Absolute path of artifacts file
"""
path = Path(__file__).parent.parent.parent.joinpath(
path = Path(__file__).parent.parent.joinpath(
"artifacts", f"v{contract_version}.json"
)

Expand Down
13 changes: 9 additions & 4 deletions packages/core/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "jpyc_core_sdk"
version = "1.0.1"
name = "jpyc-core-sdk"
version = "1.0.2"
requires-python = ">=3.12"
license = "MIT"
description = "A Python SDK for interacting with JPYCv2 contracts"
Expand All @@ -26,12 +26,12 @@ classifiers = [
"Topic :: Software Development :: Libraries :: Python Modules",
]
authors = [
{ name = "mameta", email = "mameta.zk@gmail.com" },
{ name = "SeiyaKobayashi", email = "eng@seiya.work" },
{ name = "mameta", email = "mameta.zk@gmail.com" },
]
maintainers = [
{ name = "mameta", email = "mameta.zk@gmail.com" },
{ name = "SeiyaKobayashi", email = "eng@seiya.work" },
{ name = "mameta", email = "mameta.zk@gmail.com" },
]
# Production dependencies
dependencies = [
Expand All @@ -55,10 +55,15 @@ dev = [
"ruff>=0.11.9",
]

# setuptools

[build-system]
requires = ["setuptools>=61.0"]
build-backend = "setuptools.build_meta"

[tool.setuptools.data-files]
artifacts = ["artifacts/*.json"]

# pytest

[tool.pytest.ini_options]
Expand Down
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[project]
name = "jpyc_python_sdks"
version = "1.0.1"
name = "jpyc-python-sdks"
version = "1.0.2"
requires-python = ">=3.12"
description = "Python SDKs for JPYC protocols"
readme = "README.md"

[tool.uv.sources]
core = { workspace = true }
jpyc-core-sdk = { workspace = true }

[tool.uv.workspace]
members = ["packages/*"]
Expand Down
4 changes: 2 additions & 2 deletions tests/core/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
)
from web3.eth import Eth

from packages.core.src.client import SdkClient
from packages.core.src.jpyc import JPYC
from packages.core.jpyc_core_sdk.client import SdkClient
from packages.core.jpyc_core_sdk.jpyc import JPYC


@dataclass(frozen=True)
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_allowance.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
InvalidChecksumAddress,
)

Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_approve.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidChecksumAddress,
InvalidUint256,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_balance_of.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
InvalidChecksumAddress,
)

Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_cancel_authorization.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from eth_account import Account
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidBytes32,
InvalidChecksumAddress,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_configure_minter.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidChecksumAddress,
InvalidUint256,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_decrease_allowance.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidChecksumAddress,
InvalidUint256,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_increase_allowance.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidChecksumAddress,
InvalidUint256,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_is_minter.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
InvalidChecksumAddress,
)

Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_mint.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidChecksumAddress,
InvalidUint256,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_minter_allowance.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
InvalidChecksumAddress,
)

Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_nonces.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
InvalidChecksumAddress,
)

Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_permit.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from eth_account import Account
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidBytes32,
InvalidChecksumAddress,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from eth_account import Account
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidBytes32,
InvalidChecksumAddress,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_transfer.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidChecksumAddress,
InvalidUint256,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/jpyc_methods/test_transfer_from.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidChecksumAddress,
InvalidUint256,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from eth_account import Account
import pytest

from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidBytes32,
InvalidChecksumAddress,
Expand Down
6 changes: 3 additions & 3 deletions tests/core/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
import pytest
from web3 import Web3

from packages.core.src.client import SdkClient
from packages.core.src.utils.chains import get_default_rpc_endpoint
from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.client import SdkClient
from packages.core.jpyc_core_sdk.utils.chains import get_default_rpc_endpoint
from packages.core.jpyc_core_sdk.utils.errors import (
AccountNotInitialized,
InvalidBytes32,
InvalidRpcEndpoint,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/test_jpyc.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import pytest
from web3.contract.contract import Contract

from packages.core.src.jpyc import JPYC
from packages.core.jpyc_core_sdk.jpyc import JPYC

from .conftest import V2_PROXY_ADDRESS

Expand Down
2 changes: 1 addition & 1 deletion tests/core/utils/test_addresses.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.addresses import (
from packages.core.jpyc_core_sdk.utils.addresses import (
calc_checksum_address,
get_proxy_address,
is_valid_address,
Expand Down
2 changes: 1 addition & 1 deletion tests/core/utils/test_artifacts.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest

from packages.core.src.utils.artifacts import (
from packages.core.jpyc_core_sdk.utils.artifacts import (
get_artifacts,
resolve_artifacts_file_path,
)
Expand Down
4 changes: 2 additions & 2 deletions tests/core/utils/test_chains.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import pytest

from packages.core.src.utils.chains import (
from packages.core.jpyc_core_sdk.utils.chains import (
enumerate_supported_networks,
get_default_rpc_endpoint,
is_supported_network,
)
from packages.core.src.utils.errors import (
from packages.core.jpyc_core_sdk.utils.errors import (
NetworkNotSupported,
)

Expand Down
2 changes: 1 addition & 1 deletion tests/core/utils/test_currencies.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import pytest

from packages.core.src.utils.currencies import (
from packages.core.jpyc_core_sdk.utils.currencies import (
remove_decimals,
restore_decimals,
)
Expand Down
Loading