Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle v2 error #474

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Handle v2 error #474

wants to merge 2 commits into from

Conversation

DanGould
Copy link
Contributor

Fix #468 with a simple approach: Just add the methods to UncheckedProposal which can be cloned at the beginning of the receive process.

This seems to be is the least invasive way to make this change that I didn't even think of in my enumerated approaches in #468.

Alternatively, we could have some way to extract an ErrorContext from which an Error (request,context) could be extracted from an ErrorContext::extract_req(e: Error) -> (Request, ohttp_ctx)

But I think this gets us the progress we want and we can follow up if we decide that's a good idea with the rest of the receiver module error split.

Recoverable errors are be shared with the Sender so that they
might recover rather than necessarily waiting for the session
to expire.
Only `Receiver.id()` needs to be public.
Subdir can be a private pure function.
@coveralls
Copy link
Collaborator

Pull Request Test Coverage Report for Build 12740129056

Details

  • 15 of 78 (19.23%) changed or added relevant lines in 4 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.7%) to 60.133%

Changes Missing Coverage Covered Lines Changed/Added Lines %
payjoin/src/receive/v2/error.rs 0 3 0.0%
payjoin/src/receive/error.rs 0 6 0.0%
payjoin-cli/src/app/v2.rs 0 22 0.0%
payjoin/src/receive/v2/mod.rs 15 47 31.91%
Totals Coverage Status
Change from base Build 12677131350: -0.7%
Covered Lines: 2887
Relevant Lines: 4801

💛 - Coveralls

@DanGould DanGould mentioned this pull request Jan 13, 2025
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.

V2 Original Message A error json not returned to Sender from Receiver
2 participants