Files
pumpfun-bonkfun-bot_github/tests
Anton SauchykandGitHub 503785feb5 fix(trading): sell the exact raw token count the buy received (#245)
* fix(trading): sell the exact raw token count the buy received

The buy read the raw token count off its transaction, kept it as a float, and
the sell rebuilt it with int(amount * 10**6), which for some counts comes out
one raw unit short and leaves dust in the token account. The raw count now
travels on TradeResult and Position to the seller, and an exact-in buy converts
its configured spend through its decimal text.

* fix(trading): keep the exact token count when the spend cannot be read

* fix(trading): price an exact-in buy from its spend when the spend can't be read
2026-11-01 19:10:08 +01:00
..