-
-
Notifications
You must be signed in to change notification settings - Fork 97
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
Discreet Log Contracts #576
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #576 +/- ##
==========================================
- Coverage 69.02% 59.31% -9.71%
==========================================
Files 92 101 +9
Lines 8674 11082 +2408
==========================================
+ Hits 5987 6573 +586
- Misses 2687 4509 +1822 ☔ View full report in Codecov by Sentry. |
So now basically i wanted to add to the wallet the possibility of minting/swapping-for DLC locked proofs.
Naturally this would imply a slight change in the DB table that holds the Proofs in order to accomodate |
And of course I am going to add tests for all of this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wow thanks for getting the ball rolling on this! I was surprised to see this as I hadn't received any comments on either NUT drafts. @lollerfirst Is there any discussion which needs to happen to validate the spec itself before we push ahead with this implementation? I would be happy to help out with the code if that's what the cashu team is aiming for now.
I suppose so. But I thought I would get started in the meantime. |
By the way congrats on the proposal, it's very well written. |
Co-authored-by: conduition <[email protected]>
working on a wallet implementation. the router was a bit broken, opened a PR to fix it |
Fix router paths and add `POST /v1/dlc/settle`
@gudnuf Thank you! I haven't tested the router well. The tests I wrote check the functionality but do not go through the router. Right now the only thing missing from the mint side is It's great you're working on a wallet implementation! Since the beginning I thought that the DLC orchestration between clients should be a separate thing from this. |
Looks like that's already implemented, no?
I'm working on this to help me learn rust, so forking it into cdk-cli. It will use NIP88 for the DLC orchestration between wallets |
Yea I implemented it yesterday. Nice! Will read about NIP-88. Not everything here is properly commented and named, so if you have any issue let me know. |
cashu/core/models.py
Outdated
|
||
class GetDlcStatusResponse(BaseModel): | ||
settled: bool | ||
unit: Optional[str] = None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is inconsistent from the spec. There is no unit field defined in the responses. I think including the keyset ID in the status response would make more sense than unit if anything.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Weird mistake. I'll be sure to fix that.
Test failing randomly I don't think it's related to this PR. |
Implementing @conduition 's awesome proposal (cashubtc/nuts#128) for discrete log contract execution on chaumian ecash mints.