Skip to content

Commit

Permalink
Ensure that the pool-finder runs on the first iteration when enabled …
Browse files Browse the repository at this point in the history
…(i.e., when its period is larger than 0)
  • Loading branch information
barak manos authored and platonfloria committed May 13, 2024
1 parent b4319b1 commit 75d57a1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -525,7 +525,7 @@ def run(mgr, args, tenderly_uri=None) -> None:
mgr.solidly_v2_event_mappings = dict(
solidly_v2_event_mappings[["address", "exchange"]].values
)
if args.pool_finder_period > 0 and loop_idx % args.pool_finder_period == 0:
if args.pool_finder_period > 0 and (loop_idx - 1) % args.pool_finder_period == 0:
mgr.cfg.logger.info(f"Searching for unsupported Carbon pairs.")
uni_v2, uni_v3, solidly_v2 = pool_finder.get_pools_for_unsupported_pairs(mgr.pool_data, arb_mode=args.arb_mode)
mgr.cfg.logger.info(f"Number of pools added: {len(uni_v2) + len(uni_v3) + len(solidly_v2)}")
Expand Down

0 comments on commit 75d57a1

Please sign in to comment.