* server: Enable and fix `mypy` in `server.py`
* Add a comment about the `Message` hint
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Tweak assert message
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Make `name` non-optional
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Properly reject incoming connections to crawlers
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Hint `StreamResponse` and return the existing `WebSocketResonse`
* Raise if `remote` is `None`
* Restore old behaviour: succeed, don't fail for self connection
* Raise `HTTPInternalServerError` if `remote` is `None`
* Cast config values to `int`
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* remove all references to RL wallet
* Missed one
* Some new references from main
* Fix is_transaction_confirmed
* mypy
* check for 'confirmed'
* Try again to fix is_transaction_confirmed
* remove from mypy.ini
* Remove mempool.additions
* Don't re run the program, and remove program from mempool item
* Removals only stores item ids, and stores a list
* Move pending cache down to prevent cache dos
* Separate validation from adding to pool, and remove mypy exceptions
* Fix bug with replacing
* Add to mypy
* Revert cbgui
* precommit fail
* Properly update the seen dict
* lint error
* Fix mempool bug
* Enable mypy for a bunch of files
* Update after merge with main
* 99/260 remaining
* Address comments
* Enable more mypy
* Merge conflict mypy file
* More fixes
* pytest.ini and cb-gui
* One more flake8 fix
* Flake8 and tests
* More test fixes
* isort
* Make LGTM happy
* Update chia/full_node/block_store.py
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Update chia/full_node/full_node_store.py
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Update chia/wallet/util/peer_request_cache.py
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Apply all suggestions from PR comments
* Revert cb-gui
* 100 back to 1000, minor tweaks
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Remove mempool.additions
* Don't re run the program, and remove program from mempool item
* Removals only stores item ids, and stores a list
* Move pending cache down to prevent cache dos
* Separate validation from adding to pool, and remove mypy exceptions
* Fix bug with replacing
* Add to mypy
* Revert cbgui
* precommit fail
* Properly update the seen dict
* lint error
* Fix mempool bug
* Update after merge with main
* Address comments
* use bytearray to build a binary blob, convert it to bytes once it's done
* load the bootstrap generator rom in binary form directly, avoid conversions
* Add proper types to daemon client & keychain
* pre type pass on keychain proxy
* add auto restarting keychain proxy
* finalize keychain proxy v2
* move event calls
* fix close on timeout
* fix possible key leak in logging
* fix last little error
* log on disconnection & reduce duplicate code
* Update client.py
* create new test.simulator module
to allow other packages to use the simulator without it crashing.
also tiny QOL fixes
* change user mode sim plot filter
Now only plots matching the user set fingerprint are loaded, this decreases the chance of user error.
* fix small oops in configure
* oops
* fix lint
* isort, who dis
* move folder over to chia/simulator
also change mypy settings again
* Hint and lightly refactor chia.server.upnp.UPnP
* Remove chia.server.upnp from mypy.ini lax rules
* black
* Revert the pointless int for shutdown
* isort
* from __future__ import annotations
* rename test files that are missing test_ prefix
* update mypy and isort excludes
* skip test_get_host_addr6() in GitHub Actions under macOS
* rebuild workflows
* simplify SizedBytes and StructStream
* lint
* super() !!!
* do not pass parameter up to super().__init__()
* Update chia/util/struct_stream.py
Co-authored-by: Arvid Norberg <arvid@libtorrent.org>
* parse fixed-width int data from class name
* add int512 and uint128 .from_bytes(), test .parse() failures
* test serialization against struct.pack()
* use typing_extensions for final
* override ignore
* stop using struct for StructStream
oh the irony
* fixup .to_bytes() to accept parameters again for where we use that
* bring back signed parameter
* format
* adjust tests for new exception
* eliminate custom coding for uint128 and int512
* tidy
* remove unused StructStream.PACK attribute
* add direct tests for parse_metadata_from_name()
* stricter hinting
* remove no-longer-needed typeshed work-around
* apply strict type checking to all touched files
* remove StructStream override of .to_bytes()
* tidy
* types touchup
* add unused parameter comments
Co-authored-by: Arvid Norberg <arvid@libtorrent.org>
Co-authored-by: wjblanke <wjb98672@gmail.com>
* Mypy for consensus dir (Except blockchain.py)
* Finish up consensus folder mypy
* Lint
* isort
* lint
* awaitable over coroutine
* less Any
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* isort: Fix `streamable.py` and `test_streamable.py`
* mypy: Drop `streamable.py` and `test_streamable.py` form exclusion
And fix all the mypy issues.
* Fix `pylint`
* Introduce `ParseFunctionType` and `StreamFunctionType`
* Use `object` instead of `Type[Any]` for `is_type_*` functions
* Some `Any` -> `object`
* Use `typing.overload` for `recurse_jsonify`
* Move some comments
* Drop `Union`, use `Literal` properly
* Explicitly ignore the return of `f_type.parse`
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Merge two `recurse_jsonify` overloads
* Typing for the base definition of `recurse_jsonify`
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* Merged with main (9ff3fc993f)
* Linter and some test fixes
* isort, linting, test fix
* Fixes and bumped the GUI to point to nftdev
* Couple of fixes
* streamable: Merge `strictdataclass` into `Streamable` class
* tests: Test not supported streamable types
* streamable: Reorder decorators
* streamable: Simplify streamable decorator and force correct usage/syntax
* streamable: Just move some stuff around in the file
* streamable: Improve syntax error messages
* mypy: Drop `type_checking.py` and `test_type_checking.py` from exclusion
* streamable: Use cached fields instead of `__annotations__`
This is now possible after merging `__post_init__` into `Streamable`
* Introduce `DefinitionError` as `StreamableError`
* `/t` -> ` `
* Remove unused test code
* Centralize fixture uses of setup_n_nodes
* Centralize fixure uses of setup_two_nodes
* Break up setup_nodes into setup_services, for individial services, and setup_nodes, for initializing different simulator configurations
* Sort imports
* Remove old backup stuff
* Remove references to CC (couloured coins) which is deprecated terminology
* removed no longer used import
Co-authored-by: Kyle Altendorf <sda@fstab.net>
* just put __init__.py files where we have .py files
* and the rest
* remove unused ignore
* update mypy ignore list
* remove chia.util.clvm pass-through file
* import ConsensusConstants from actual definition
* in tests too
* import ConditionOpcode from actual definition
* a little less ignore
* update mypy reduced-strictness set
* update mypy reduced-strictness set
* New chiapos API
* Fix flake
* Move to chiapos 0.12.30 to fix segfaults
* Black
* change stripe size to 2000
* chiavdf to 0.12.25
* Revert "chiavdf to 0.12.25"
This reverts commit f7f596ce16.
chiavdf has a timelord compile error on MacOS.
* Increase default -b
* Plotter GUI test
Co-authored-by: Gene Hoffman <hoffmang@hoffmang.com>
Co-authored-by: Yostra <straya@chia.net>