Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix issue in which validator test could randomly fail #90

Merged
merged 2 commits into from
Aug 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions fastlane_bot/bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -511,22 +511,22 @@ def validate_optimizer_trades(self, arb_opp, arb_mode, arb_finder):
-------
tuple or None
"""
(
best_profit,
best_trade_instructions_df,
best_trade_instructions_dic,
best_src_token,
best_trade_instructions,
) = arb_opp

(
ordered_trade_instructions_dct,
tx_in_count,
) = self._simple_ordering_by_src_token(
best_trade_instructions_dic, best_src_token
)
if arb_mode == "bancor_v3" or arb_mode == "b3_two_hop":

(
best_profit,
best_trade_instructions_df,
best_trade_instructions_dic,
best_src_token,
best_trade_instructions,
) = arb_opp

(
ordered_trade_instructions_dct,
tx_in_count,
) = self._simple_ordering_by_src_token(
best_trade_instructions_dic, best_src_token
)
cids = []
for pool in ordered_trade_instructions_dct:
pool_cid = pool["cid"]
Expand Down
Loading
Loading