Skip to content

How can I chain transaction? #145

Open
@jeffhappily

Description

@jeffhappily

I'm trying to use lucid to chain transaction, meaning to create a transaction that consumes output from another transaction in mempool, which is yet to be confirmed on-chain, it is possible to do it on Cardano, but it's not obvious how can I do it using lucid.

I tried to do it but I got this error

{
  "CannotCreateEvaluationContext": {
    "reason": "Unknown transaction input (missing from UTxO set): b7e37f8ebb8a113517055d0c637bfe7d4e266e816c83c034a25af70b31b1826a#0"
  }
}

The error seems to be coming from the call to construct function

lucid/src/lucid/tx.ts

Lines 584 to 588 in 4c92f56

await this.txBuilder.construct(
utxos,
changeAddress,
options?.nativeUplc === undefined ? true : options?.nativeUplc,
),
and the error message seems to be coming from Ogmios, but since the tx builder is from wasm, I'm not entirely sure.

But if this error truly comes from Ogmios, I do know that they support transaction chaining, in their EvaluateTx API, they take an argument called additionalUtxoSet, not sure if Lucid supports it or not.

Appreciate if I could get help on this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions