Skip to content

Support starknet_getCompiledCasm #1514

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

franciszekjob
Copy link
Collaborator

@franciszekjob franciszekjob commented Nov 3, 2024

Towards #1498

Introduced changes

Support starknet_getCompiledCasm

  • Add get_compiled_casm method in FullNodeClient and Client

  • Add models representing executables

  • This PR contains breaking changes

  • CasmClass:

    • Remove pythonic_hints
    • Change hints type from List[Any] to List[Tuple[int, List[Hint]]]

@franciszekjob franciszekjob changed the base branch from development to franciszekjob/support-rpc-0.8.0 November 3, 2024 19:35
@franciszekjob franciszekjob changed the base branch from franciszekjob/support-rpc-0.8.0 to franciszekjob/1498-rpc-0.8.0 November 3, 2024 19:35
@franciszekjob franciszekjob mentioned this pull request Nov 4, 2024
1 task
@franciszekjob franciszekjob removed the request for review from ddoktorski November 4, 2024 15:51
@franciszekjob
Copy link
Collaborator Author

note: Fore some reason circular imports test is failing, will address it later.

Copy link
Collaborator

@ddoktorski ddoktorski left a comment

Choose a reason for hiding this comment

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

Please re-request after fixing circular imports and adding tests

Base automatically changed from franciszekjob/1498-fix-network-tests to franciszekjob/1498-rpc-0.8.0 March 4, 2025 10:16
@franciszekjob
Copy link
Collaborator Author

I've added tests both on sepolia and devnet. The devnet one fails, because endpoint returns pythonic_hints which is not included in spec. Described in #1564

@franciszekjob franciszekjob marked this pull request as ready for review March 4, 2025 16:31
@franciszekjob franciszekjob requested a review from ddoktorski March 4, 2025 16:37
@ddoktorski
Copy link
Collaborator

The devnet one fails, because endpoint returns pythonic_hints which is not included in spec

Can we temporary run those tests with ignoring unknown keys in deserialization?

@franciszekjob
Copy link
Collaborator Author

franciszekjob commented Mar 5, 2025

The devnet one fails, because endpoint returns pythonic_hints which is not included in spec

Can we temporary run those tests with ignoring unknown keys in deserialization?

Sure, I've added temporary adjustment for CasmClassSchema and linked todo.

@franciszekjob franciszekjob merged commit 1bd395d into franciszekjob/1498-rpc-0.8.0 Mar 5, 2025
10 checks passed
@franciszekjob franciszekjob deleted the franciszekjob/1498-2-get-compiled-casm branch March 5, 2025 16:21
franciszekjob added a commit that referenced this pull request Apr 8, 2025
* Fix cyclic imports test

* Add ws-related dataclasses and schemas

* Add `WSClient` and `RpcWSClient`

* Add `FullNodeWSClient`

* Cleanup `FullNodeWSClient`

* Refactor `FullNodeWSClient._handle_received_message()`

* Fix circular imports

* Add `ReorgNotificationSchema`

* Add `devnet_ws` fixture

* Fix `resource_bounds` params name

* Add default values in `get_storage_proof()`

* Add `devnet_ws_client` fixture

* Add `ws_client` and `full_node_ws_client` fixtures

* Move `devnet_ws` to separate file

* Refactor `FullNodeWSClient._handle_received_message()`; Fix typechecks

* Fix formatting and linting

* Fix linting

* Update `resource_bounds` params description

* Apply other code review suggestions

* Fix description in migration guide

* Fix example snippets in readme

* Add mocked values in tests

* Add setup devnet workflow

* Change `devnet.yml` to be composite action

* Rename `l1_transaction_hash` to `transaction_hash` in `starknet_getMessagesStatus`

* Move `devnet.yml` to `composite-actions` dir

* Format

* Rename devnet composite action

* Update devnet action path

* Add missing `shell` property

* Refactor devnet installation action; Add temporary workflow which will create devnet cache

* Add inputs to steps using devnet action

* Add missing checkout step

* Add missing `devnet_sha` input to devnet setup workflow

* Fix devnet installation action - use `devnet_sha` input

* Trgigger CI

* Remove `install_devnet.yml` workflow

* Add todo in `checks.yml`

* Remove temporary step for showing dirs

* Move `parsed_abi_v2` into `test_event_serialization_v2`

* Fix formatting

* Add echo for displaying contracts v2 directory contents

* Fix displaying contents of contracts v2 directory

* Temporary change for displaying directory contents

* Temporarily list contract v2 directory

* Temporarily display owd

* Revert "Temporarily display owd"

This reverts commit 2ad7fe7.

* Include Python 3.9 in `Setup Tests` job

* Remove CI changes apart from modified devnet installation

* Temporarily display directory with compiled contracts

* Fix ls

* Fix ls

* Unconditionally compile contracts v1 and v2

* Use asdf action

* Implement `test_get_transaction_status_with_failure_reason`; Code cleanup

* Fix linting; Tests cleanup

* Update regex in `test_rejection_reason_in_transaction_receipt`

* Skip `test_compute_deploy_account_v3_transaction_hash`

* Format

* Skip `test_block_with_receipts_latest`

* Fix failing docs tests

* Fix linting

* Remove contracts conditional compilation on CI

* Add contracts compilation steps in docs tests

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_using_full_node_client`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Add todos

* Add todos in workflow

* Update resource bounds params

* Minor refactor of resource bounds params usage

* Apply code review suggestion

* Add `storage_root` field to `ContractLeafData`

* Rename `block` to `block_id` param in ws methods

* Add `is_reverted` field to `FunctionInvocation`

* Add todo

* Remove `block_id` param from `starknet_subscribeTransactionStatus` endpoint

* Remove `contracts_storage_proof` field from `ContractsProof`

* Fix `storage_root` data key

* Implement `test_get_messages_status`

* Fix `test_latest_resource_bounds_take_precedence`

* Fix `test_deploy_prefunded_account`

* Remove mocks from full node client

* Add `l1_data_gas` to `ExecutionResources`

* Update `CommonTransactionV3Fields.compute_resource_bounds_for_fee`

* Add `l1_data_gas` to ExecutionResourcesSchema`

