Currently, if the daemon doesn't send `initial_target_state` for
new pool_wallets, it will cause a `KeyError`.
This commit makes it give a more informative error, so less users
are confused by this.
Signed-off-by: wallentx <william.allentx@gmail.com>
Signed-off-by: wallentx <william.allentx@gmail.com>
Co-authored-by: bolshoytoster <toasterbig@gmail.com.com>
* No traceback for OSError 113 in WSChiaConnection.outbound_handler()
```python-traceback
Aug 16 21:24:08 fullnode chia_full_node[58416]: 2022-08-16T21:24:08.489 full_node full_node_server : ERROR Exception: [Errno 113] No route to host with 121.236.62.254
Aug 16 21:24:08 fullnode chia_full_node[58416]: 2022-08-16T21:24:08.490 full_node full_node_server : ERROR Exception Stack: Traceback (most recent call last):
Aug 16 21:24:08 fullnode chia_full_node[58416]: File "/farm/chia-blockchain/chia/server/ws_connection.py", line 262, in outbound_handler
Aug 16 21:24:08 fullnode chia_full_node[58416]: await self._send_message(msg)
Aug 16 21:24:08 fullnode chia_full_node[58416]: File "/farm/chia-blockchain/chia/server/ws_connection.py", line 416, in _send_message
Aug 16 21:24:08 fullnode chia_full_node[58416]: await self.ws.send_bytes(encoded)
Aug 16 21:24:08 fullnode chia_full_node[58416]: File "/farm/chia-blockchain/venv/lib/python3.8/site-packages/aiohttp/web_ws.py", line 315, in send_bytes
Aug 16 21:24:08 fullnode chia_full_node[58416]: await self._writer.send(data, binary=True, compress=compress)
Aug 16 21:24:08 fullnode chia_full_node[58416]: File "/farm/chia-blockchain/venv/lib/python3.8/site-packages/aiohttp/http_websocket.py", line 688, in send
Aug 16 21:24:08 fullnode chia_full_node[58416]: await self._send_frame(message, WSMsgType.BINARY, compress)
Aug 16 21:24:08 fullnode chia_full_node[58416]: File "/farm/chia-blockchain/venv/lib/python3.8/site-packages/aiohttp/http_websocket.py", line 659, in _send_frame
Aug 16 21:24:08 fullnode chia_full_node[58416]: await self.protocol._drain_helper()
Aug 16 21:24:08 fullnode chia_full_node[58416]: File "/farm/chia-blockchain/venv/lib/python3.8/site-packages/aiohttp/base_protocol.py", line 87, in _drain_helper
Aug 16 21:24:08 fullnode chia_full_node[58416]: await asyncio.shield(waiter)
Aug 16 21:24:08 fullnode chia_full_node[58416]: File "/usr/lib/python3.8/asyncio/selector_events.py", line 848, in _read_ready__data_received
Aug 16 21:24:08 fullnode chia_full_node[58416]: data = self._sock.recv(self.max_size)
Aug 16 21:24:08 fullnode chia_full_node[58416]: OSError: [Errno 113] No route to host
Aug 16 21:24:08 fullnode chia_full_node[58416]:
```
* Update ws_connection.py
* refactor
* Change the pattern for running pre-commit. Previously, this was using a deprecated action workflow.
* Fix the python version for the - uses: ./.github/actions/install step
* Added --all-files and --verbose to the pre-commit run command
* Precommit is already installed as part of the dev dependencies. Removing the installation step.
* Drop `use_passphrase_cache` parameter, its always `True`
* Drop `unlocks_keyring` calls in `Keychain`
* Change `unlocks_keyring` to `unlock_keyring` and drop the decorator fun
* Move `obtain_current_passphrase` and `unlock_keyring` into `chia.cmds`