Skip to content

Conversation

@defi0x1
Copy link
Collaborator

@defi0x1 defi0x1 commented Nov 13, 2025

Fix: Always drop pool borrow before reload pool to prevent AccountBorrowFailed when without external swap (liquidity is 0)

Screenshot 2025-11-14 at 05 04 40

@andrewsource147 andrewsource147 merged commit 0ec2249 into release_0.2.0 Nov 14, 2025
3 checks passed
@andrewsource147 andrewsource147 deleted the fix_account_borrow branch November 14, 2025 01:24
andrewsource147 added a commit that referenced this pull request Dec 4, 2025
* init release 0.2.0

* Zap in (#18)

* init

* update changelog

* remove comments

* update flow

* refactor

* care for transfer fee extension

* refactor

* fix for rate limiter

* fix for rate limiter

* fix rate limiter

* add zapin dlmm

* fix based comments

* add unit test for dlmm

* add unit test in damm v2

* log deposit and remaining amounts after zapin

* test/fix zap in (#17)

* dammv2 0.1.5

* update test

* trigger cicd

* low liquidity case

* fix liquidity

* remove only

* cicd

* update test

* update test

* update test

* bin array bitmap extension test

* fix comments

* fix test

---------

Co-authored-by: Andrew Nguyen <cuong.hv.dtvt@gmail.com>

* support transfer fee (#19)

* update readme

---------

Co-authored-by: defi0x1 <34453681+defi0x1@users.noreply.github.com>

* allow position to shrink

* fix account borrow (#20)

* flexible for zap in (#22)

* Release 0.2.0 Audit fix (#37)

* fix: price diff bps ceil (#26)

* fix: validate min max delta (#28)

* fix: make sure position not rent payer as well (#30)

* fix: use crate defined max basis point (#32)

* fix: potential overflow in user ledger (#33)

* fix: exp i32::MIN not representable (#34)

* fix: skip swap when output is zero amount (#35)

* fix: skip swap if output is zero

* fix: swap_out_amount inverted

* fix: typo and comments (#31)

* fix: potential overflow (#27)

* fix: potential overflow

* chore: use non upcast formula to calc midpoint

* fix: return error if unknown fee mode (#38)

* fix: stop swap if swap computation fail (#25)

* fix: stop swap attempt if sim fail

* fix: stop swap attempt if sim fail

* fix: binary search (#36)

* fix: avoid meaningless loop

* fix after rebase

---------

Co-authored-by: Andrew Nguyen <cuong.hv.dtvt@gmail.com>

* fix: curve and bid ask single bin zap in (#23)

* fix: curve & bidask zap in single bin

* fix: bidask and curve x0, delta_x formula when delta == 0

* fix: curve reduce precision loss (#24)

* fix: curve reduce precision loss

* fix type

---------

Co-authored-by: Andrew Nguyen <cuong.hv.dtvt@gmail.com>

---------

Co-authored-by: kampung-tech <tian@raccoons.dev>

* minor fix (#39)

* remove unused import

---------

Co-authored-by: defi0x1 <34453681+defi0x1@users.noreply.github.com>
Co-authored-by: kampung-tech <tian@raccoons.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants