Commit Graph
88 Commits
Author SHA1 Message Date
dependabot[bot]GitHubdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>Earle Lowe
452cbf890d build(deps): bump ruff from 0.14.6 to 0.14.13 (#20439)
* build(deps): bump ruff from 0.14.6 to 0.14.13

Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.6 to 0.14.13.
- [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.14.6...0.14.13)

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

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

* ruff 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:17 -08:00
Arvid NorbergandGitHub 507a2b858d update the fast FullBlock parser (#20458)
* update the fast FullBlock parser (that just skips fields) to support the new serialization of RewardChainBlock

* add test and shard the test, to enable it running in parallel

* disable expensive tests on MacOS Intel

* document some aspects of the full_blocks_utils test
2026-02-10 11:00:57 -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 6a1b2314f8 [LABS-387] Revert accidental RPC parameter name change (#20362)
Revert accidental RPC parameter name change
2025-12-29 10:40:24 -08:00
Matt HauffandGitHub a745d88961 [LABS-249] Port crcat_approve_pending to @marshal (#20116)
* Port `crcat_approve_pending` to `@marshal`

* Forgot `push=True`
2025-12-09 13:15:55 -08:00
Matt HauffandGitHub a05a0c57d2 [CHIA-3707] Port create_new_wallet to @marshal (#20087)
* Add the request types

* Add the request types

* some test fixes

* Add the client ports

* Fix tests

* Add cmd support and fix a test

* Missed a couple

* Add test for `CreateNewWallet.__post_init__()`
2025-12-08 09:31:51 -08:00
Matt HauffandGitHub 8eba5d8490 [CHIA-3686] Port send_transaction_multi to @marshal (#20071)
* Port `send_transaction_multi` to `@marshal`

* test coverage
2025-12-04 09:43:05 -08:00
Matt HauffandGitHub 2b3c11e170 [CHIA-3610] Port cancel_offer(s) to @marshal (#20066)
* Port `cancel_offer` to `@marshal`

* Port `cancel_offers` to `@marshal`

* forgot `push=True`
2025-11-25 10:57:19 -08:00
Matt HauffandGitHub 5ffb3618a3 [CHIA-3609] Port get_offer(s) to @marshal (#20062)
* Port `get_offer` to `@marshal`

* Port `get_all_offers` to `@marshal`
2025-11-21 09:45:26 -08:00
Earle LoweandGitHub f6fc9328ed Change GetTransactions to use uint32 to support wallets with very large numbers of transactions (#20278) 2025-11-21 09:35:48 -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
Matt HauffandGitHub 74ec8a44d4 [CHIA-3608] Port take_offer to @marshal (#20061)
* Port `take_offer` to `@marshal`

* `TransactionEndpointRequest` misses
2025-11-06 09:35:24 -07:00
Matt HauffandGitHub 657b637544 [LABS-151] Replace NIL with Program.NIL (#20189)
Replace `NIL` with `Program.NIL`
2025-10-24 11:24:28 -07:00
Matt HauffandGitHub 0a26924688 [CHIA-3606] Port create_offer_for_ids to @marshal (#20056)
* Port `create_offer_for_ids` to `@marshal`

* Self from typing_extensions

* Fix support for "" in PuzzleInfo/Solver
2025-10-21 11:00:37 -07:00
Matt HauffandGitHub 0158ff2783 [CHIA-3605] Port cat_spend to @marshal (#20007)
* Port `cat_spend` to `@marshal`

* fix tests

* test coverage
2025-10-14 15:42:44 -07:00
e947dd14c7 [LABS-244] Remove python 3.9 support (#20099)
* initial changes

* poetry fix

* Address ruff

* Install scripts issues

* Experiment a little bit

* Okay now try for rocky linux and use 3.12 instead

* Remove the now unused thing

* Use dnf for consistency

* Simplify installations

* Still need git

* relock poetry with 2.2.0

* relock poetry with 2.2.0

* try `git checkout main poetry.lock && .penv/bin/poetry lock` on altendky's system

---------

Co-authored-by: Kyle Altendorf <sda@fstab.net>
2025-10-14 07:19:52 -07:00
Matt HauffandGitHub b45f67765f [CHIA-3604] Port easy CAT endpoints to @marshal (#19992)
* Port `spend_clawback_coins` to `@marshal`

* fix tests

* fix test again

* how do I keep missing these?

* Port `select_coins` to `@marshal`

* fix tests

* fix test

* Port `get_spendable_coins`

* Port `get_coin_records_by_names`

* Port `send_notifications` to `@marshal`

* Fixing the thing that is always broken

* Remove accidental import

* Port `get_default_cat_list`

* Port `cat_set_name`

* Port `cat_get_name`

* Port `get_stray_cats`

* Port `cat_get_asset_id`

* Port `cat_asset_id_to_name`

* Port `check_offer_validity`

* Port `get_offers_count`
2025-09-23 12:48:40 -07:00
Matt HauffandGitHub 9d71f283c3 [CHIA-3603] Port send_notifications to @marshal (#19987)
* Port `spend_clawback_coins` to `@marshal`

* fix tests

* fix test again

* how do I keep missing these?

* Port `select_coins` to `@marshal`

* fix tests

* fix test

* Port `get_spendable_coins`

* Port `get_coin_records_by_names`

* Port `send_notifications` to `@marshal`

* Fixing the thing that is always broken

* Remove accidental import
2025-09-19 13:27:03 -07:00
Matt HauffandGitHub 61034b5646 [CHIA-3602] Port wallet coin endpoints to @marshal (#19966)
* Port `spend_clawback_coins` to `@marshal`

* fix tests

* fix test again

* how do I keep missing these?

* Port `select_coins` to `@marshal`

* fix tests

* fix test

* Port `get_spendable_coins`

* Port `get_coin_records_by_names`

* bad port of `include_spent_coins`

* Less bad replace logic

* Actually autofill the CoinSelectionConfigLoader in `get_spendable_coins`

* Comments by @altendky
2025-09-13 11:11:03 -07:00
Matt HauffandGitHub ecb514868f [CHIA-3601] Port spend_clawback_coins to @marshal (#19965)
* Port `spend_clawback_coins` to `@marshal`

* fix tests

* fix test again

* how do I keep missing these?
2025-08-20 12:33:03 -07:00
Matt HauffandGitHub 11696e4b50 [CHIA-3600] Port send_transaction to @marshal (#19960)
* Port `send_transaction`

* Have I mentioned this framework is suboptimal?

* Fix tests
2025-08-19 09:24:36 -07:00
Matt HauffandGitHub 8463909e8f [CHIA-3598] Port easy wallet endpoints to @marshal (#19941)
* Port `get_transaction_count`

* Port `get_next_address`

* Port `delete_unconfirmed_transactions`

* Port `get_current_derivation_index`

* Really disliking this framework FYI

* Port `extend_derivation_index`

* Fix the mock

* Port `delete_notifications`

* Fix the test check

* Store, not RPC

* Port `verify_signature`

* Port `sign_message_by_address`

* Fix tests

* Port `sign_message_by_id`

* fix tests

* fix test

* test coverage

* comments by @altendky
2025-08-18 09:28:21 -07:00
0a0293f81a [CHIA-3297] Port get_transaction(s) to @marshal (#19775)
* Port `get_transaction(s)`

* simplify class

* undo simplification

* Delete __eq__ and add test coverage

* Less dunder access

* small change

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

---------

Co-authored-by: Kyle Altendorf <sda@fstab.net>
2025-08-11 12:34:37 -07:00
Richard KissandGitHub 4e6038ba3b Simplify dependencies wrt chia.server (#19895)
Remove some dependencies in `chia.server`.
2025-08-06 12:03:47 -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
Matt HauffandGitHub e8e060b533 [CHIA-3419] Remove TransactionRecord.*_json_dict_convenience (#19860)
* Change `TransactionRecord` to use dict instead of list of tuples for memos

* Update streamable and fix tests

* Update test to accidentally fixed memos generation

* Remove `TransactionRecord.*_json_dict_convenience`

* Fix test

* Use AddressType library in WSM method

* Use AddressType library in transaction_store method
2025-08-05 13:10:52 -07:00
William AllenandGitHub 148b8137b6 Include plotNFT rewards in get_farmed_amount (#19245)
* Include plotNFT rewards in get_farmed_amount

* Add flag to include pool rewards in farm summary

* Add -i for short flag

* Fix expected args

* Include additional farming detail

* Include additional farming detail

* Format/organize output

* Move block rewards

* Update test

* Format

* Update test_farm_cmd.py

* revert test bool

* Passing tests

* Added test for 'include_pool_rewards=True'

* Address linting errors
2025-08-01 09:16:12 -07:00
Matt HauffandGitHub 55165b1163 [CHIA-3418] Change TransactionRecord to use dict instead of list of tuples for memos (#19846)
* Change `TransactionRecord` to use dict instead of list of tuples for memos

* Update streamable and fix tests

* Update test to accidentally fixed memos generation
2025-07-23 13:17:41 -07:00
Matt HauffandGitHub 018c3fe46e [CHIA-3293] Port get_wallets to @marshal decorator (#19770)
* Port `get_wallets`

* Suggestion by @altendky
2025-07-16 09:07:56 -07:00
13d9d62e41 [CHIA-1311] Port DID RPCs to @marshal decorator (#19708)
* Port `did_set_wallet_name`

* Port `did_get_wallet_name`

* Port `did_update_recovery_ids`

* Port `did_message_spend`

* Port `did_get_info`

* Port `did_find_lost_did`

* fix test

* Port `did_update_metadata`

* Port `did_get_did`

* Port `did_get_recovery_list`

* Port `did_get_metadata`

* Port `did_get_pubkey`

* Port `did_get_information_needed_for_recovery`

* Port `did_get_current_coin_info`

* Port `did_create_backup_file`

* Port `did_transfer_did`

* Add extra_conditions uniformly in CLI tests

* test coverage

* Minor changes.

---------

Co-authored-by: Amine Khaldi <amine.khaldi@reactos.org>
2025-07-08 11:57:58 -05:00
760a65fd0b [CHIA-1313] Port NFT RPCs to @marshal decorator (#19617)
* Port `nft_mint_nft`

* Fix tests

* More test fixes

* Port `nft_count_nfts`

* Port `nft_list_nfts`

* Fix tests

* Port `nft_set_nft_did`

* Fix tests

* Port `nft_set_did_bulk`

* Port `nft_transfer_bulk`

* Port `nft_get_by_did`

* Port `nft_get_wallet_did`

* fix tests

* Fix one more test

* Okay actually fix the test

* Port `nft_get_wallets_with_dids`

* Port `nft_set_nft_status`

* Port `nft_transfer_nft`

* Use kwargs

* Forgot default raise

* Port `nft_get_info`

* Port `nft_add_uri`

* d

* Port `nft_calculate_royalties`

* Fix tests

* Port `nft_mint_bulk`

* Add test coverage for cmd line offering CAT by asset ID

* Add test coverage for a more complex offer take

* Add test coverage for `NFTCalculateRoyalties.__post_init__()

* test coverage generally

* Actually dont commit puzzle hashes when push=False

* Inadvertent test breakage

* Fix tests

* Fix tests

* Fix test

* Fix hopefully one more test

* Comments by @altendky

* small improvement @altendky

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

* small improvement @altendky

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

---------

Co-authored-by: Kyle Altendorf <sda@fstab.net>
2025-06-24 11:04:37 -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
Richard KissandGitHub a803d18c3b The chia.protocols module no longer depends upon chia.server. (#19636)
<!-- Merging Requirements:
- Please give your PR a title that is release-note friendly
- In order to be merged, you must add the most appropriate category
Label (Added, Changed, Fixed) to your PR
-->
<!-- Explain why this is an improvement (Does this add missing
functionality, improve performance, or reduce complexity?) -->

The modules `chia.protocols` and `chia.server` form a dependency loop.
This change at least removes the direct dependency of `chia.protocols`
on `chia.server`.

### Purpose:

<!-- Does this PR introduce a breaking change? -->

### Current Behavior:

### New Behavior:

<!-- As we aim for complete code coverage, please include details
regarding unit, and regression tests -->

### Testing Notes:

<!-- Attach any visual examples, or supporting evidence (attach any
.gif/video/console output below) -->
2025-05-29 09:24:29 -07:00
Kyle AltendorfandGitHub a90f04ff48 move chia.types.aliases to chia.server.aliases (#19535)
* move `chia.types.aliases` to `chia.server.aliases`

* touchup
2025-04-25 13:15:04 -05:00
Earle LoweandGitHub a1e695e896 Allow DIDs from other wallets with NIL recovery lists (#19469)
* Somewhat hacky workaounds for DIDs from other wallets

* cannot use set as not hashable

* Add a couple tests

* Change DIDCoinData to use bytes instead of bytes32

* Remove some unused code

* Remove some more unused code

* Make the alternate recovery did spendable I think

* Use Optional[bytes32] for DIDCoinData to show the list should be 32 bytes or nothing (where nothing is the NIL program)

* Replace specific test with parameterization of other tests to get more testing of the Alternate DIDs

* Empty commit for github

* minor formatting change

* No need to cast to bytes since as_atom returns bytes
2025-04-23 09:28:48 -05:00
Kyle AltendorfandGitHub fcd20ce543 more chia_rs directly (#19520)
* more `chia_rs` directly

* maybe

* undo, kinda
2025-04-21 14:05:05 -05:00
Kyle AltendorfandGitHub 1911044e97 use chia_rs directly for more types (#19475)
* use chia_rs directly for more types

* more more

* undo submodule change...
2025-04-18 11:45:44 -05:00
Kyle AltendorfandGitHub 26fcbe70e6 subdirectory for chia dev commands (#19418)
* move `chia dev` to its own subdirectory

* rename `dev.py` to `main.py`

* fixup

* more
2025-03-21 14:31:13 -07:00
Kyle AltendorfandGitHub d50b6e0883 use chia_rs directly for sized bytes (#19326) 2025-02-28 09:35:25 -08:00
dependabot[bot]GitHubdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>Kyle Altendorf
bc99c7a283 build(deps): bump mypy from 1.14.1 to 1.15.0 (#19319)
* build(deps): bump mypy from 1.14.1 to 1.15.0

Bumps [mypy](https://github.com/python/mypy) from 1.14.1 to 1.15.0.
- [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md)
- [Commits](https://github.com/python/mypy/compare/v1.14.1...v1.15.0)

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

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

* adjust accordingly

* remove another

* and windows

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Kyle Altendorf <sda@fstab.net>
2025-02-28 09:32:34 -08:00
dependabot[bot]GitHubdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>Earle LoweEarle LoweKyle Altendorf
d7e2358a32 build(deps): bump ruff from 0.8.5 to 0.9.6 (#19260)
* build(deps): bump ruff from 0.8.5 to 0.9.6

Bumps [ruff](https://github.com/astral-sh/ruff) from 0.8.5 to 0.9.6.
- [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.8.5...0.9.6)

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

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

* Update source to ruff 0.9.6

* Apply suggestions from code review

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

---------

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>
Co-authored-by: Earle Lowe <30607889+emlowe@users.noreply.github.com>
Co-authored-by: Kyle Altendorf <sda@fstab.net>
2025-02-27 09:53:34 -08:00
Kyle AltendorfandGitHub fb6b78ef07 use chia_rs directly for foliage (#19308) 2025-02-25 11:33: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
Matt HauffandGitHub ccfa35cab8 [CHIA-2369] Legacy-ify DAOs (#19266)
Legacy-ify DAOs
2025-02-20 11:05:30 -07:00
Kyle AltendorfandGitHub b6b4ea1c73 add chia dev gh test for launching configured test runs (#18922)
* add chia dev gh test for launching configured test runs

* empty again

* better

* use the actual authenticated username

* more output

* helpful errors for invalid --only value

* tidy short help

* add at least an invalid --only test case

* prepare a long help

* add gh api runner helper

* use the commit hash for the temporary branch

* and uuid too

* fix up os selection

* add `--remote`

* load a url for a specified `--ref` as well

* both helps

* show defaults in `--help`

* help touchup

* Revert "show defaults in `--help`"

This reverts commit 5d7f4868e0.

* r

* add an actual dispatch test skeleton

* do not conflict check `tmp/**`

* assert a bit more about the resulting run

* oops

* skip the test for now

* pre-commit
2024-12-19 11:32:56 -07:00
Kyle AltendorfandGitHub 9a0b5728c5 use a class for the chia cli context data (#18919)
* use a class for the chia cli context data

* actually assign to the context properly...

* handle the not-present case

* catch up

* tidy

* more

* stuff

* ...

* more real

* expected address prefix
2024-12-19 10:44:48 -07: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
Kyle AltendorfandGitHub 9c60a48de3 less DEFAULT_ROOT_PATH for get_any_service_client() (#19049) 2024-12-17 10:27:41 -07:00
Kyle AltendorfandGitHub 78afe07f28 first pass at using @chia_command without a group (#19040)
* first pass at using `@chia_command` without a group

* less slots
2024-12-13 11:49:16 -07:00