Skip to content

Add descriptive revert reasons to DataEscrowV3 contract #27

@crtahlin

Description

@crtahlin

Description

Contract reverts with empty data instead of helpful error messages, making debugging very difficult.

Current Behavior

Error: execution reverted (no data present; likely require(false) occurred)
Error data: 0x

Expected Behavior

Descriptive revert reasons like:

  • "Seller not registered as agent"
  • "Invalid expiry: must be 1-365 days"
  • "Amount below minimum threshold"
  • "Content hash cannot be zero"
  • "Key commitment cannot be zero"

Impact

  • Developers waste time guessing what validation failed
  • Support burden increases
  • Integration testing is painful

Suggested Implementation

Replace:

require(someCondition);

With:

require(someCondition, "Descriptive error message");

Found during seller flow UX testing - contract rejected call with no explanation

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions