Commit Graph

8 Commits

Author SHA1 Message Date
Eric 33010bd20c
feat(slot-reservations): Allow slots to be reserved (#177)
* feat(slot-reservations): Allow slots to be reserved

Closes #175.

Allows reservation of slots, without an implementation of the expanding window.

- Add a function called `reserveSlot(address, SlotId)`, that allows three unique addresses per slot to be reserved, that returns bool if successful.
       - Use `mapping(SlotId => EnumerableSet.AddressSet)`
       - Return false if the address could not be added to the set (if `EnumerableSet.add` returns false)
- Add `canReserveSlot(address, SlotId)`
        - Return `true` if set of reservations is less than 3 and the set doesn't already contain the address
        - Return `true` otherwise (for now, later add in logic for checking the address is inside the expanding window)
        - Call `canReserveSlot` from `reserveSlot` as a `require` or invariant
- Add `SlotReservations` configuration struct to the network-level config, with `maxReservations`
2024-10-03 11:01:21 +10:00
Eric ed428767b3
chore: add `downtimeProduct` configuration parameter (#138)
* add `downtimeProduct` configuration parameter

* formatting
2024-08-14 15:50:32 +10:00
r4bbit 688a8ed929
Set up certora and implement first rules (#122)
Co-authored-by: 0xb337r007 <0xe4e5@proton.me>
Co-authored-by: Adam Uhlíř <adam@uhlir.dev>
2024-07-24 18:50:18 +02:00
Mark Spanbroek 6c9f797f40 Explicit getters for token and config
Implicit getters have slightly different semantics when
it comes to ABI encoding their results.
2024-02-06 12:27:40 +01:00
Adam Uhlíř 331bc56e8f
feat: zkey hash in marketplace config (#81) 2024-01-30 06:36:27 +01:00
Mark Spanbroek db124ddbd9 Re-arrange marketplace constructor parameters
first configuration, then contracts that we depend on
2024-01-25 13:08:10 +01:00
Adam Uhlíř 0d9b67bb31 feat: verifier integration 2024-01-25 13:08:10 +01:00
Mark Spanbroek 3390e21071 [fuzzing] Enable fuzzing for Marketplace
Replaces runtime invariant checks with fuzzing tests,
simplifying the contract code and lowering gas costs.
2023-06-19 14:58:47 +02:00