Skip to content

Commit 7e86eb7

Browse files
ADD. asserting _kupo_url has been set
1 parent 33b90a6 commit 7e86eb7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

pycardano/backend/ogmios.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,6 +233,9 @@ def _utxos_kupo(self, address: str) -> List[UTxO]:
233233
Returns:
234234
List[UTxO]: A list of UTxOs.
235235
"""
236+
if self._kupo_url is None:
237+
raise AssertionError("kupo_url object attribute has not been assigned properly.")
238+
236239
address_url = self._kupo_url + "/" + address
237240
results = requests.get(address_url).json()
238241

0 commit comments

Comments
 (0)