1
0

Kucoin coverage
All checks were successful
Build container / Package-Python (push) Successful in 22s
Build container / Package-Container (push) Successful in 1m19s

This commit is contained in:
Jon Michael Aanes 2024-05-18 22:03:34 +02:00
parent 53f307e40c
commit 4be07a91bb
Signed by: Jmaa
SSH Key Fingerprint: SHA256:Ab0GfHGCblESJx7JRE4fj4bFy/KRpeLhi41y4pF3sNA

View File

@ -44,8 +44,8 @@ class KucoinAccountBalances(Scraper):
def addresses_to_data_points(addresses) -> frozendict: def addresses_to_data_points(addresses) -> frozendict:
data_point = {} data_point = {}
data_point['account.num_deposit_addresses'] = len(addresses)
data_point['account.update_time'] = datetime.datetime.now(tz=datetime.UTC) data_point['account.update_time'] = datetime.datetime.now(tz=datetime.UTC)
data_point['account.num_deposit_addresses'] = len(addresses)
if len(addresses) > 0: if len(addresses) > 0:
for k, v in addresses[-1].items(): for k, v in addresses[-1].items():
@ -61,6 +61,5 @@ class KucoinDepositAddresses(Scraper):
deduplicate_ignore_columns = ['account.update_time'] deduplicate_ignore_columns = ['account.update_time']
def scrape(self) -> Iterator[Mapping[str, object]]: def scrape(self) -> Iterator[Mapping[str, object]]:
# addresses = client.get_deposit_address('MPC') addresses = client.get_deposit_address('MPC')
addresses = list()
yield addresses_to_data_points(addresses) yield addresses_to_data_points(addresses)