IntersectMBO / cardano-node

The core component that is used to participate in a Cardano decentralised blockchain.
https://cardano.org
Apache License 2.0
3.07k stars 720 forks source link

[BUG] - preprod testnet withdrawal doesn't work #6015

Closed ekko-Huang closed 1 month ago

ekko-Huang commented 1 month ago

I using off-chain sdk to build a transaction raw txraw:

84a4008182582063cf0c197527841a6308c82a807d25efd96026dc3dea1d10c9c4ff7955b58e21000181825839002fa9016e5c7a8634c74cd064bfcb29d4b8ecbd2b64a17438763c35db15194b17d2214dd1d927331091cb269001518cac8901bfd2e713fc301a0072b792021a0002a16d05a1581de015194b17d2214dd1d927331091cb269001518cac8901bfd2e713fc30199231a10082825820aa121ea23de87b1773816dcfa7b76d3986a146a257c7c4e25f2e53135403b9c5584007d64c5c19dfee0cc37fcafc91ac518491b61b0cdd6c2420e6e8360c586044696713af06424a52aee53e28480ff8af4d1e42e849dea2931e8e389083360a870b82582047aee32f6a924a3a12322277b0b64ce7241331b534943c1bd6cce7bda2b04d2d58406cbecefd64d4e8b1dfe5e2597f52e5fd07a21ffd0cf629ec505b3daec8895ea375a08ad29f211c85a48acc163e3fced74aff59fb7879fda6ef85905ad76bf307f5f6

When broadcasting the transaction, an error occurred

{
    "error": "Bad Request",
    "message": "{"contents":{"contents":{"contents":{"era":"ShelleyBasedEraConway","error":["ConwayCertsFailure (WithdrawalsNotInRewardsCERTS (fromList [(RewardAccount {raNetwork = Testnet, raCredential = KeyHashObj (KeyHash {unKeyHash = \"15194b17d2214dd1d927331091cb269001518cac8901bfd2e713fc30\"})},Coin 37425)]))"],"kind":"ShelleyTxValidationError"},"tag":"TxValidationErrorInCardanoMode"},"tag":"TxCmdTxSubmitValidationError"},"tag":"TxSubmitFail"}",
    "status_code": 400
}
CarlosLopezDeLara commented 1 month ago

Please make sure you are withdrawing the entire balance of rewards address.

https://github.com/IntersectMBO/cardano-ledger/blob/30992cb50df3e3a763073f58fdba921191d8af1c/eras/conway/impl/src/Cardano/Ledger/Conway/Rules/Certs.hs#L116