Skip to content

Update to UTxO RPC Spec v0.18.1 #29

@Mercurial

Description

@Mercurial

Update Required: UTxO RPC Spec v0.18.1

The lucid-evolution-provider currently depends on @utxorpc/spec version 0.17.0. This needs to be updated to 0.18.1 to support the latest spec features.

Current Dependencies

"@utxorpc/sdk": "0.7.0",
"@utxorpc/spec": "0.17.0"

Required Updates

"@utxorpc/sdk": "^0.8.0",  // or latest
"@utxorpc/spec": "^0.18.1"

Breaking Changes in 0.18.1

The following breaking changes need to be addressed:

1. Single TX Submission

SubmitTx changed from repeated tx to single tx. The provider may need updates if it batches transactions.

2. BigInt for Amounts

Many fields now use BigInt instead of numeric types. Check:

  • result.parsedValued.coin (line 293) - may need BigInt handling
  • subAsset.outputCoin (line 303) - may need BigInt handling

3. Idle Action in WatchTx

New idle action type in WatchTxResponse for block progress signals (not used by this provider currently).


Current Feature Support

The provider uses @utxorpc/sdk for:

  • QueryClient.readParams() - Protocol parameters
  • QueryClient.searchUtxosByAddress() - UTxO queries
  • QueryClient.searchUtxosByPaymentPart() - Payment credential queries
  • QueryClient.searchUtxosByDelegationPart() - Delegation credential queries
  • QueryClient.searchUtxosByAddressWithAsset() - UTxO with asset queries
  • QueryClient.searchUtxosByPaymentPartWithAsset() - Payment + asset queries
  • QueryClient.searchUtxosByDelegationPartWithAsset() - Delegation + asset queries
  • QueryClient.searchUtxosByAsset() - Asset queries
  • QueryClient.readUtxosByOutputRef() - Resolve UTxOs
  • SubmitClient.submitTx() - Transaction submission
  • SubmitClient.waitForTx() - Await confirmation
  • SubmitClient.evalTx() - Transaction evaluation

Not Implemented

  • getDelegation() - throws "Method not implemented"
  • getDatum() - throws "Method not implemented"

Action Items

  1. Update @utxorpc/spec to ^0.18.1
  2. Update @utxorpc/sdk to latest version
  3. Test BigInt handling for coin/asset amounts
  4. Verify transaction submission still works with single-tx API
  5. Consider implementing getDatum() using QueryClient.readData() when available in SDK

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions