eliotstock / dro

Uniswap v3 dynamic range orders
0 stars 1 forks source link

Handle broadening the range at runtime #5

Closed eliotstock closed 2 years ago

eliotstock commented 2 years ago

The code currently makes no distinction between the range from the .env file and the one from the existing position at Uniswap, when there's a pre-existing position on start up.

When going from a broad range to a narrow one, this is acceptable. When the edge of the broad range is met, we re-range and the new range is narrower.

When going from a narrow range to a broad one, this is a bug. The existing order has met the edge of its range, but the code considers it still to be in range because it's using the broad range already. We should remove liquidity but we do not.

eliotstock commented 2 years ago

I think this is fixed. Testing now. Changes in main already though.

msnelling commented 2 years ago

Yep, I’m running from main now.

On 11 Mar 2022, at 08:45, Eliot Stock @.***> wrote:

I think this is fixed. Testing now. Changes in main already though.

— Reply to this email directly, view it on GitHub https://github.com/biketracker/dro/issues/5#issuecomment-1064897670, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIEUQZPO4S3XG43ITQD34DU7MBZPANCNFSM5QB4N2OQ. You are receiving this because you are subscribed to this thread.

eliotstock commented 2 years ago

yeah....fixed