-
Notifications
You must be signed in to change notification settings - Fork 217
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
Join stake pool shelley #1722
Join stake pool shelley #1722
Conversation
66ef978
to
bba630e
Compare
I need to still improve on
|
bba630e
to
5791948
Compare
(k, pwd) <- lookupPrivateKey keyFrom addr | ||
pure $ mkWitness unsigned (getRawKey k, pwd) | ||
|
||
witsForChimeric <- fmap Set.fromList (pure $ [mkWitness unsigned (getRawKey accXPrv, pwd')]) |
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 probably the culprit for too low fee - I am adding this artificially
eaf01ae
to
8c8d70e
Compare
-> [TxOut] | ||
-> Either ErrMkTx (Tx, SealedTx) | ||
_mkDelegationJoinTx poolId (accXPrv, pwd') keyFrom slot ownedIns outs = do | ||
let timeToLive = (toSlotNo epochLength slot) + 7200 |
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.
I know this is still a draft, but I hope the similarities between mkDelegationJoinTx
and mkStdTx
can be factored out
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.
yes, some code overlap - I will reuse it later
VerKeyEd25519DSIGN . | ||
throwCryptoError $ | ||
Ed25519.publicKey pId | ||
--} |
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.
I'd definitely factor these functions out to make the body of this function more readable 👍
:: PoolId | ||
-> Cardano.ShelleyVerificationKeyHashStakePool | ||
toPoolIdHash (PoolId pId) = | ||
SL.KeyHash $ Hash.UnsafeHash pId |
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.
Shouldn't our pool id be already the hashed version?
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.
right now it is hashed, so it goes wrapped with ledger data constructors. Below, there is version that hashes verification key. But because knownStakePools
will return hashes we are not going to use it
(toStakingKeyHash accXPrv) | ||
(toPoolIdHash poolId) | ||
let unsigned = | ||
mkUnsignedTx timeToLive ownedIns outs [registerCert, delegateCert] |
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.
👍
c43e8ef
to
cda3f3c
Compare
88ce777
to
9841048
Compare
9c82939
to
d4d3c04
Compare
bors try |
tryBuild failed |
3033671
to
e3b889c
Compare
98c69a3
to
a719a4c
Compare
bors r+ |
1722: Join stake pool shelley r=KtorZ a=paweljakubas # Issue Number <!-- Put here a reference to the issue this PR relates to and which requirements it tackles --> #1709 # Overview <!-- Detail in a few bullet points the work accomplished in this PR --> - [x] I have mocked stake pool layer and added joinStakePool to shelley api server - [x] I have added first tests (now wallet id and no pool id) for stake pools in shelley - [x] I have added impl for mkDelegationJoinTx - [x] I have extended mkDelegationJoinTx by adding WalletDelegation - [x] I have added tests for joining/rejoining - [x] I have impl quitting and added tests # Comments <!-- Additional comments or screenshots to attach if any --> <!-- Don't forget to: ✓ Self-review your changes to make sure nothing unexpected slipped through ✓ Assign yourself to the PR ✓ Assign one or several reviewer(s) ✓ Once created, link this PR to its corresponding ticket ✓ Assign the PR to a corresponding milestone ✓ Acknowledge any changes required to the Wiki --> Co-authored-by: Pawel Jakubas <[email protected]> Co-authored-by: KtorZ <[email protected]>
Build failed |
bors r- |
bors r+ |
1722: Join stake pool shelley r=KtorZ a=paweljakubas # Issue Number <!-- Put here a reference to the issue this PR relates to and which requirements it tackles --> #1709 # Overview <!-- Detail in a few bullet points the work accomplished in this PR --> - [x] I have mocked stake pool layer and added joinStakePool to shelley api server - [x] I have added first tests (now wallet id and no pool id) for stake pools in shelley - [x] I have added impl for mkDelegationJoinTx - [x] I have extended mkDelegationJoinTx by adding WalletDelegation - [x] I have added tests for joining/rejoining - [x] I have impl quitting and added tests # Comments <!-- Additional comments or screenshots to attach if any --> <!-- Don't forget to: ✓ Self-review your changes to make sure nothing unexpected slipped through ✓ Assign yourself to the PR ✓ Assign one or several reviewer(s) ✓ Once created, link this PR to its corresponding ticket ✓ Assign the PR to a corresponding milestone ✓ Acknowledge any changes required to the Wiki --> Co-authored-by: Pawel Jakubas <[email protected]> Co-authored-by: KtorZ <[email protected]>
Build failed |
771de62
to
c8ee7f2
Compare
bors r+ |
1722: Join stake pool shelley r=KtorZ a=paweljakubas # Issue Number <!-- Put here a reference to the issue this PR relates to and which requirements it tackles --> #1709 # Overview <!-- Detail in a few bullet points the work accomplished in this PR --> - [x] I have mocked stake pool layer and added joinStakePool to shelley api server - [x] I have added first tests (now wallet id and no pool id) for stake pools in shelley - [x] I have added impl for mkDelegationJoinTx - [x] I have extended mkDelegationJoinTx by adding WalletDelegation - [x] I have added tests for joining/rejoining - [x] I have impl quitting and added tests # Comments <!-- Additional comments or screenshots to attach if any --> <!-- Don't forget to: ✓ Self-review your changes to make sure nothing unexpected slipped through ✓ Assign yourself to the PR ✓ Assign one or several reviewer(s) ✓ Once created, link this PR to its corresponding ticket ✓ Assign the PR to a corresponding milestone ✓ Acknowledge any changes required to the Wiki --> Co-authored-by: Pawel Jakubas <[email protected]> Co-authored-by: KtorZ <[email protected]>
Build failed |
c8ee7f2
to
b5d966e
Compare
bors try |
The transaction submission command seems to occasionally fail on macos, unable to open the socket.
tryBuild failed |
Retrying submitTx worked when testing locally... bors try |
tryBuild failed |
Most messages from the node are actually redundant with the messages we get from our own networking layer.
Pools are still registered on-chain beforehand, so we can still get to test a bunch of things.
bors r+ |
Build succeeded |
Issue Number
#1709
Overview
Comments