* Fix `FullNodeClient.estimate_fee`

* Fix contract tests

* Temporarily skip some tests; Fix other tests

* Update devnet sha

* Remove code, tests and docs for old txs

* Fix lint and typecheck

* Fix formatting

* Fix lint and typecheck

* Remove old txs usages, adjust tests and docs

* Fix tests

* Remove todos

* Remove `test_account_get_balance_eth`

* Fix other tests

* Skip test

* Adjust devnet

* Fix skip mark

* Remove skip marks; Fix tests

* Update ledger app sha

* Refactor assertion in test

* Restore original `test_ci_v2`

* Remove `ResourceBounds.init_with_l1_gas_only`

* Add todos

* Formatting

* Adjust todos and fixmes

* Use `argent_account_class_hash` in `test_deploy_account_and_transfer`

* Fix `test_deploy_account_and_transfer`

* Revert "Fix `test_deploy_account_and_transfer`"

This reverts commit d4c2eed.

* Revert "Use `argent_account_class_hash` in `test_deploy_account_and_transfer`"

This reverts commit 240c8ad.

* Skip and add todo for `test_deploy_account_and_transfer`

* Update skip message for `test_get_transaction_by_block_id`

* Update todo

* Remove `--initial-balance` flag for devnet start

* Revert "Remove `--initial-balance` flag for devnet start"

This reverts commit d9a2091.

* Fix models and schemas for `get_storage_proof`; Add tests

* Add storage proof response json

* Restore values in storage proof response json

* Use shorter example response for `get_storage_proof` test

* Adjust storage proof tests

* Remove helper function

* Update migration guide

* Update migration guide

* Fix linting

* Fix formatting

* Remove unused imports

* Add file with `ContractsStorageKeysSchema`

* Fix `test_get_storage_proof`

* Remove multipliers from `EstimatedFee.to_resource_bounds`

* update todo

* Fix and update network tests

* Fix devnet client tests

* Fix CI

* Use asdf action

* Restore `Download contracts` step in CI

* Temporarily list contracts dir

* Update listing dirs

* Update listing dirs

* Temporary CI change

* Display compiled contracts path

* Compile contract before running tests in CI

* Partially implement `test_get_compiled_casm`

* Fix params in `FullNodeClient.get_compiled_casm`

* Update dependencies

* Restore read api for txs other than v3

* Refactor broadcasted txn schemas

* Add todo as skip reason

* Add `test_sign_invoke_v3_auto_estimate`

* Run `poetry lock`

* Restore test values in `test_get_transaction_by_block_id_and_index`

* Fix docs

* Docstrings formatting

* Add todos

