Starknet Simple Deploy
Reason this release was yanked:
does not function and match github tag
Project description
Starknet Simple Deploy
Overview
Starknet Simple Deploy is a Python package designed to simplify the process of deploying StarkNet smart contracts. It provides a set of APIs that abstract away the complexities involved in the deployment process, making it more accessible for developers of all skill levels. It utilizes API's from https://github.com/software-mansion/starknet.py
Features
- Simplified Deployment: Decalre and Deploy StarkNet smart contracts with minimal setup and configuration.
- Configurable: Supports custom deployment configurations through
DeployerConfig
. - Write Deployment Data: Supports ability to write data to a json file throug
ContractDataWriter
. - Async Support: Fully asynchronous API for efficient contract deployment.
- Error Handling: Designed to gracefully handle deployment errors and provide clear feedback.
Installation
To install Starknet Simple Deploy, run the following command in your terminal:
pip install starknet-simple-deploy
Quick Start
Here's a quick example to get you started with deploying a StarkNet smart contract:
from starknet_simple_deploy import (
DeclareContract,
DeployContract,
DeployerConfig,
ContractDataWriter,
InitializeContractData,
)
from starknet_simple_deploy.utils import get_abi
deployer_config = DeployerConfig.get_config(deploy_env, chain).init_account()
initialized_contract = InitializeContractData(contract_name="MyContract")
casm_class_hash, compiled_contract, sierra_class_hash = initialized_contract.read_contract_file_data()
declared_contract = DeclareContract(
deployer_config,
casm_class_hash,
compiled_contract,
sierra_class_hash
)
declared_contract = await declared_contract.get_contract()
deployer = DeployContract(
declared_contract,
deployer_config,
sierra_class_hash,
constructor_args={
"oracle_address": deployed_oracle_contract.address,
"contract_class_hash": sierra_class_hash
}
)
deployed_contract = await deployer.deploy()
ContractDataWriter.write_data(
deploy_env=args.deploy_env,
abi=get_abi(declared_contract),
chain_id=deployer_config.chain_id,
contract_name="MyContract",
address = deployed_contract.address
)
Contributing
Contributions are welcome! If you'd like to contribute, please fork the repository and submit a pull request with your changes. For major changes, please open an issue first to discuss what you would like to change.
License
Starknet Simple Deploy is released under the MIT License.
Support
If you have any questions or encounter any issues, please open an issue on the GitHub repository, and we'll do our best to assist you.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for starknet-simple-deploy-0.1.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 68d56c106e43737ae3591a0cb5379c2cda0b0e239c449209fdb81c4110401918 |
|
MD5 | e77d8164297ab1282e6f3ffe0484cd3d |
|
BLAKE2b-256 | 34e22561ef48ac0702c31b766d83137d1e68a2f5714bf60a00591b5454428264 |
Hashes for starknet_simple_deploy-0.1.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b75be0ab3b859ee685d4cb0d14dce4e92c43ec08d58bc4edc97f95c52007e55d |
|
MD5 | 44932d0c046929bccb6785b8408650b9 |
|
BLAKE2b-256 | 699781e0b39f4b0ec95c7cbdc35426b32fea000ecd7ef1bf05dffdb6d9be446b |