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
29 changes: 0 additions & 29 deletions .github/workflows/testnet-examples.yaml

This file was deleted.

4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@

All notable changes to the Aptos Python SDK will be captured in this file. This changelog is written by hand for now.

## Unreleased
## 0.11.0

- `PrivateKey.format_private_key` can now format a AIP-80 compliant private key
- Removed strictness warnnings for `PrivateKey.parse_hex_input`
- Make HTTP2 default
- Update all dependencies

## 0.10.0

Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ lint:
examples:
poetry run python -m examples.aptos_token
poetry run python -m examples.fee_payer_transfer_coin
poetry run python -m examples.multikey
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Positively alphabetical!

poetry run python -m examples.rotate_key
poetry run python -m examples.read_aggregator
poetry run python -m examples.secp256k1_ecdsa_transfer_coin
Expand All @@ -32,7 +33,6 @@ examples:
poetry run python -m examples.simulate_transfer_coin
poetry run python -m examples.transfer_coin
poetry run python -m examples.transfer_two_by_two
poetry run python -m examples.multikey

examples_cli:
poetry run python -m examples.hello_blockchain
Expand Down
2 changes: 1 addition & 1 deletion aptos_sdk/async_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class ClientConfig:
gas_unit_price: int = 100
max_gas_amount: int = 100_000
transaction_wait_in_seconds: int = 20
http2: bool = False
http2: bool = True
api_key: Optional[str] = None


Expand Down
2 changes: 2 additions & 0 deletions examples/large_package_publisher.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ async def main(
alice, large_package_example_dir, large_packages_account
)

await rest_client.close()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit, can we use the client as a context manager? The indentation is annoying though...



if __name__ == "__main__":
if len(sys.argv) == 2:
Expand Down
4 changes: 3 additions & 1 deletion examples/multisig.py
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ async def main(should_wait_input=True):
# :!:>section_12
print("\n=== Invoking Move script ===")

with open(f"{build_path}bytecode_scripts/set_and_transfer.mv", "rb") as f:
with open(f"{build_path}bytecode_scripts/set_and_transfer_0.mv", "rb") as f:
script_code = f.read()

payload = Script(
Expand Down Expand Up @@ -471,6 +471,8 @@ async def main(should_wait_input=True):
print(f"Chad's balance: {chad_balance}")
print(f"Multisig balance: {multisig_balance}") # <:!:section_12

await rest_client.close()


if __name__ == "__main__":
asyncio.run(main())
2 changes: 2 additions & 0 deletions examples/your_coin.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,8 @@ async def main(moon_coin_path: str):
balance = await rest_client.get_balance(alice.address(), bob.address())
print(f"Bob's updated MoonCoin balance: {balance}")

await rest_client.close()


if __name__ == "__main__":
assert (
Expand Down
1 change: 1 addition & 0 deletions features/stubs/behave/model_core.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ class Status(Enum):
failed: int
undefined: int
executing: int
IGNORE_LINT = 99 # Used to ignore linting error
def __eq__(self, other): ...
@classmethod
def from_name(cls, name): ...
Expand Down
1,751 changes: 982 additions & 769 deletions poetry.lock

Large diffs are not rendered by default.

22 changes: 11 additions & 11 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "aptos-sdk"
version = "0.10.0"
version = "0.11.0"
description = "Aptos SDK"
authors = ["Aptos Labs <[email protected]>"]
license = "Apache-2.0"
Expand All @@ -15,21 +15,21 @@ keywords = ["web3", "sdk", "aptos", "blockchain"]
[tool.poetry.dependencies]
ecdsa = "0.18.0"
python-graphql-client = "^0.4.3"
httpx = "^0.27.0"
httpx = {extras = ["http2"], version = "^0.28.0"}
PyNaCl = "^1.5.0"
python = ">=3.8.1"
tomli = "^2.0.1"
python = ">=3.9.0"
tomli = "^2.2.0"
typing-extensions = "^4.4.0"
behave = "^1.2.6"
types-six = "^1.16.21.20240513"
types-six = "^1.17.0"

[tool.poetry.dev-dependencies]
autoflake = "2.2.0"
black = "^24.3.0"
coverage = "^7.2.4"
flake8 = "7.0.0"
isort = "^5.10.1"
mypy = "^1.0.0"
autoflake = "^2.3.0"
black = "^24.10.0"
coverage = "^7.6.0"
flake8 = "^7.1.0"
isort = "^5.13.0"
mypy = "^1.14.0"
mypy-extensions = "^1.0.0"

[build-system]
Expand Down
Loading