Skip to content

Conversation

OlufemiAdeOlusile
Copy link
Collaborator

@OlufemiAdeOlusile OlufemiAdeOlusile commented Sep 2, 2025

This PR simplifies and unifies the delegation transaction handling by removing redundant use_build_cmd branches and consolidating transaction creation into a single clusterlib_utils.build_and_submit_tx flow.

Key Changes

  • delegate_stake_addr

    • Removed conditional handling of use_build_cmd vs. send_tx.
    • Replaced both with clusterlib_utils.build_and_submit_tx for consistency.
    • Ensures returned DelegationOut uses tx_output instead of mixed outputs.
    • Balance validation updated to reference unified transaction output.
  • test_delegation.py

    • Updated delegation tests (delegate using pool_id, delegate using vkey, delegation + deregistration, unknown addr, deregistered addr) to use build_method instead of use_build_cmd.
    • Simplified test logic by removing duplicated transaction signing/submission branches.
    • Maintained existing assertions on balance updates, stake key deposits, and delegation error handling.

    Regression RUN: https://github.com/IntersectMBO/cardano-node-tests/actions/runs/17407105869/job/49414294045

except clusterlib.CLIError as exc:
if "ValueNotConservedUTxO" in str(exc):
issues.cli_942.finish_test()
raise
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please also check for blockers from common.match_blocker, if using transaction build.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

addressed

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.

2 participants