Area
Project Registry / State Machine
Complexity
Medium-hard
File(s)
project_registry/src/types.rs:106-115 (ProjectStatus), project_registry/src/lib.rs:205 (only assignment besides Archived at :234)
Problem
ProjectStatus defines five variants (Pending, Active, Funded, Completed, Archived), but grepping all of lib.rs for ProjectStatus:: shows exactly two writes: Pending at creation and Archived in archive_project. No function in this contract (nor any cross-contract call from the vault) ever sets Active, Funded, or Completed. Every project that isn't explicitly archived stays Pending forever, even after being fully funded and repaid. Any off-chain indexer or downstream logic branching on these three variants is dead code path that can never trigger.
Scope
In:
- Either wire a real transition (e.g. an admin/vault-callable set_project_status, or an implicit transition inside deposit_collateral/vault funding), or clarify in types.rs/API.md that these variants are reserved/vault-managed and currently unset by this contract.
Out:
- Implementing the vault-side funding-status cross-contract call (separate, larger piece of work — flag as a dependency).
Acceptance Criteria
Area
Project Registry / State Machine
Complexity
Medium-hard
File(s)
project_registry/src/types.rs:106-115 (ProjectStatus), project_registry/src/lib.rs:205 (only assignment besides Archived at :234)
Problem
ProjectStatus defines five variants (Pending, Active, Funded, Completed, Archived), but grepping all of lib.rs for ProjectStatus:: shows exactly two writes: Pending at creation and Archived in archive_project. No function in this contract (nor any cross-contract call from the vault) ever sets Active, Funded, or Completed. Every project that isn't explicitly archived stays Pending forever, even after being fully funded and repaid. Any off-chain indexer or downstream logic branching on these three variants is dead code path that can never trigger.
Scope
In:
Out:
Acceptance Criteria