Dispute Module
Arbitration and conflict resolution.
Created: 1/9/2026
Dispute Module (dispute_module)
The dispute_module provides a safety net for contracts. It allows an authorized third party (the Arbiter) to intervene when the Poster and Worker cannot reach an agreement.
Roles
- Arbiter: The address authorized to resolve disputes. Initially set to the contract deployer, but can be reassigned.
Flows
Arbiter Management
By default, the deployer is assigned as the Arbiter. However, this authority can be transferred to another address (e.g., a specific admin account or DAO) using the assign_new_arbiter function.
This ensures that the arbitration responsibility can be decoupled from the technical deployment of the contracts.
1. Initiation
- Trigger: Called by either the Poster or Worker involved in a
gig_contract. - Effect:
- Checks that the caller is a party to the gig.
- Calls
gig_contract::set_disputedto freeze the gig state, preventing further actions like normal completion.
2. Resolution
- Trigger: Called by the Arbiter.
- Inputs:
gig_addr,favor_poster(bool),split_ratio(u64). - Logic:
- Favor Poster: Full refund of the budget to the poster.
- Favor Worker: Full payout of the budget to the worker.
- Split: Distributes funds based on the ratio (e.g., 50% to worker, 50% to poster) for partial work done.
- Finally, marks the gig as
Closed.
