(Resolved) A minor bug and a simple request


I think I’ve found a minor bug.

In https://github.com/incognitochain/incognito-chain/blob/6cdb8e2494d43c70221fc0be7479d769088aae5e/blockchain/pdex/statedb.go#L364 line, orderbook object is filled but it is not sent to the client. I mean an empty orderbook (https://github.com/incognitochain/incognito-chain/blob/6cdb8e2494d43c70221fc0be7479d769088aae5e/blockchain/pdex/statedb.go#L380) is sent.

As for my request, could you add a new verbosity (say LiquidityVerbosity) to pdexv3State/PoolPairs RPC which sends only State and Orderbook parts of the pairs? If you have no time and accept it, I’ve prepared a PR (https://github.com/incognitochain/incognito-chain/pull/1504) via Github site. However, I think and hope that it will compile and run flawlessly :slight_smile:



Thank you so much for the PR @abduraman, we will definitely review it today and get back to you soon.

1 Like

Hey @abduraman, maybe you might know already, your PR was merged to the chain’s codebase and will be deployed on mainnet this week. Thanks again for your contribution!

1 Like

Yes, I was notified by Github yesterday. Thanks for merging. I’m a non-core contributor of Incognito :slight_smile:


Btw, just to prevent misunderstanding, PR only adds the feature, not fixes the bug below:

If not implemented, to remove the bug, Orderbook{} should be replaced with *orderbook. @duc