* Remove old transactions (#1557)

* Fix `test_transaction_not_received_max_fee_too_big`

* Fix and update network tests (#1563)

* Add rust toolchain installation

* Add `HintSchema`; Rename fields

* Update field names in models

* Add tests for `get_compiled_casm`

* Move models and schema from executables api to separate files

* Add docs

* Fix migration guide

* Rename file

* Fix `test_get_compiled_casm` for devnet

* Remove unused import

* Add `STARKNET_PY_MARSHMALLOW_UNKNOWN_EXCLUDE` to CI

* Change `index_delta_minus_1` to `index_delta_minus1`

* Add fixes in executables schemas and models

* Use schema with excluding unknown fields for `CasmClassSchema`

* Update todos

* Support `starknet_getCompiledCasm` (#1514)

* Add todos

* Add missing websocket API methods; Add tests

* Fix formatting

* Remove composite action

* Format and lint

* Add more tests

* Further improvements of websocket client

* Remove api docs (will be added in subsequent PR)

* Run `poetry lock`

* Update docstrings

* Add `WebsocketClientError`

* Fix `pytest_plugins`

* Remove unused schemas; Refactor passing block number and block hash params

* Remove unused `WSClient`

* Add `devnet_ws` fixture

* Add `test_new_heads_subscription_block_not_found`

* Remove prints

* Fix passing block id

* Update websocket schemas

* Add devnet websocket fixture

* Remove `test_new_heads_subscription_block_not_found`

* Restructure files; Add new tests

* Remove unused model

* Add missing docstrings

* Update subscription id type to `str` (RPC 0.8.1)

* Fix formatting

* Remove unused schema

* Add `is_connected` property; Add connection test

* Little comments cleanup

* Rename `reorg_notification_handler` to `on_chain_reorg`

* Fix formatting

* Fix serialize method in `PendingTransactionsNotificationResultField`

* Apply code review suggestions

* Change subscription id type to int

* Change type of subscription id to str
franciszekjob added a commit that referenced this pull request Apr 8, 2025
* Add `ws_client` and `full_node_ws_client` fixtures

* Move `devnet_ws` to separate file

* Refactor `FullNodeWSClient._handle_received_message()`; Fix typechecks

* Fix formatting and linting

* Fix linting

* Update `resource_bounds` params description

* Apply other code review suggestions

* Fix description in migration guide

* Fix example snippets in readme

* Add mocked values in tests

* Add setup devnet workflow

* Change `devnet.yml` to be composite action

* Rename `l1_transaction_hash` to `transaction_hash` in `starknet_getMessagesStatus`

* Move `devnet.yml` to `composite-actions` dir

* Format

* Rename devnet composite action

* Update devnet action path

* Add missing `shell` property

* Refactor devnet installation action; Add temporary workflow which will create devnet cache

* Add inputs to steps using devnet action

* Add missing checkout step

* Add missing `devnet_sha` input to devnet setup workflow

* Fix devnet installation action - use `devnet_sha` input

* Trgigger CI

* Remove `install_devnet.yml` workflow

* Add todo in `checks.yml`

* Remove temporary step for showing dirs

* Move `parsed_abi_v2` into `test_event_serialization_v2`

* Fix formatting

* Add echo for displaying contracts v2 directory contents

* Fix displaying contents of contracts v2 directory

* Temporary change for displaying directory contents

* Temporarily list contract v2 directory

* Temporarily display owd

* Revert "Temporarily display owd"

This reverts commit 2ad7fe7.

* Include Python 3.9 in `Setup Tests` job

* Remove CI changes apart from modified devnet installation

* Temporarily display directory with compiled contracts

* Fix ls

* Fix ls

* Unconditionally compile contracts v1 and v2

* Use asdf action

* Implement `test_get_transaction_status_with_failure_reason`; Code cleanup

* Fix linting; Tests cleanup

* Update regex in `test_rejection_reason_in_transaction_receipt`

* Skip `test_compute_deploy_account_v3_transaction_hash`

* Format

* Skip `test_block_with_receipts_latest`

* Fix failing docs tests

* Fix linting

* Remove contracts conditional compilation on CI

* Add contracts compilation steps in docs tests

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_using_full_node_client`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Add todos

* Add todos in workflow

* Update resource bounds params

* Minor refactor of resource bounds params usage

* Apply code review suggestion

* Add `storage_root` field to `ContractLeafData`

* Rename `block` to `block_id` param in ws methods

* Add `is_reverted` field to `FunctionInvocation`

* Add todo

* Remove `block_id` param from `starknet_subscribeTransactionStatus` endpoint

* Remove `contracts_storage_proof` field from `ContractsProof`

* Fix `storage_root` data key

* Implement `test_get_messages_status`

* Fix `test_latest_resource_bounds_take_precedence`

* Fix `test_deploy_prefunded_account`

* Remove mocks from full node client

* Add `l1_data_gas` to `ExecutionResources`

* Update `CommonTransactionV3Fields.compute_resource_bounds_for_fee`

* Add `l1_data_gas` to ExecutionResourcesSchema`

* Fix `FullNodeClient.estimate_fee`

* Fix contract tests

* Temporarily skip some tests; Fix other tests

* Update devnet sha

* Remove code, tests and docs for old txs

* Fix lint and typecheck

* Fix formatting

* Fix lint and typecheck

* Remove old txs usages, adjust tests and docs

* Fix tests

* Remove todos

* Remove `test_account_get_balance_eth`

* Fix other tests

* Skip test

* Adjust devnet

* Fix skip mark

* Remove skip marks; Fix tests

* Update ledger app sha

* Refactor assertion in test

* Restore original `test_ci_v2`

* Remove `ResourceBounds.init_with_l1_gas_only`

* Add todos

* Formatting

* Adjust todos and fixmes

* Use `argent_account_class_hash` in `test_deploy_account_and_transfer`

* Fix `test_deploy_account_and_transfer`

* Revert "Fix `test_deploy_account_and_transfer`"

This reverts commit d4c2eed.

* Revert "Use `argent_account_class_hash` in `test_deploy_account_and_transfer`"

This reverts commit 240c8ad.

* Skip and add todo for `test_deploy_account_and_transfer`

* Update skip message for `test_get_transaction_by_block_id`

* Update todo

* Remove `--initial-balance` flag for devnet start

* Revert "Remove `--initial-balance` flag for devnet start"

This reverts commit d9a2091.

* Fix models and schemas for `get_storage_proof`; Add tests

* Add storage proof response json

* Restore values in storage proof response json

* Use shorter example response for `get_storage_proof` test

* Adjust storage proof tests

* Remove helper function

* Update migration guide

* Update migration guide

* Fix linting

* Fix formatting

* Remove unused imports

* Add file with `ContractsStorageKeysSchema`

* Fix `test_get_storage_proof`

* Remove multipliers from `EstimatedFee.to_resource_bounds`

* update todo

* Fix and update network tests

* Fix devnet client tests

* Fix CI

* Use asdf action

* Restore `Download contracts` step in CI

* Temporarily list contracts dir

* Update listing dirs

* Update listing dirs

* Temporary CI change

* Display compiled contracts path

* Compile contract before running tests in CI

* Partially implement `test_get_compiled_casm`

* Fix params in `FullNodeClient.get_compiled_casm`

* Update dependencies

* Restore read api for txs other than v3

* Refactor broadcasted txn schemas

* Add todo as skip reason

* Add `test_sign_invoke_v3_auto_estimate`

* Run `poetry lock`

* Restore test values in `test_get_transaction_by_block_id_and_index`

* Fix docs

* Docstrings formatting

* Add todos

* Remove old transactions (#1557)

* Fix `test_transaction_not_received_max_fee_too_big`

* Fix and update network tests (#1563)

* Add rust toolchain installation

* Add `HintSchema`; Rename fields

* Update field names in models

* Add tests for `get_compiled_casm`

* Move models and schema from executables api to separate files

* Add docs

* Fix migration guide

* Rename file

* Fix `test_get_compiled_casm` for devnet

* Remove unused import

* Add `STARKNET_PY_MARSHMALLOW_UNKNOWN_EXCLUDE` to CI

* Change `index_delta_minus_1` to `index_delta_minus1`

* Add fixes in executables schemas and models

* Use schema with excluding unknown fields for `CasmClassSchema`

* Update todos

* Support `starknet_getCompiledCasm` (#1514)

* Add todos

* Add missing websocket API methods; Add tests

* Fix formatting

* Remove composite action

* Format and lint

* Add more tests

* Further improvements of websocket client

* Remove api docs (will be added in subsequent PR)

* Run `poetry lock`

* Update docstrings

* Add `WebsocketClientError`

* Fix `pytest_plugins`

* Remove unused schemas; Refactor passing block number and block hash params

* Remove unused `WSClient`

* Add `devnet_ws` fixture

* Add `test_new_heads_subscription_block_not_found`

* Remove prints

* Fix passing block id

* Update websocket schemas

* Add devnet websocket fixture

* Remove `test_new_heads_subscription_block_not_found`

* Restructure files; Add new tests

* Remove unused model

* Add missing docstrings

* Update subscription id type to `str` (RPC 0.8.1)

* Fix formatting

* Remove unused schema

* Add `is_connected` property; Add connection test

* Little comments cleanup

* Add websockets docs; Add code examples

* Add api and guide docs files

* Remove unneeded file

* Rename `reorg_notification_handler` to `on_chain_reorg`

* Fix formatting

* Trigger CI

* Format docstrings of `subscribe_pending_transactions`

* Fix docs

* Update `transaction_details` param description

* Increase sleep time in `test_subscribe_transaction_status`

* Fix serialize method in `PendingTransactionsNotificationResultField`

* Apply code review suggestions

* Apply code review suggestions

* Change subscription id type to int

* Change type of subscription id to str
franciszekjob added a commit that referenced this pull request Apr 8, 2025
* Update devnet action path

* Add missing `shell` property

* Refactor devnet installation action; Add temporary workflow which will create devnet cache

* Add inputs to steps using devnet action

* Add missing checkout step

* Add missing `devnet_sha` input to devnet setup workflow

* Fix devnet installation action - use `devnet_sha` input

* Trgigger CI

* Remove `install_devnet.yml` workflow

* Add todo in `checks.yml`

* Remove temporary step for showing dirs

* Move `parsed_abi_v2` into `test_event_serialization_v2`

* Fix formatting

* Add echo for displaying contracts v2 directory contents

* Fix displaying contents of contracts v2 directory

* Temporary change for displaying directory contents

* Temporarily list contract v2 directory

* Temporarily display owd

* Revert "Temporarily display owd"

This reverts commit 2ad7fe7.

* Include Python 3.9 in `Setup Tests` job

* Remove CI changes apart from modified devnet installation

* Temporarily display directory with compiled contracts

* Fix ls

* Fix ls

* Unconditionally compile contracts v1 and v2

* Use asdf action

* Implement `test_get_transaction_status_with_failure_reason`; Code cleanup

* Fix linting; Tests cleanup

* Update regex in `test_rejection_reason_in_transaction_receipt`

* Skip `test_compute_deploy_account_v3_transaction_hash`

* Format

* Skip `test_block_with_receipts_latest`

* Fix failing docs tests

* Fix linting

* Remove contracts conditional compilation on CI

* Add contracts compilation steps in docs tests

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_using_full_node_client`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Add todos

* Add todos in workflow

* Update resource bounds params

* Minor refactor of resource bounds params usage

* Apply code review suggestion

* Add `storage_root` field to `ContractLeafData`

* Rename `block` to `block_id` param in ws methods

* Add `is_reverted` field to `FunctionInvocation`

* Add todo

* Remove `block_id` param from `starknet_subscribeTransactionStatus` endpoint

* Remove `contracts_storage_proof` field from `ContractsProof`

* Fix `storage_root` data key

* Implement `test_get_messages_status`

* Fix `test_latest_resource_bounds_take_precedence`

* Fix `test_deploy_prefunded_account`

* Remove mocks from full node client

* Add `l1_data_gas` to `ExecutionResources`

* Update `CommonTransactionV3Fields.compute_resource_bounds_for_fee`

* Add `l1_data_gas` to ExecutionResourcesSchema`

* Fix `FullNodeClient.estimate_fee`

* Fix contract tests

* Temporarily skip some tests; Fix other tests

* Update devnet sha

* Remove code, tests and docs for old txs

* Fix lint and typecheck

* Fix formatting

* Fix lint and typecheck

* Remove old txs usages, adjust tests and docs

* Fix tests

* Remove todos

* Remove `test_account_get_balance_eth`

* Fix other tests

* Skip test

* Adjust devnet

* Fix skip mark

* Remove skip marks; Fix tests

* Update ledger app sha

* Refactor assertion in test

* Restore original `test_ci_v2`

* Remove `ResourceBounds.init_with_l1_gas_only`

* Add todos

* Formatting

* Adjust todos and fixmes

* Use `argent_account_class_hash` in `test_deploy_account_and_transfer`

* Fix `test_deploy_account_and_transfer`

* Revert "Fix `test_deploy_account_and_transfer`"

This reverts commit d4c2eed.

* Revert "Use `argent_account_class_hash` in `test_deploy_account_and_transfer`"

This reverts commit 240c8ad.

* Skip and add todo for `test_deploy_account_and_transfer`

* Update skip message for `test_get_transaction_by_block_id`

* Update todo

* Remove `--initial-balance` flag for devnet start

* Revert "Remove `--initial-balance` flag for devnet start"

This reverts commit d9a2091.

* Fix models and schemas for `get_storage_proof`; Add tests

* Add storage proof response json

* Restore values in storage proof response json

* Use shorter example response for `get_storage_proof` test

* Adjust storage proof tests

* Remove helper function

* Update migration guide

* Update migration guide

* Fix linting

* Fix formatting

* Remove unused imports

* Add file with `ContractsStorageKeysSchema`

* Fix `test_get_storage_proof`

* Remove multipliers from `EstimatedFee.to_resource_bounds`

* update todo

* Fix and update network tests

* Fix devnet client tests

* Fix CI

* Use asdf action

* Restore `Download contracts` step in CI

* Temporarily list contracts dir

* Update listing dirs

* Update listing dirs

* Temporary CI change

* Display compiled contracts path

* Compile contract before running tests in CI

* Partially implement `test_get_compiled_casm`

* Fix params in `FullNodeClient.get_compiled_casm`

* Update dependencies

* Restore read api for txs other than v3

* Refactor broadcasted txn schemas

* Add todo as skip reason

* Add `test_sign_invoke_v3_auto_estimate`

* Run `poetry lock`

* Restore test values in `test_get_transaction_by_block_id_and_index`

* Fix docs

* Docstrings formatting

* Add todos

* Remove old transactions (#1557)

* Fix `test_transaction_not_received_max_fee_too_big`

* Fix and update network tests (#1563)

* Add rust toolchain installation

* Add `HintSchema`; Rename fields

* Update field names in models

* Add tests for `get_compiled_casm`

* Move models and schema from executables api to separate files

* Add docs

* Fix migration guide

* Rename file

* Fix `test_get_compiled_casm` for devnet

* Remove unused import

* Add `STARKNET_PY_MARSHMALLOW_UNKNOWN_EXCLUDE` to CI

* Change `index_delta_minus_1` to `index_delta_minus1`

* Add fixes in executables schemas and models

* Use schema with excluding unknown fields for `CasmClassSchema`

* Update todos

* Support `starknet_getCompiledCasm` (#1514)

* Add todos

* Add missing websocket API methods; Add tests

* Fix formatting

* Remove composite action

* Format and lint

* Add more tests

* Further improvements of websocket client

* Remove api docs (will be added in subsequent PR)

* Run `poetry lock`

* Update docstrings

* Add `WebsocketClientError`

* Fix `pytest_plugins`

* Remove unused schemas; Refactor passing block number and block hash params

* Remove unused `WSClient`

* Add `devnet_ws` fixture

* Add `test_new_heads_subscription_block_not_found`

* Remove prints

* Fix passing block id

* Update websocket schemas

* Add devnet websocket fixture

* Remove `test_new_heads_subscription_block_not_found`

* Restructure files; Add new tests

* Remove unused model

* Add missing docstrings

* Update subscription id type to `str` (RPC 0.8.1)

* Fix formatting

* Remove unused schema

* Add `is_connected` property; Add connection test

* Little comments cleanup

* Add websockets docs; Add code examples

* Add api and guide docs files

* Remove unneeded file

* Rename `reorg_notification_handler` to `on_chain_reorg`

* Fix formatting

* Trigger CI

* Format docstrings of `subscribe_pending_transactions`

* Fix docs

* Update `transaction_details` param description

* Increase sleep time in `test_subscribe_transaction_status`

* Fix serialize method in `PendingTransactionsNotificationResultField`

* Temporarily disable braavos integration

* Fix migration guide

* Update docs

* Update migration guide; Bump version

* Code refactor

* Apply code review suggestions

* Apply code review suggestions

* Change subscription id type to int

* Change RPC to 0.8.0 in migration guide

* Remove braavos-related changes

* Remove util file

* Bump version in `pyproject.toml`

* Change type of subscription id to str

* Apply code review suggestions

* Update migration guide
franciszekjob added a commit that referenced this pull request Apr 9, 2025
* Move `devnet.yml` to `composite-actions` dir

* Format

* Rename devnet composite action

* Update devnet action path

* Add missing `shell` property

* Refactor devnet installation action; Add temporary workflow which will create devnet cache

* Add inputs to steps using devnet action

* Add missing checkout step

* Add missing `devnet_sha` input to devnet setup workflow

* Fix devnet installation action - use `devnet_sha` input

* Trgigger CI

* Remove `install_devnet.yml` workflow

* Add todo in `checks.yml`

* Remove temporary step for showing dirs

* Move `parsed_abi_v2` into `test_event_serialization_v2`

* Fix formatting

* Add echo for displaying contracts v2 directory contents

* Fix displaying contents of contracts v2 directory

* Temporary change for displaying directory contents

* Temporarily list contract v2 directory

* Temporarily display owd

* Revert "Temporarily display owd"

This reverts commit 2ad7fe7.

* Include Python 3.9 in `Setup Tests` job

* Remove CI changes apart from modified devnet installation

* Temporarily display directory with compiled contracts

* Fix ls

* Fix ls

* Unconditionally compile contracts v1 and v2

* Use asdf action

* Implement `test_get_transaction_status_with_failure_reason`; Code cleanup

* Fix linting; Tests cleanup

* Update regex in `test_rejection_reason_in_transaction_receipt`

* Skip `test_compute_deploy_account_v3_transaction_hash`

* Format

* Skip `test_block_with_receipts_latest`

* Fix failing docs tests

* Fix linting

* Remove contracts conditional compilation on CI

* Add contracts compilation steps in docs tests

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_using_full_node_client`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Add todos

* Add todos in workflow

* Update resource bounds params

* Minor refactor of resource bounds params usage

* Apply code review suggestion

* Add `storage_root` field to `ContractLeafData`

* Rename `block` to `block_id` param in ws methods

* Add `is_reverted` field to `FunctionInvocation`

* Add todo

* Remove `block_id` param from `starknet_subscribeTransactionStatus` endpoint

* Remove `contracts_storage_proof` field from `ContractsProof`

* Fix `storage_root` data key

* Implement `test_get_messages_status`

* Fix `test_latest_resource_bounds_take_precedence`

* Fix `test_deploy_prefunded_account`

* Remove mocks from full node client

* Add `l1_data_gas` to `ExecutionResources`

* Update `CommonTransactionV3Fields.compute_resource_bounds_for_fee`

* Add `l1_data_gas` to ExecutionResourcesSchema`

* Fix `FullNodeClient.estimate_fee`

* Fix contract tests

* Temporarily skip some tests; Fix other tests

* Update devnet sha

* Remove code, tests and docs for old txs

* Fix lint and typecheck

* Fix formatting

* Fix lint and typecheck

* Remove old txs usages, adjust tests and docs

* Fix tests

* Remove todos

* Remove `test_account_get_balance_eth`

* Fix other tests

* Skip test

* Adjust devnet

* Fix skip mark

* Remove skip marks; Fix tests

* Update ledger app sha

* Refactor assertion in test

* Restore original `test_ci_v2`

* Remove `ResourceBounds.init_with_l1_gas_only`

* Add todos

* Formatting

* Adjust todos and fixmes

* Use `argent_account_class_hash` in `test_deploy_account_and_transfer`

* Fix `test_deploy_account_and_transfer`

* Revert "Fix `test_deploy_account_and_transfer`"

This reverts commit d4c2eed.

* Revert "Use `argent_account_class_hash` in `test_deploy_account_and_transfer`"

This reverts commit 240c8ad.

* Skip and add todo for `test_deploy_account_and_transfer`

* Update skip message for `test_get_transaction_by_block_id`

* Update todo

* Remove `--initial-balance` flag for devnet start

* Revert "Remove `--initial-balance` flag for devnet start"

This reverts commit d9a2091.

* Fix models and schemas for `get_storage_proof`; Add tests

* Add storage proof response json

* Restore values in storage proof response json

* Use shorter example response for `get_storage_proof` test

* Adjust storage proof tests

* Remove helper function

* Update migration guide

* Update migration guide

* Fix linting

* Fix formatting

* Remove unused imports

* Add file with `ContractsStorageKeysSchema`

* Fix `test_get_storage_proof`

* Remove multipliers from `EstimatedFee.to_resource_bounds`

* update todo

* Fix and update network tests

* Fix devnet client tests

* Fix CI

* Use asdf action

* Restore `Download contracts` step in CI

* Temporarily list contracts dir

* Update listing dirs

* Update listing dirs

* Temporary CI change

* Display compiled contracts path

* Compile contract before running tests in CI

* Partially implement `test_get_compiled_casm`

* Fix params in `FullNodeClient.get_compiled_casm`

* Update dependencies

* Restore read api for txs other than v3

* Refactor broadcasted txn schemas

* Add todo as skip reason

* Add `test_sign_invoke_v3_auto_estimate`

* Run `poetry lock`

* Restore test values in `test_get_transaction_by_block_id_and_index`

* Fix docs

* Docstrings formatting

* Add todos

* Remove old transactions (#1557)

* Fix `test_transaction_not_received_max_fee_too_big`

* Fix and update network tests (#1563)

* Add rust toolchain installation

* Add `HintSchema`; Rename fields

* Update field names in models

* Add tests for `get_compiled_casm`

* Move models and schema from executables api to separate files

* Add docs

* Fix migration guide

* Rename file

* Fix `test_get_compiled_casm` for devnet

* Remove unused import

* Add `STARKNET_PY_MARSHMALLOW_UNKNOWN_EXCLUDE` to CI

* Change `index_delta_minus_1` to `index_delta_minus1`

* Add fixes in executables schemas and models

* Use schema with excluding unknown fields for `CasmClassSchema`

* Update todos

* Support `starknet_getCompiledCasm` (#1514)

* Add todos

* Add missing websocket API methods; Add tests

* Fix formatting

* Remove composite action

* Format and lint

* Add more tests

* Further improvements of websocket client

* Remove api docs (will be added in subsequent PR)

* Run `poetry lock`

* Update docstrings

* Add `WebsocketClientError`

* Fix `pytest_plugins`

* Remove unused schemas; Refactor passing block number and block hash params

* Remove unused `WSClient`

* Add `devnet_ws` fixture

* Add `test_new_heads_subscription_block_not_found`

* Remove prints

* Fix passing block id

* Update websocket schemas

* Add devnet websocket fixture

* Remove `test_new_heads_subscription_block_not_found`

* Restructure files; Add new tests

* Remove unused model

* Add missing docstrings

* Update subscription id type to `str` (RPC 0.8.1)

* Fix formatting

* Remove unused schema

* Add `is_connected` property; Add connection test

* Little comments cleanup

* Add websockets docs; Add code examples

* Add api and guide docs files

* Remove unneeded file

* Rename `reorg_notification_handler` to `on_chain_reorg`

* Fix formatting

* Trigger CI

* Format docstrings of `subscribe_pending_transactions`

* Fix docs

* Update `transaction_details` param description

* Increase sleep time in `test_subscribe_transaction_status`

* Fix serialize method in `PendingTransactionsNotificationResultField`

* Temporarily disable braavos integration

* Fix migration guide

* Update docs

* Code refactor

* Apply code review suggestions

* Apply code review suggestions

* Change subscription id type to int

* Add changes from rpc 0.8.1

* Use sepolia client in `test_account_execute_v3_braavos`

* Update migration guide

* Update rpc and starknet version in migration guide

* Update migration guide

* Remove argent changes

* Remove account util

* Update migration guide
franciszekjob added a commit that referenced this pull request Apr 10, 2025
* Fix devnet installation action - use `devnet_sha` input

* Trgigger CI

* Remove `install_devnet.yml` workflow

* Add todo in `checks.yml`

* Remove temporary step for showing dirs

* Move `parsed_abi_v2` into `test_event_serialization_v2`

* Fix formatting

* Add echo for displaying contracts v2 directory contents

* Fix displaying contents of contracts v2 directory

* Temporary change for displaying directory contents

* Temporarily list contract v2 directory

* Temporarily display owd

* Revert "Temporarily display owd"

This reverts commit 2ad7fe7.

* Include Python 3.9 in `Setup Tests` job

* Remove CI changes apart from modified devnet installation

* Temporarily display directory with compiled contracts

* Fix ls

* Fix ls

* Unconditionally compile contracts v1 and v2

* Use asdf action

* Implement `test_get_transaction_status_with_failure_reason`; Code cleanup

* Fix linting; Tests cleanup

* Update regex in `test_rejection_reason_in_transaction_receipt`

* Skip `test_compute_deploy_account_v3_transaction_hash`

* Format

* Skip `test_block_with_receipts_latest`

* Fix failing docs tests

* Fix linting

* Remove contracts conditional compilation on CI

* Add contracts compilation steps in docs tests

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_using_full_node_client`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Add todos

* Add todos in workflow

* Update resource bounds params

* Minor refactor of resource bounds params usage

* Apply code review suggestion

* Add `storage_root` field to `ContractLeafData`

* Rename `block` to `block_id` param in ws methods

* Add `is_reverted` field to `FunctionInvocation`

* Add todo

* Remove `block_id` param from `starknet_subscribeTransactionStatus` endpoint

* Remove `contracts_storage_proof` field from `ContractsProof`

* Fix `storage_root` data key

* Implement `test_get_messages_status`

* Fix `test_latest_resource_bounds_take_precedence`

* Fix `test_deploy_prefunded_account`

* Remove mocks from full node client

* Add `l1_data_gas` to `ExecutionResources`

* Update `CommonTransactionV3Fields.compute_resource_bounds_for_fee`

* Add `l1_data_gas` to ExecutionResourcesSchema`

* Fix `FullNodeClient.estimate_fee`

* Fix contract tests

* Temporarily skip some tests; Fix other tests

* Update devnet sha

* Remove code, tests and docs for old txs

* Fix lint and typecheck

* Fix formatting

* Fix lint and typecheck

* Remove old txs usages, adjust tests and docs

* Fix tests

* Remove todos

* Remove `test_account_get_balance_eth`

* Fix other tests

* Skip test

* Adjust devnet

* Fix skip mark

* Remove skip marks; Fix tests

* Update ledger app sha

* Refactor assertion in test

* Restore original `test_ci_v2`

* Remove `ResourceBounds.init_with_l1_gas_only`

* Add todos

* Formatting

* Adjust todos and fixmes

* Use `argent_account_class_hash` in `test_deploy_account_and_transfer`

* Fix `test_deploy_account_and_transfer`

* Revert "Fix `test_deploy_account_and_transfer`"

This reverts commit d4c2eed.

* Revert "Use `argent_account_class_hash` in `test_deploy_account_and_transfer`"

This reverts commit 240c8ad.

* Skip and add todo for `test_deploy_account_and_transfer`

* Update skip message for `test_get_transaction_by_block_id`

* Update todo

* Remove `--initial-balance` flag for devnet start

* Revert "Remove `--initial-balance` flag for devnet start"

This reverts commit d9a2091.

* Fix models and schemas for `get_storage_proof`; Add tests

* Add storage proof response json

* Restore values in storage proof response json

* Use shorter example response for `get_storage_proof` test

* Adjust storage proof tests

* Remove helper function

* Update migration guide

* Update migration guide

* Fix linting

* Fix formatting

* Remove unused imports

* Add file with `ContractsStorageKeysSchema`

* Fix `test_get_storage_proof`

* Remove multipliers from `EstimatedFee.to_resource_bounds`

* update todo

* Fix and update network tests

* Fix devnet client tests

* Fix CI

* Use asdf action

* Restore `Download contracts` step in CI

* Temporarily list contracts dir

* Update listing dirs

* Update listing dirs

* Temporary CI change

* Display compiled contracts path

* Compile contract before running tests in CI

* Partially implement `test_get_compiled_casm`

* Fix params in `FullNodeClient.get_compiled_casm`

* Update dependencies

* Restore read api for txs other than v3

* Refactor broadcasted txn schemas

* Add todo as skip reason

* Add `test_sign_invoke_v3_auto_estimate`

* Run `poetry lock`

* Restore test values in `test_get_transaction_by_block_id_and_index`

* Fix docs

* Docstrings formatting

* Add todos

* Remove old transactions (#1557)

* Fix `test_transaction_not_received_max_fee_too_big`

* Fix and update network tests (#1563)

* Add rust toolchain installation

* Add `HintSchema`; Rename fields

* Update field names in models

* Add tests for `get_compiled_casm`

* Move models and schema from executables api to separate files

* Add docs

* Fix migration guide

* Rename file

* Fix `test_get_compiled_casm` for devnet

* Remove unused import

* Add `STARKNET_PY_MARSHMALLOW_UNKNOWN_EXCLUDE` to CI

* Change `index_delta_minus_1` to `index_delta_minus1`

* Add fixes in executables schemas and models

* Use schema with excluding unknown fields for `CasmClassSchema`

* Update todos

* Support `starknet_getCompiledCasm` (#1514)

* Add todos

* Add missing websocket API methods; Add tests

* Fix formatting

* Remove composite action

* Format and lint

* Add more tests

* Further improvements of websocket client

* Remove api docs (will be added in subsequent PR)

* Run `poetry lock`

* Update docstrings

* Add `WebsocketClientError`

* Fix `pytest_plugins`

* Remove unused schemas; Refactor passing block number and block hash params

* Remove unused `WSClient`

* Add `devnet_ws` fixture

* Add `test_new_heads_subscription_block_not_found`

* Remove prints

* Fix passing block id

* Update websocket schemas

* Add devnet websocket fixture

* Remove `test_new_heads_subscription_block_not_found`

* Restructure files; Add new tests

* Remove unused model

* Add missing docstrings

* Update subscription id type to `str` (RPC 0.8.1)

* Fix formatting

* Remove unused schema

* Add `is_connected` property; Add connection test

* Little comments cleanup

* Add websockets docs; Add code examples

* Add api and guide docs files

* Remove unneeded file

* Rename `reorg_notification_handler` to `on_chain_reorg`

* Fix formatting

* Trigger CI

* Format docstrings of `subscribe_pending_transactions`

* Fix docs

* Update `transaction_details` param description

* Increase sleep time in `test_subscribe_transaction_status`

* Fix serialize method in `PendingTransactionsNotificationResultField`

* Temporarily disable braavos integration

* Fix migration guide

* Update docs

* Code refactor

* Apply code review suggestions

* Apply code review suggestions

* Change subscription id type to int

* Use sepolia client in `test_account_execute_v3_braavos`

* Update migration guide

* Update migration guide

* Refactor braavos tests

* Temporarily disable running tests in parallel

* Revert "Temporarily disable running tests in parallel"

This reverts commit 54e86a4.

* Refactor braavos tests

* Fix formatting

* Restore gas amount multiplier params

* Update migration guide

* Fix linting

* Add missing envs

* Remove try/except from unnecessary places

* Fix test

* Formatting

* Trigger CI
franciszekjob added a commit that referenced this pull request Apr 10, 2025
* Temporarily display directory with compiled contracts

* Fix ls

* Fix ls

* Unconditionally compile contracts v1 and v2

* Use asdf action

* Implement `test_get_transaction_status_with_failure_reason`; Code cleanup

* Fix linting; Tests cleanup

* Update regex in `test_rejection_reason_in_transaction_receipt`

* Skip `test_compute_deploy_account_v3_transaction_hash`

* Format

* Skip `test_block_with_receipts_latest`

* Fix failing docs tests

* Fix linting

* Remove contracts conditional compilation on CI

* Add contracts compilation steps in docs tests

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Skip `test_using_full_node_client`; Add todo

* Skip `test_get_transaction_by_block_id`; Add todo

* Add todos

* Add todos in workflow

* Update resource bounds params

* Minor refactor of resource bounds params usage

* Apply code review suggestion

* Add `storage_root` field to `ContractLeafData`

* Rename `block` to `block_id` param in ws methods

* Add `is_reverted` field to `FunctionInvocation`

* Add todo

* Remove `block_id` param from `starknet_subscribeTransactionStatus` endpoint

* Remove `contracts_storage_proof` field from `ContractsProof`

* Fix `storage_root` data key

* Implement `test_get_messages_status`

* Fix `test_latest_resource_bounds_take_precedence`

* Fix `test_deploy_prefunded_account`

* Remove mocks from full node client

* Add `l1_data_gas` to `ExecutionResources`

* Update `CommonTransactionV3Fields.compute_resource_bounds_for_fee`

* Add `l1_data_gas` to ExecutionResourcesSchema`

* Fix `FullNodeClient.estimate_fee`

* Fix contract tests

* Temporarily skip some tests; Fix other tests

* Update devnet sha

* Remove code, tests and docs for old txs

* Fix lint and typecheck

* Fix formatting

* Fix lint and typecheck

* Remove old txs usages, adjust tests and docs

* Fix tests

* Remove todos

* Remove `test_account_get_balance_eth`

* Fix other tests

* Skip test

* Adjust devnet

* Fix skip mark

* Remove skip marks; Fix tests

* Update ledger app sha

* Refactor assertion in test

* Restore original `test_ci_v2`

* Remove `ResourceBounds.init_with_l1_gas_only`

* Add todos

* Formatting

* Adjust todos and fixmes

* Use `argent_account_class_hash` in `test_deploy_account_and_transfer`

* Fix `test_deploy_account_and_transfer`

* Revert "Fix `test_deploy_account_and_transfer`"

This reverts commit d4c2eed.

* Revert "Use `argent_account_class_hash` in `test_deploy_account_and_transfer`"

This reverts commit 240c8ad.

* Skip and add todo for `test_deploy_account_and_transfer`

* Update skip message for `test_get_transaction_by_block_id`

* Update todo

* Remove `--initial-balance` flag for devnet start

* Revert "Remove `--initial-balance` flag for devnet start"

This reverts commit d9a2091.

* Fix models and schemas for `get_storage_proof`; Add tests

* Add storage proof response json

* Restore values in storage proof response json

* Use shorter example response for `get_storage_proof` test

* Adjust storage proof tests

* Remove helper function

* Update migration guide

* Update migration guide

* Fix linting

* Fix formatting

* Remove unused imports

* Add file with `ContractsStorageKeysSchema`

* Fix `test_get_storage_proof`

* Remove multipliers from `EstimatedFee.to_resource_bounds`

* update todo

* Fix and update network tests

* Fix devnet client tests

* Fix CI

* Use asdf action

* Restore `Download contracts` step in CI

* Temporarily list contracts dir

* Update listing dirs

* Update listing dirs

* Temporary CI change

* Display compiled contracts path

* Compile contract before running tests in CI

* Partially implement `test_get_compiled_casm`

* Fix params in `FullNodeClient.get_compiled_casm`

* Update dependencies

* Restore read api for txs other than v3

* Refactor broadcasted txn schemas

* Add todo as skip reason

* Add `test_sign_invoke_v3_auto_estimate`

* Run `poetry lock`

* Restore test values in `test_get_transaction_by_block_id_and_index`

* Fix docs

* Docstrings formatting

* Add todos

* Remove old transactions (#1557)

* Fix `test_transaction_not_received_max_fee_too_big`

* Fix and update network tests (#1563)

* Add rust toolchain installation

* Add `HintSchema`; Rename fields

* Update field names in models

* Add tests for `get_compiled_casm`

* Move models and schema from executables api to separate files

* Add docs

* Fix migration guide

* Rename file

* Fix `test_get_compiled_casm` for devnet

* Remove unused import

* Add `STARKNET_PY_MARSHMALLOW_UNKNOWN_EXCLUDE` to CI

* Change `index_delta_minus_1` to `index_delta_minus1`

* Add fixes in executables schemas and models

* Use schema with excluding unknown fields for `CasmClassSchema`

* Update todos

* Support `starknet_getCompiledCasm` (#1514)

* Add todos

* Add missing websocket API methods; Add tests

* Fix formatting

* Remove composite action

* Format and lint

* Add more tests

* Further improvements of websocket client

* Remove api docs (will be added in subsequent PR)

* Run `poetry lock`

* Update docstrings

* Add `WebsocketClientError`

* Fix `pytest_plugins`

* Remove unused schemas; Refactor passing block number and block hash params

* Remove unused `WSClient`

* Add `devnet_ws` fixture

* Add `test_new_heads_subscription_block_not_found`

* Remove prints

* Fix passing block id

* Update websocket schemas

* Add devnet websocket fixture

* Remove `test_new_heads_subscription_block_not_found`

* Restructure files; Add new tests

* Remove unused model

* Add missing docstrings

* Update subscription id type to `str` (RPC 0.8.1)

* Fix formatting

* Remove unused schema

* Add `is_connected` property; Add connection test

* Little comments cleanup

* Add websockets docs; Add code examples

* Add api and guide docs files

* Remove unneeded file

* Rename `reorg_notification_handler` to `on_chain_reorg`

* Fix formatting

* Trigger CI

* Format docstrings of `subscribe_pending_transactions`

* Fix docs

* Update `transaction_details` param description

* Increase sleep time in `test_subscribe_transaction_status`

* Fix serialize method in `PendingTransactionsNotificationResultField`

* Temporarily disable braavos integration

* Fix migration guide

* Update docs

* Code refactor

* Apply code review suggestions

* Apply code review suggestions

* Change subscription id type to int

* Add changes from rpc 0.8.1

* Bump version; Update migration guide

* DFix migration guide

* Update migration guide

* Use sepolia client in `test_account_execute_v3_braavos`

* Update migration guide

* Update migration guide

* Refactor braavos tests

* Temporarily disable running tests in parallel

* Revert "Temporarily disable running tests in parallel"

This reverts commit 54e86a4.

* Remove todos; Restore multiplier params

* Refactor braavos tests

* Fix formatting

* Remove changes related with amount multipliers params

* Restore gas amount multiplier params

* Fix linting

* Update migration guide

* Fix linting

* Add `InnerCallExecutionResources`; Fix tests

* Update migration guide

* Update migration guide

* Add missing envs

* Remove try/except from unnecessary places

* Fix test

* Formatting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants