File tree 1 file changed +2
-6
lines changed
1 file changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -258,7 +258,7 @@ def _utxos_kupo(self, address: str) -> List[UTxO]:
258
258
"kupo_url object attribute has not been assigned properly."
259
259
)
260
260
261
- kupo_utxo_url = self ._kupo_url + "/matches/" + address
261
+ kupo_utxo_url = self ._kupo_url + "/matches/" + address + "?unspent"
262
262
results = requests .get (kupo_utxo_url ).json ()
263
263
264
264
utxos = []
@@ -267,11 +267,7 @@ def _utxos_kupo(self, address: str) -> List[UTxO]:
267
267
tx_id = result ["transaction_id" ]
268
268
index = result ["output_index" ]
269
269
270
- # Right now, all UTxOs of the address will be returned with Kupo, which requires Ogmios to
271
- # validate if the UTxOs are spent with output reference. This feature is being considered to
272
- # be added to Kupo to avoid extra API calls.
273
- # See discussion here: https://github.com/CardanoSolutions/kupo/discussions/19.
274
- if self ._check_utxo_unspent (tx_id , index ):
270
+ if result ["spent_at" ] is None :
275
271
tx_in = TransactionInput .from_primitive ([tx_id , index ])
276
272
277
273
lovelace_amount = result ["value" ]["coins" ]
You can’t perform that action at this time.
0 commit comments