Update `Marketplace.state` getter to to take `isCancelled` into account. This state can then be used internally and externally.
Add checks to `proofEnd`, `isProofRequired`, `willProofBeRequired`, and `getChallenge` that understands if the request is in a state to accept proofs. If not, return other values.
Add `slotMustAcceptProofs` modifier, originally introduced in a later PR, which requires the request to be in state of the request accepting proofs.
Add tests for all the above.
- Remove `FundsWithdrawn` event
- do not copy request to memory
- todo for changing withdraw amount to not include proof payments
- test lock expiry border
- in tests, move `RequestState` to exported const in marketplace.js
- move test for state checks on `fillSlot` to the “filling a slot” section.
Add cancelled check for slot state which checks the contract state and also the slot expiry time. This handles the case where the client may not have withdrawn funds yet (which sets the contract state to Cancelled).
Add tests for contract state.
Adds ability for client to withdraw funds from a cancelled storage request.
Tests to check if request has timed out, if the client address is requesting withdraw, if the request state is new, and the funds were successfully transferred.