Skip to content

fix(escrow): require delivery before receipt confirmation#236

Open
kongwen686 wants to merge 1 commit into
Cylo-Traders:mainfrom
kongwen686:fix/delivered-before-confirm
Open

fix(escrow): require delivery before receipt confirmation#236
kongwen686 wants to merge 1 commit into
Cylo-Traders:mainfrom
kongwen686:fix/delivered-before-confirm

Conversation

@kongwen686
Copy link
Copy Markdown

Summary

  • add a Delivered order status and set it when farmers call mark_delivered
  • require orders to be delivered before confirm_receipt can complete payment
  • update escrow tests so confirmation happens only after delivery and undelivered confirmation returns OrderNotDelivered
  • assert the exact error for repeated delivery marking

Closes #233

Tests

  • Not run locally (cargo is not installed in this environment).
  • Verified the remote diff to confirm all direct receipt confirmations in the escrow tests now pass through mark_delivered first.

Payment / contact

  • Email: chaoqiang.tian@gmail.com
  • EVM: 0x225b4bC64E051827c069312f82fA590Ec9632209
  • Stellar: GDYPL56JCCHD75ZB2I5Z4FT4WEWZFRD24LEC62XQ2MBL34653XKO65LA
  • RTC/ClawRTC: RTC02d8536941d636aee4012596afbcd8185e9f8283
  • Alipay: chaoqiang457963@126.com

@kongwen686
Copy link
Copy Markdown
Author

Payment update: Stripe onboarding is not available for me from mainland China. If this contribution is approved for a reward, can payout be sent via PayPal instead? PayPal receiving account: hooqee@126.com. Contact email: chaoqiang.tian@gmail.com. If PayPal is not supported, Stellar/EVM/Alipay details are available on request / in the PR body.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Contract] Test: Fix invalid post-delivery state assertion in escrow test

1 participant