Skip to content

Commit

Permalink
feat: cleanup examples
Browse files Browse the repository at this point in the history
  • Loading branch information
Evan-Kim2028 committed Jul 21, 2024
1 parent a7209ba commit 943199d
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
2 changes: 0 additions & 2 deletions examples/hypersync/get_windows_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
pl.Config.set_fmt_str_lengths(200)
pl.Config.set_fmt_float("full")

# Create an asynchronous function to manage the queries


async def main():
# Initialize the client
Expand Down
6 changes: 0 additions & 6 deletions examples/hypersync/get_windows_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,14 @@
deposits_df = asyncio.run(client.get_window_deposits(
address='0xe51EF1836Dbef052BfFd2eB3Fe1314365d23129d'))

# print(deposits_df.head(5))

withdraws_df = asyncio.run(client.get_window_withdraws(
address='0xe51EF1836Dbef052BfFd2eB3Fe1314365d23129d'))
# print(withdraws_df.head(5))


# extract dataframe columns to lists
deposit_windows: list[int] = deposits_df['windowNumber'].to_list()
withdraw_windows: list[int] = withdraws_df['window'].to_list()
# take the set difference between deposit_windows and withdraw_windows
windows: list[int] = list(set(deposit_windows) - set(withdraw_windows))
# convert float to integer
# windows: list[int] = [int(window) for window in windows]
print('windows with funds still locked')
print(windows)

Expand Down

0 comments on commit 943199d

Please sign in to comment.