* Cleanup seeder & mypy all files
holy crap mother of all tech debt this was horrid
* Make UDP Protocol class a dataclass & separate out functions.
* add TCP protocol class to DNS server
* Fix mypy types & other cleanup
also fix a couple bugs
* Add seeder and crawler tests
* change log levels
* re add db lock timeout
oops
* add edns & edns tests
* fix repeated shutdown on close signal
* fix binding to use both ipv6 and ipv4
whyyyyyyy
* add ipv6 and ipv4 tests + add ipv4 if windows
* New aggregate signature conditions.
* compute domain strings on the fly (but cache them) (#2)
* Addendum to Arvid's idea.
* Fix a typo.
* more test coverage (#3)
* Fix a typo.
* Refactor final message creation logic into make_aggsig_final_message.
* Cover make_aggsig_final_message exception cases.
* Refactor processing spends' agg sig lists in pkm_pairs.
* Construct a Coin out of a Spend and use it in make_aggsig_final_message.
* Adopt Richard's dictionary trick to simplify make_aggsig_final_message.
* Leverage make_aggsig_final_message in WalletTool's sign_transaction.
---------
Co-authored-by: Arvid Norberg <arvid.norberg@gmail.com>
* use solution_generator() from rust
* farm blocks with backrefs
* update BlockTools to generate block generators serialized with backrefs
* support deserializing programs with backrefs
* Renaming instances of 'decompresser' to 'decompressor'
* Making 'parallel_decompressors_count' singular
* Using chiapos version that has matching spelling
* Putting the clsp file back where I found it
* fix ver
---------
Co-authored-by: Jack Nelson <j.nelson@chia.net>
* update passed_plot_filter() to take the filter size rather than consensus constants. This allows the filter size to change by block height. make verify_and_get_quality_string() take either the height or filter size
* Add some filter_prefix_bits tests on test blocks.
* Add some filter_prefix_bits tests on simulated farmer and harvester.
* Cache filter prefix bits by challenge chain signage point hash and use that for the the lookups. This allows us to perform plot filter validation.
* Add more cases to verify_and_get_quality_string() unit tests.
* Add some tests for Farmer's respond_signatures.
* Apply Kevin's suggestion to simplify the check for passing plot filter.
* Apply Kevin's suggestions to simplify some test checks and fix a couple typos.
* Apply Kevin's suggestion to send peak height instead of filter prefix bits as part of NewSignagePoint.
* Remove no longer needed filter prefix bit related logic and make height non optional in verify_and_get_quality_string().
---------
Co-authored-by: Amine Khaldi <amine.khaldi@reactos.org>
* add HARD_FORK_2_0 consensus_mode to run tests under hard-fork consensus rules
* hook up soft-fork and hard-fork changes in CLVM
* fix AGG_SIG_* garbage tests for the 2.0 hard-fork
* add test for unknown conditions with cost, which is a hard-fork feature
* add mempool tests for unknown conditions with cost
* add tests for the SOFTFORK condition
* fix benchmark to take LIMIT_ANNOUNCES into account
* server: Introduce `ApiProtocol`
* genericize (#5)
* `ApiProtocol.api_ready` -> `ApiProtocol.ready()`
* Add `ApiProtocol.log` and give APIs separate loggers
* Fix `CrawlerAPI`
* Drop some unrelated removals
* Fix some of the generic hinting
* Revert some changes in `timelord_api.py`
* Fix `CawlerAPI` readiness
* Fix hinting
* Get some `CrawlerAPI` coverage
---------
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* explore a simplification of the blockchain priority lock queue
* add some tests
* correct task tracking
* use time.perf_counter for better resolution on windows
* just count an integer for request order retention
* stop using time in the (new) tests as well
* add tests and a couple no covers
* less existing test refactoring
* use a sync PriorityQueue
* switch to deques
* address bugs and simplify priority to deque mapping
* remove unused attribute ._priority_type
* make LockQueu.create() not async
* explain the active element check on wait cancellation
* drop LockQueue._process()
* import final from typing_extensions
* rename LockQueue to PriorityMutex
* remove test from mypy exclusions
* clean up straggling lock references
* ignore test failure case line coverage
* add a monkeypatch test ;[
* remove queued callback feature
* remove todos
make sure tests that use BlockTools use a single source of consensus constants. This is in preparations for being able to run tests with different sets of constants, e.g. the hard-fork constants
* remove unused run_generator_mempool() function
* move run_generator_unsafe() into the tests, which is the only place it's used
* remove (somewhat meaningless) setup_generator_args() and create_generator_args()
* remove unused GENERATOR_MOD in mempool_check_conditions.py
* remove redundant get_generator() function
* transition analyze-chain.py to use run_block_generator() and drop dependency on GENERATOR_MOD
* fixup type hints in test_rom.py
* fixup type hints in test_compression.py
* fixup type hints in test_generator_types.py
* full_node: Rename `FullNode.resond_block` to `FullNode.add_bock`
The naming `respond_block` is confusing here imo, we have a full node
API method called `respond_block` but here in the `FullNode` class this
method is there to try adding a block to the full nodes's chain so i
think `add_block` is the better choice?
Also change the `respond_block: full_node_protocol.RespondBlock`
parameter to `block: FullBlock` which lets us get rid of many
`full_node_protocol.RespondBlock` wrappings.
* `FullNode.receive_block_batch` -> `FullNode.add_block_batch`
* `receive_unfinished_block` -> `add_unfinished_block` + change parameter
* `FullNode.respond_transaction` -> `FullNode.add_transaction`
* `FullNode.respond_end_of_sub_slot` -> `FullNode.add_end_of_sub_slot`
* `FullNode.respond_compact_vdf` -> `FullNode.add_compact_vdf`
* `respond_compact_proof_of_time` -> `add_compact_proof_of_time`
* `respond_transaction_semaphore` -> `add_transaction_semaphore`
* fix test asserts to not require the same object, just the same value
* make Mempool's implementation private and give it a public interface
* fixup test that used to count fee *levels* but now count transactions
* Drop redundant fixtures in `test_dl_wallet.py`
* Drop `two_wallet_nodes_five_freeze`
Maybe im just not getting it but the `five_freeze` doesn't sound right
here to me and the fixture does the same as `two_wallet_nodes` so i
guess we can just drop it?
* Drop `wallet_and_node` fixture
* Drop both `wallet_node` fixtures
The one in `conftest.py` and the one in `test_dl_wallet.py`.
* Drop both `wallet_node` fixtures
The one in `conftest.py` and the one in `test_dl_wallet.py`.
* Drop `wallet_node_sim_and_wallet` fixture
* Drop `wallet_node_simulator` fixture
* Drop `one_wallet_node` fixture
* preliminary test_pool_rpc refactor
* remove todo
* handle some todos
* one more
* wait for wallets to sync in the fixtures
* drop an extra wallet
* drop unused function
We create new configs in `setup_farmer` and `setup_harvester` and they
contain `localhost` defaults. Replace it here also like we do it in
`BlockTools` to consistently use `127.0.0.1` instead of `localhost` in
tests.