You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Portfolio API - Gateway wallet tokens are missing from portfolio state #195
While testing #193 and use a Solana mint-address swap, the wallet successfully received 0.156298 TRUMP. Gateway's direct POST /chains/solana/balances route returned SOL, USDC, and TRUMP with the correct positive balances, but Hummingbot API's refreshed POST /portfolio/state response returned only SOL and USDC. Restarting Gateway did not change the result. The token remained registered, and Gateway continued to detect both SPL token accounts.
The expected result is for portfolio state to include every positive wallet balance returned by Gateway. The observed code path appears to store the complete Gateway wallet result and then overwrite the same master_account["solana-mainnet-beta"] entry with the narrower balance list from an initialized trading connector. This can make users or portfolio automation believe an asset is missing even though the wallet still holds it.
The affected code path is also present on the current main branch at ddcc11e87de1aea55446fb859f5babb1a940e937, but main was inspected rather than separately live-tested.
Steps to reproduce bug
Start Hummingbot API and Gateway, then initialize solana-mainnet-beta with a pair such as SOL-USDC.
Add a Solana token mint to Gateway and complete a swap so the default wallet holds a positive balance.
Call Gateway’s POST /chains/solana/balances route and confirm the token is returned.
Call Hummingbot API’s POST /portfolio/state with refresh: true, filtered to master_account and solana-mainnet-beta.
Observe that portfolio state lists the connector’s tracked tokens but omits the additional Gateway wallet token.
Activity
fix(portfolio): stop Gateway connectors from overwriting wallet balances
fix(portfolio): stop Gateway connectors from overwriting wallet balances