Skip to content

Commit

Permalink
Print full traceback for failed arbs.
Browse files Browse the repository at this point in the history
  • Loading branch information
dowlandaiello committed Jul 24, 2024
1 parent 682513b commit 2fba1b2
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/strategies/naive.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
of hops using all available providers.
"""

import traceback
from itertools import groupby
import asyncio
import random
Expand Down Expand Up @@ -150,8 +151,13 @@ async def strategy(
r.status = Status.EXECUTED

ctx.log_route(r, "info", "Executed route successfully", [])
except Exception as e:
ctx.log_route(r, "error", "Arb failed %s: %s", [fmt_route(route), e])
except Exception:
ctx.log_route(
r,
"error",
"Arb failed %s: %s",
[fmt_route(route), traceback.format_exc()],
)

r.status = Status.FAILED

Expand Down

0 comments on commit 2fba1b2

Please sign in to comment.