-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chia|tests: Introduce
PlotManager
+ some plot loading improvements …
…and fixes (#7848) * harvester|plotting|tests: Introduce `PlotManager` class This moves all plots related and plot-directory related stuff from the harvester into the class `PlotManager`, adjusts all related code accordingly and adds some extra wrappers there. * harvester|plotting|tests: Return how many new plots were loaded * plotting: Fix `failed_to_open_filenames` re-try interval With `< 1200` it just tries it on the next refresh. * plotting: Fix and improve duplicates handling * harvester|plotting: Thread locks for `PlotManager.plots` * chia|tests: Load plots in batches * chia|tests: Move plot refreshing into a separate thread * plotting: Properly handle removed plots And fix tests accordingly. It seems like this fix Chia-Network/chia-blockchain#3350 wasn't really a fix, rather adjusting to allow for a bug? * plotting|harvester|tests: Introduce `PlotRefreshResult` * tests: Expand `test_farmer_harvester_rpc.py` * chia|tests: Move some stuff from `plot_tools.py` into new file `util.py` * refactor: Rename `plot_tools.py` to `manager.py` * chia|tests: Use pure dataclass for `PlotsRefreshParameter` With `uint16` as type saving to config doesn't work, this is a preparation for the next commit. * harvester: Adjust deprecation message, use `info` instead of `warning` * plotting: Fix typo * refactor: Rename `filename` to `file_path` Fits better and does avoid shadowing with filename from outer scope. * chia|tests: Move some methods from `plotting.manager` to `plotting.util` * plotting: Make `refresh_callback` mandatory (cherry picked from commit 53149f2e57743e203aba1d25a89786edcf1f78ab)
- Loading branch information
1 parent
8e4ca5f
commit 4dd09ba
Showing
11 changed files
with
900 additions
and
246 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.