Commit Graph
25 Commits
Author SHA1 Message Date
dependabot[bot]GitHubdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>Earle Lowe
0a818825bc build(deps): bump mypy from 1.18.2 to 1.19.1 (#20363)
* build(deps): bump mypy from 1.18.2 to 1.19.1

Bumps [mypy](https://github.com/python/mypy) from 1.18.2 to 1.19.1.
- [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md)
- [Commits](https://github.com/python/mypy/compare/v1.18.2...v1.19.1)

---
updated-dependencies:
- dependency-name: mypy
  dependency-version: 1.19.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* mypy fixes

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Earle Lowe <e.lowe@chia.net>
2026-02-10 11:01:32 -08:00
Matt HauffandGitHub 4ace81ae17 [LABS-294] Add kw_only to all wallet RPC types (#20324)
Add `kw_only` to all wallet RPC types
2026-01-21 09:48:44 -08:00
Matt HauffandGitHub 40db4635a8 [LABS-245] Enable PEP604 Ruff rules (#20269)
* Enable PEP604 Ruff rules

* Fix harcoded signature in test

* Hack CLVMStreamable test with note to fast follow
2025-11-18 12:34:00 -08:00
2971eb0a3c [LABS-290] Port test_wallet_rpc.py to WalletTestFramework (#20253)
* Port `test_send_transaction`

* Port `test_push_transactions`

* Port `test_get_balance`

* Port `test_get_farmed_amount`

* Port `test_get_farmed_amount_with_fee`

* Port `test_get_timestamp_for_height`

* (restrict some parametrizations)

* Port `create_signed_transaction` (and fix WalletTestFramework)

* Port `test_create_signed_transaction_with_puzzle/coin_announcement`

* Port `test_create_signed_transaction_with_excluded_coins`

* Port `test_get_transactions`

* Port `test_get_transaction_count`

* Port `test_get_coin_records_by_names`

* Port `test_did_endpoints`

* Port `test_nft_endpoints`

* Port `test_key_and_address_endpoints`

* Port `test_select_coins_rpc`

* Port `test_get_coin_records_rpc`

* Port `test_get_coin_records_rpc_limits/failures`

* Port `test_notification_rpcs`

* Port `test_verify_signature`

* Port `test_set_wallet_resync_on_startup`

* Port `test_set_wallet_resync_on_startup_disable`

* Port `test_set_wallet_resync_schema`

* Port `test_cat_spend_run_tail`

* Port `test_get_balances`

* Delete unused fixtures

* Remove DEFAULT_TX_CONFIG

* Fix reuse_puzhash behavior

* Minor improvements.

---------

Co-authored-by: Amine Khaldi <amine.khaldi@reactos.org>
2025-11-15 10:52:36 -08:00
deepdringandGitHub 30e3985ee0 chore: fix some minor issues in comment (#19980)
chore: fix some minor issues in the comment

Signed-off-by: deepdring <deepdrink@icloud.com>
2025-10-17 06:33:45 -07:00
Matt HauffandGitHub 42da90e105 [CHIA-3294] Port get_wallet_balance(s) to @marshal (#19774)
* Port `get_wallet_balance(s)`

* Use Streamable dict functionality
2025-08-05 13:11:24 -07:00
Kyle AltendorfandGitHub 32ca9c0804 by service not layer (#19715)
* by service not layer

* monkey patch fixup
2025-06-16 14:31:51 -07:00
Matt HauffandGitHub ad46ee2301 [CHIA-2546] Refactor and add test for WSM puzzle hash endpoints (#19385)
refactor puzzle hash requests
2025-03-26 13:08:00 -07:00
Kyle AltendorfandGitHub d50b6e0883 use chia_rs directly for sized bytes (#19326) 2025-02-28 09:35:25 -08:00
Kyle AltendorfandGitHub e446d6b726 use chia_rs directly for sized ints (#19303)
* use chia_rs directly for sized ints

* Update data_layer_rpc_api.py
2025-02-24 14:33:09 -08:00
Kyle AltendorfandGitHub 45465b4865 move some non-framework items out of chia.cmds.cmd_classes (#19047)
* move some non-framework items out of `chia.cmds.cmd_classes`

* move the other new stuff too
2024-12-17 14:14:13 -07:00
61207d2435 [CHIA-1348] Port chia wallet coin commands to @chia_command framework (#18641)
* Extract TransactionsIn/Out

* Create a helper for coin selection arguments

* Port `chia wallet coins list`

* Unused item

* Add TransactionEndpoint

* Port `chia wallet coins combine`

* Port `chia wallet coins split`

* Delete test_coins.py

* Add test for TXConfig helpers

* Add test for TransactionEndpoint mixin

* Forgot to delete old split command

* test coverage

* coverage ignores

* Link old framework with new

* fix command tests

* fix signer test

* coverage ignores

* pre-commit

* Move tests back to rpc file

* Move coin functions back to their own file

* Move split above combine in rpc tests

* Stop duplicate name definitions

* new puzzle hashes allowed

* Address comments by @altendky

* more comments by @altendky

* Update chia/cmds/cmd_classes.py

Co-authored-by: Kyle Altendorf <sda@fstab.net>

* another comment by @altendky

* this one is the fault of @altendky

---------

Co-authored-by: Kyle Altendorf <sda@fstab.net>
2024-12-17 10:44:33 -07:00
Almog De PazandGitHub 35c83753aa Unconfirmed tx cache - CHIA-785 (#18422)
* unconfirmed_tx_cache

* fix types in test

* fix already included check
2024-12-10 06:38:53 -07:00
dependabot[bot]GitHubdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>MattKyle Altendorf
29d2eedd3c build(deps): bump ruff from 0.7.1 to 0.8.1 (#18973)
* build(deps): bump ruff from 0.7.1 to 0.8.1

Bumps [ruff](https://github.com/astral-sh/ruff) from 0.7.1 to 0.8.1.
- [Release notes](https://github.com/astral-sh/ruff/releases)
- [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md)
- [Commits](https://github.com/astral-sh/ruff/compare/0.7.1...0.8.1)

---
updated-dependencies:
- dependency-name: ruff
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Fix ruff issues

* >-

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Matt <quexington@gmail.com>
Co-authored-by: Kyle Altendorf <sda@fstab.net>
2024-12-04 08:59:18 -07:00
Matt HauffandGitHub 9755c46dec [CHIA-1773] Add better reuse_puzhash checking to WalletTestFramework (#18897)
* Add better reuse_puzhash checking to WalletTestFramework

* Do more sophisticated monkeypatching

* Fix `test_did_find_lost_did`

* Add ability to ignore reuse_puzhash enforcement

* Actually fix `test_did_find_lost_did`

* Fix `test_nft_with_did_wallet_creation`

* Fix `test_split_coins`

* Fix `test_did_attest_after_recovery`
2024-11-22 13:05:29 -08:00
Matt HauffandGitHub 604fc1feb0 [CHIA-1732] Add Ruff specific linting rules (#18845)
* Add Ruff specific linting rules

* Further tighten ignore list

* Address comments by @altendky

* One more comment @altendky
2024-11-14 15:58:12 -07:00
6c90a76b56 Tighten up ruff ignore list (#18837)
* Tighten up ruff ignore list

* Okay that fix was indeed unsafe

* enable type-name-incorrect-variance

* enable literal-membership

* enable non-augmented-assignment

* enable useless-return

* enable global-variable-not-assigned

* -

* fixup

* Clean up roff.toml from annotations

* use ignore instead of explicit re-export

* use more descriptive names

---------

Co-authored-by: Kyle Altendorf <sda@fstab.net>
2024-11-12 12:19:31 -07:00
Matt HauffandGitHub 2808ee2446 [CHIA-1681] Replace black with Ruff (#18813)
* Replace black with Ruff

* Change build_network_protocol_files.py
2024-11-04 15:22:18 -07:00
Almog De PazandGitHub a80d779fe6 refactor full_node add_block (#18584)
* refactor

* minor fixes

* fix_tests

* add finish sync to add_blocks_in_batches

* add_blocks_in_batches updates wallets

* test fixes

* fix condition in add_block

* add known block to cache

* restore comment

* remove init file from log dir

* fix failed reorg test

* revert known block info change

* assert height in cat test

* wait for wallet height in nft test

* assert sync all height for all wallets

* test_cat_creation assert height

* rename vars

* assert height in process states
2024-10-22 12:14:18 -07:00
Kyle AltendorfandGitHub 9c8557a1f8 Remove Python 3.8 support and update source to 3.9 standards (#18687)
* manual python 3.8 removals

* poetry

* pyupgrade

* black

* isort

* manually tidy imports

* work around shadowed type

* catch up build network protocol files for pyupgrade changes

* placate pylint

* re-enable 20.04

* placate flake8
2024-10-16 14:21:15 -07:00
111b0e57d5 Port test_trades.py to WalletTestFramework (#18590)
* Port `test_trade_cancellation`

* Delete obsolete test

* Port `test_trade_conflict`

* Port `test_trade_bad_spend`

* Port `test_trade_high_fee`

* Port `test_aggregated_trade_state`

* Remove DEFAULT_TX_CONFIG

* Remove accidental comments

* Use fee in our respond_to_offer call.

* Minor readability tweak.

---------

Co-authored-by: Amine Khaldi <amine.khaldi@reactos.org>
2024-09-20 15:04:32 -07:00
Matt HauffandGitHub ac8b96defd [CHIA-1346] Add a full node RPC client to WalletTestFramework (#18580)
* Add a full node RPC client to `WalletTestFramework`

* Add test

* comments by @altendky
2024-09-11 17:01:37 -05:00
835c1f8924 Port tests/wallet/test_wallet.py to WalletTestFramework (#17687)
* Port test_wallet_coinbase

* Port test_wallet_make_transaction

* Port test_wallet_reuse_address

* Port test_wallet_clawback_claim_auto

* Port test_wallet_clawback_clawback

* Port test_wallet_clawback_sent_self

* Port test_wallet_clawback_claim_manual

* Port test_wallet_clawback_reorg

* Rebase fixes and flakiness improvements

* Port test_get_clawback_coins

* Port test_clawback_resync

* Port test_wallet_coinbase_reorg

* Port test_wallet_make_transaction_hop

* Port test_wallet_make_transaction_with_fee

* Port test_wallet_make_transaction_with_memo

* Port test_wallet_create_hit_max_send_amount

* Port test_wallet_prevent_fee_theft

* Port test_wallet_tx_reorg

* Port test_address_sliding_window

* Port test_sign_message

* Port test_wallet_transaction_options

* Remove unneeded check_balances call.

* Introduce tx_amount and use it across test_wallet_clawback_claim_auto.

* Reapply b79ecd2 (got lost in the recent merge).

* Minor improvements to test_wallet_clawback_clawback:

* Introduce tx_amount and test_fees and use them to clarify test conditions.
* Remove no longer needed json.dumps(resp) call.
* Remove unneeded dict() call on a {} constructed dictionary.

* Remove accidental change (addendum to bebc87f).

* More tx_amount and test_fees.

* Remove no longer needed json import.

* Remove unneeded dict() calls on {} constructed dictionaries.

* Introduce tx_amount2 in test_clawback_resync and clarify state transitions.

* Clarify state transitions in test_wallet_make_transaction_hop.

* Simplify transaction_has_failed.

* Just some consistency.

* Remove unneeded check_balances calls.

---------

Co-authored-by: Amine Khaldi <amine.khaldi@reactos.org>
2024-03-20 09:08:00 -07:00
Kyle AltendorfandGitHub 2eb3633bcb json.dumps(indent=2) (#17714) 2024-03-18 10:26:13 -07:00
Kyle AltendorfandGitHub a89222a428 move tests (#17209)
* prep

* verify source and installed tests match

* move

* remove move script
2024-03-14 10:19:20 -07:00