Arnaud 7065718e09
feat(marketplace): indicate that slot is being repaired when trying to download (#1083)
* Indicate that slot is being repaired when trying to download

* Fix tests

* Apply nph

* Calculate the repair collateral when adding the item into the queue

* Add slotCollateral calculation with getRequest cache and remove populationItem function

* Update with pricePerByte

* Simplify StorageAsk parameter

* Minor fixes

* Move cache request to another PR

* Rename SlotQueueItem collateral and required in init

* Use override func to optimise calls when the slot state is known

* Remove unused code

* Cosmetic change

* Use raiseMarketError helper

* Add exceptions to async pragma

* Cosmetic change

* Use raiseMarketError helper

* Let slotCollateral determines the slot sate

* Use configSync to avoid async pragma in onStorageRequested

* Add loadConfig function

* Add CatchableError to async pragma

* Add missing pragma raises errors

* Move loadConfig

* Avoid swallow CancelledError

* Avoid swallowing CancelledError

* Avoid swallowing CancelledError

* Update error messages

* Except MarketError instead of CatchableError

* Fix merge issue

* Log fatal when configuration cannot be loaded

* Propagate MarketError in slotCollateral

* Remove useless configSync

* Use result with explicit error

* Fix syntax

---------

Signed-off-by: Arnaud <arnaud@status.im>
2025-02-27 16:58:23 +00:00
..
2022-01-10 09:32:56 -06:00
2025-01-21 20:54:46 +00:00
2025-01-21 20:54:46 +00:00
2024-01-29 17:03:51 -03:00
2025-01-21 20:54:46 +00:00
2025-01-21 20:54:46 +00:00
2025-01-21 20:54:46 +00:00
2025-01-21 20:54:46 +00:00
2025-01-21 20:54:46 +00:00
2024-05-30 06:57:10 +00:00
2025-01-21 20:54:46 +00:00
2023-08-01 16:47:57 -07:00
2025-01-24 17:18:00 +00:00
2025-01-21 20:54:46 +00:00