From b80d207cb078e237f6a6113496464ef51983de21 Mon Sep 17 00:00:00 2001 From: Etienne Wallet <116115319+EtienneWallet@users.noreply.github.com> Date: Tue, 11 Feb 2025 06:11:36 +0100 Subject: [PATCH] fix: adapt tutorials --- scripts/run_tutorials.sh | 6 +++--- tutorials/enhanced_first_scene/mxops_scenes/01_deploy.yaml | 5 +++-- tutorials/first_scene/first_scene.yaml | 2 ++ .../mxops_scenes/{onedex_with_abi.yaml => onedex.yaml} | 3 --- tutorials/queries/mxops_scenes/xexchange_without_abi.yaml | 4 ---- .../{execute_onedex_with_abi.sh => execute_onedex.sh} | 2 +- 6 files changed, 9 insertions(+), 13 deletions(-) rename tutorials/queries/mxops_scenes/{onedex_with_abi.yaml => onedex.yaml} (91%) rename tutorials/queries/scripts/{execute_onedex_with_abi.sh => execute_onedex.sh} (66%) diff --git a/scripts/run_tutorials.sh b/scripts/run_tutorials.sh index dd142f5..7d949fb 100644 --- a/scripts/run_tutorials.sh +++ b/scripts/run_tutorials.sh @@ -7,7 +7,7 @@ uv venv $ENV_NAME --python 3.11 source ${ENV_NAME}/bin/activate # install project -uv pip install -r pyproject.toml +uv pip install . # launch first scene tutorial cd tutorials/first_scene @@ -23,9 +23,9 @@ bash scripts/execute_pong_scene.sh # launch queries tutorial cd ../queries -bash scripts/execute_onedex_with_abi.sh -bash scripts/execute_xexchange_without_abi.sh +bash scripts/execute_onedex.sh # remove env +cd ../.. deactivate rm -rf ${ENV_NAME} \ No newline at end of file diff --git a/tutorials/enhanced_first_scene/mxops_scenes/01_deploy.yaml b/tutorials/enhanced_first_scene/mxops_scenes/01_deploy.yaml index f412a5b..56ce89c 100644 --- a/tutorials/enhanced_first_scene/mxops_scenes/01_deploy.yaml +++ b/tutorials/enhanced_first_scene/mxops_scenes/01_deploy.yaml @@ -14,8 +14,9 @@ steps: contract_id: "egld-ping-pong" gas_limit: 40000000 arguments: - - "$PING_PONG_AMOUNT:int" - - "$PONG_WAIT_TIME:int" + - "$PING_PONG_AMOUNT" + - "$PONG_WAIT_TIME" + - null upgradeable: true readable: false payable: false diff --git a/tutorials/first_scene/first_scene.yaml b/tutorials/first_scene/first_scene.yaml index 91759b0..3b1a6f0 100644 --- a/tutorials/first_scene/first_scene.yaml +++ b/tutorials/first_scene/first_scene.yaml @@ -13,11 +13,13 @@ steps: - type: ContractDeploy sender: owner wasm_path: "./contract/ping-pong/output/ping-pong.wasm" + abi_path: "./contract/ping-pong/output/ping-pong.abi.json" contract_id: "egld-ping-pong" gas_limit: 40000000 arguments: - 500000000000000000 - 1 + - null upgradeable: true readable: false payable: false diff --git a/tutorials/queries/mxops_scenes/onedex_with_abi.yaml b/tutorials/queries/mxops_scenes/onedex.yaml similarity index 91% rename from tutorials/queries/mxops_scenes/onedex_with_abi.yaml rename to tutorials/queries/mxops_scenes/onedex.yaml index a3b6e1f..d3bc639 100644 --- a/tutorials/queries/mxops_scenes/onedex_with_abi.yaml +++ b/tutorials/queries/mxops_scenes/onedex.yaml @@ -1,9 +1,6 @@ allowed_networks: - mainnet -allowed_scenario: - - .* - external_contracts: onedex-swap: address: erd1qqqqqqqqqqqqqpgqqz6vp9y50ep867vnr296mqf3dduh6guvmvlsu3sujc diff --git a/tutorials/queries/mxops_scenes/xexchange_without_abi.yaml b/tutorials/queries/mxops_scenes/xexchange_without_abi.yaml index d10ce78..aa8817c 100644 --- a/tutorials/queries/mxops_scenes/xexchange_without_abi.yaml +++ b/tutorials/queries/mxops_scenes/xexchange_without_abi.yaml @@ -13,7 +13,3 @@ steps: contract: xexchange-wegld-usdc endpoint: getReservesAndTotalSupply print_results: true - results_types: - - type: BigUint - - type: BigUint - - type: BigUint diff --git a/tutorials/queries/scripts/execute_onedex_with_abi.sh b/tutorials/queries/scripts/execute_onedex.sh similarity index 66% rename from tutorials/queries/scripts/execute_onedex_with_abi.sh rename to tutorials/queries/scripts/execute_onedex.sh index 99ccb58..0144d30 100644 --- a/tutorials/queries/scripts/execute_onedex_with_abi.sh +++ b/tutorials/queries/scripts/execute_onedex.sh @@ -4,4 +4,4 @@ mxops execute \ -n mainnet \ -s temp \ -d \ - mxops_scenes/onedex_with_abi.yaml \ No newline at end of file + mxops_scenes/onedex.yaml \ No newline at end of file