Skip to content

Commit d657cf7

Browse files
committed
Update
1 parent 9f6426d commit d657cf7

File tree

7 files changed

+30
-32
lines changed

7 files changed

+30
-32
lines changed

examples/nep-11-airdrop.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ async def example_airdrop(neoxp: shared.NeoExpress):
5252

5353
# Now let's airdrop the NFTs
5454
destination_addresses = [
55-
"NWuHQdxabXPdC6vVwJhxjYELDQPqc1d4TG",
56-
"NhVnpBxSRjkScZKHGzsEreYAMS1qRrNdaH",
55+
"Xy9pxEaPuHJFRD9MjVxA14vdARqKvxC3hJ",
56+
"XhVKWczT2euGEhv67kezpKHGAn69Ngjk4r",
5757
]
5858
print("Airdropping 1 NFT to each address and waiting for receipt...", end="")
5959
receipt = await facade.invoke(

examples/nep17-airdrop.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ async def example_airdrop(neoxp: shared.NeoExpress):
2424
# Use the generic NEP17 class to wrap the token
2525
token = NEP17Contract(shared.coz_token_hash)
2626
balance = await facade.test_invoke(token.balance_of(account.address))
27-
print(f"Current COZ token balance: {balance}")
27+
print(f"Current token balance: {balance}")
2828

2929
# First we have to mint the tokens to our own wallet
30-
# We do this by sending NEO to the contract
30+
# We do this by sending EpicChain to the contract
3131
# We increase the retry delay to match our local chain block production time
3232
neo = NeoToken()
3333
print("Minting once...", end="")
@@ -47,15 +47,15 @@ async def example_airdrop(neoxp: shared.NeoExpress):
4747
print(receipt.result)
4848

4949
balance = await facade.test_invoke(token.balance_of(account.address))
50-
print(f"New COZ token balance: {balance}")
50+
print(f"New token balance: {balance}")
5151

5252
# Now let's airdrop the tokens
5353
destination_addresses = [
54-
"NWuHQdxabXPdC6vVwJhxjYELDQPqc1d4TG",
55-
"NhVnpBxSRjkScZKHGzsEreYAMS1qRrNdaH",
56-
"NanYZRm6m6sa6Z6F3RBRYSXqdpg5rZqxdZ",
57-
"NUqLhf1p1vQyP2KJjMcEwmdEBPnbCGouVp",
58-
"NKuyBkoGdZZSLyPbJEetheRhMjeznFZszf",
54+
"XtxcQeNhLuNDucqAVynTwYBh2QHdDUyPzN",
55+
"XciXUD25yEsuMcxpq1eGoEZyLbstM3N1KE",
56+
"XsokdeQ3kXqsryRycSVd1cJ86tHJ8kn8uP",
57+
"XxBHmJuzGu8vnUnbB7ZWXWrS37hypTPwtB",
58+
"XkqcLP2QnBsHZnVnFxZ97fbsiEDAcB3bkZ",
5959
]
6060
print("Airdropping 10 tokens and waiting for receipt")
6161
print(

examples/nep17-transfer.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ async def example_transfer_neo(neoxp: shared.NeoExpress):
2424
)
2525

2626
source = account.address
27-
destination = "NUVaphUShQPD82yoXcbvFkedjHX6rUF7QQ"
27+
destination = "XyPUJMm6PhmtvGM7D1NsYagEfyNbVT1NGB"
2828
# Dedicated Neo native contract wrapper
2929
neo = NeoToken()
3030
print("Calling transfer and waiting for receipt...")
@@ -46,7 +46,7 @@ async def example_transfer_other(neoxp: shared.NeoExpress):
4646
)
4747

4848
source = account.address
49-
destination = "NUVaphUShQPD82yoXcbvFkedjHX6rUF7QQ"
49+
destination = "XyPUJMm6PhmtvGM7D1NsYagEfyNbVT1NGB"
5050

5151
# Use the generic NEP17 class to wrap the token and create a similar interface as before
5252
# The contract hash is that of our sample Nep17 token which is deployed in our neoxpress setup

examples/shared/__init__.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,13 +78,13 @@ def _verify_executable(self, full_path: str):
7878
raise ValueError(f"Invalid executable: {full_path}")
7979

8080
def initialize_with(self, batch_path: str):
81-
print("executing neo-express batch...", end="")
81+
print("executing private chain batch...", end="")
8282
cmd = f"{self.prog} batch -r {batch_path}"
8383
subprocess.run(shlex.split(cmd), check=True, stdout=subprocess.DEVNULL)
8484
print("done")
8585

8686
def run(self):
87-
print("starting neo-express...", end="")
87+
print("starting private chain...", end="")
8888
cmd = f"{self.prog} run -i {self.config_path}"
8989

