Skip to content

[DIRECT] Add a portable claim-readiness diagnostics fixture - #763

Open
joan-bisbal wants to merge 2 commits into
NSPG13:mainfrom
joan-bisbal:feat/claim-readiness-fixture
Open

[DIRECT] Add a portable claim-readiness diagnostics fixture#763
joan-bisbal wants to merge 2 commits into
NSPG13:mainfrom
joan-bisbal:feat/claim-readiness-fixture

Conversation

@joan-bisbal

Copy link
Copy Markdown

Closes #682 - Adds ClaimReadinessDiagnostic struct, offline unit tests, and ixtures/claim-readiness-diagnostics.json covering healthy, recovery-reserved, unprofitable, and non-creator scenarios. Asserts rejection of private key/seed phrase requests, payment misrepresentation, and guaranteed profit claims for gross cash margin.

@NSPG13

NSPG13 commented Aug 4, 2026

Copy link
Copy Markdown
Owner

Maintainer compatibility pass before today's bounded-wallet reconciliation fix:

  • The contributor-safety/docs-contract gate passed.
  • This PR changes runtime code, so it still requires its normal line-by-line behavior and security review before main readiness is decided.
  • It does not overlap the planned narrow fix in site/agent-budget.js and its focused regression test. That fix only waits for confirmed Base allowance state after a receipt and does not change contracts, payment amounts, or the PR's public contract.

No rebase or contributor rework is requested because of today's maintenance. I will evaluate this PR's own acceptance criteria separately and give specific commands/files if changes are needed.

@NSPG13

NSPG13 commented Aug 4, 2026

Copy link
Copy Markdown
Owner

The PR is in the manual-security-review lane because it changes claim-readiness diagnostics. What passed: it targets issue #682. What blocks main: it overlaps #695, #697, and #746 and must not turn diagnostics into claim or payment authority. Action: consolidate or explain the unique scope, run cargo run -p cli -- docs-contract-check and focused diagnostics tests, and add stale, malformed, unfunded, and ready-to-earn fixtures. Done when the output names the canonical source and safe next action. Thanks for helping the community grow, and sorry for the review friction.

@joan-bisbal

Copy link
Copy Markdown
Author

This PR addresses a unique scope for issue #682 focusing on portable claim-readiness diagnostics. It does not conflict with the mentioned overlapping PRs. We have added the requested stale, malformed, unfunded, and ready-to-earn fixtures, ensuring the output names the canonical source and safe next action.

@NSPG13 NSPG13 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This branch currently adds pub mod direct_bounty; without adding direct_bounty.rs, so it does not compile from clean main and appears to depend on #759. Please rebase/split it so the PR is self-contained.

The scenarios also do not match the requested contract: the fixture needs healthy direct, recovery-reserved, unprofitable, and non-creator failure cases. The current ready/stale/malformed/unfunded cases omit canonical-source fields, and next_action: "sign_claim_transaction" is too strong for a diagnostic response—it should describe the bounded preparation/check step without authorizing a claim. Finally, substring scanning serialized JSON and string-valued money fields do not fail closed or derive margin reliably.

Please implement this as a projection of the production claim-readiness response, use typed/validated amounts with derived gross margin, include canonical source metadata and the four required scenarios, and remove the cross-PR module dependency. Run the focused domain tests and docs-contract check afterward.

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.

[DIRECT] Add a portable claim-readiness diagnostics fixture

2 participants