Skip to content

Commit

Permalink
Fix level for identity
Browse files Browse the repository at this point in the history
  • Loading branch information
tupui committed May 2, 2024
1 parent 10f9352 commit 88e9e02
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 1 deletion.
20 changes: 20 additions & 0 deletions src/soroban/deploy.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
"""
def deploy_asset(*, asset: Asset, source_account: Keypair) -> None:
source_account_ = server.load_account(source_account.public_key)
tx = (
TransactionBuilder(source_account_, Network.TESTNET_NETWORK_PASSPHRASE)
.set_timeout(300)
.append_create_stellar_asset_contract_from_asset_op(asset=asset)
.build()
)
# tx = soroban_server.prepare_transaction(tx)
# tx.sign(kp)
# send_transaction_data = soroban_server.send_transaction(tx)
# if get_transaction_data.status == GetTransactionStatus.SUCCESS:
# transaction_meta = stellar_xdr.TransactionMeta.from_xdr(
# get_transaction_data.result_meta_xdr
# )
# result = transaction_meta.v3.soroban_meta.return_value.address.contract_id.hash # type: ignore
# contract_id = StrKey.encode_contract(result)
# print(f"contract id: {contract_id}")
"""
2 changes: 1 addition & 1 deletion src/soroban/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class Identity(BaseSettings):
keypair: Keypair | None = None

model_config = SettingsConfigDict(
env_file=["identity.toml", ".soroban/identity.toml"]
env_file=["identity.toml", ".soroban/identity/identity.toml"]
)

@model_validator(mode="after")
Expand Down
File renamed without changes.

0 comments on commit 88e9e02

Please sign in to comment.