9090
self._process = subprocess.Popen(
@@ -101,7 +101,7 @@ def process_stdout(process):
101101
if self._stop is True:
102102
break
103103

104-
if "Neo express is running" in output:
104+
if "EpicChain private chain is running" in output:
105105
self._ready = True
106106

107107
if self.debug:
@@ -116,7 +116,7 @@ def process_stdout(process):
116116
print("done")
117117

118118
def stop(self):
119-
print("stopping neo-express...", end="")
119+
print("stopping epicchain private chain...", end="")
120120
# break out of the process_stdout loop
121121
self._stop = True
122122
self._process.kill()

logo.png

-17.7 KB
Binary file not shown.

neo3/api/noderpc.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
"""
2-
NEO RPC Node client and response classes.
2+
EpicChain RPC Node client and response classes.
33
"""
44
from __future__ import annotations
55

@@ -406,7 +406,7 @@ def as_uint256(self) -> types.UInt256:
406406

407407
def as_address(self) -> str:
408408
"""
409-
Unwrap as NEO3 address.
409+
Unwrap as EpicChain address.
410410
"""
411411
return walletutils.script_hash_to_address(self.as_uint160())
412412

@@ -862,7 +862,7 @@ def __str__(self):
862862

863863
class EpicRpcClient(RPCClient):
864864
"""
865-
Specialised RPC client for NEO's Node RPC API.
865+
Specialised RPC client for EpicChain's Node RPC API.
866866
"""
867867

868868
def __init__(self, host: str, **kwargs):
@@ -913,7 +913,7 @@ async def find_states(
913913
Examples:
914914
# prints all deployed
915915
prefix_contract_hash = b"\x0c"
916-
async with api.EpicRpcClient("https://testnet1.neo.coz.io:443") as client:
916+
async with api.EpicRpcClient("https://testnet5-seed.epic-chain.org:20111") as client:
917917
async for k, v in client.find_states(CONTRACT_HASHES.MANAGEMENT, prefix_contract_hash):
918918
print(k, v)
919919
@@ -1030,7 +1030,7 @@ async def get_candidates(self) -> Sequence[Candidate]:
10301030

10311031
async def get_committee(self) -> tuple[cryptography.ECPoint, ...]:
10321032
"""
1033-
Fetch the public keys of the current NEO committee.
1033+
Fetch the public keys of the current EpicChian committee.
10341034
"""
10351035
response = await self._do_post("getcommittee")
10361036
return tuple(
@@ -1184,7 +1184,7 @@ async def get_unclaimed_gas(self, address: str) -> int:
11841184
Fetch the amount of unclaimed gas for the given address.
11851185
11861186
Args:
1187-
address: a NEO address.
1187+
address: a EpicChain address.
11881188
"""
11891189
result = await self._do_post("getunclaimedgas", [address])
11901190
return int(result["unclaimed"])
@@ -1340,7 +1340,7 @@ async def validate_address(self, address: str) -> bool:
13401340
Verify if the given address is valid for the network the node is running on.
13411341
13421342
Args:
1343-
address: a NEO address.
1343+
address: a EpicChain address.
13441344
"""
13451345
result = await self._do_post("validateaddress", [address])
13461346
return result["isvalid"]
@@ -1368,7 +1368,7 @@ async def print_contract_methods(
13681368

13691369
# return types are not included because ABI types like ARRAY cannot be properly translated e.g. the
13701370
# following functions both have ARRAY as return type in the ABI but their actual response is very different
1371-
# 1. NeoToken.GetNextBlockValidators returns a list of serialized ECPoints
1371+
# 1. EpicChainToken.GetNextBlockValidators returns a list of serialized ECPoints
13721372
# 2. ManagementContract.getContract a serialized ContractState (not even a list)
13731373
print(f"def {method.name}(self{params})")
13741374
print(" ")

pyproject.toml

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
[project]
2-
name = "neo-mamba"
3-
description = "Python SDK for the NEO 3 blockchain"
2+
name = "epicchain-python-sdk"
3+
description = "Python SDK for the EpicChain blockchain"
44
readme = "README.rst"
55
requires-python = ">= 3.11.0,<= 3.13"
66
license = { file = "LICENSE.md" }
7-
keywords = ["NEO", "NEO3", "blockchain", "SDK"]
7+
keywords = ["EpicChain", "blockchain", "SDK"]
88
authors = [
9-
{ name = "Erik van den Brink", email = "erik@coz.io" },
9+
{ name = "xmoohad", email = "xmoohad@epic-chain.org" },
1010
]
1111
maintainers = [
12-
{ name = "Erik van den Brink", email = "erik@coz.io" },
12+
{ name = "xmoohad", email = "xmoohad@epic-chain.or" },
1313
]
1414
dynamic = ["version"]
1515
dependencies = [
@@ -47,9 +47,7 @@ docs = [
4747
]
4848

4949
[project.urls]
50-
repository = "https://github.com/CityOfZion/neo-mamba"
51-
documentation = "https://mamba.coz.io/"
52-
50+
repository = "https://github.com/epicchainlabs/Python-SDK-for-the-EpicChain-blockchain"
5351

5452
[build-system]
5553
requires = ["setuptools"]

0 commit comments

Comments
 (0)