Closed MuthuVega closed 1 year ago
This issue happens only during the full run where there are a lot of markets and liquidity provisions. If this test is run on its own , the test will pass.
Jenkins Failure:
Jenkins Logs:
https://jenkins.ops.vega.xyz/job/common/job/system-tests-wrapper/69948/consoleText
In the above logs search for Datanode data diff output for to find the output.
System Tests Test name - test_datanode_compare_restored_datanode_data_against_core
System Tests Marker - datanode_core_datadiff
this is an issue with the tool. The LP missing from datanode results (hence causing the count to mismatch) is a PENDING LP. This is caused by the tool excluding pending LPs from datanode result before the comparison. The ticket should be moved to vegatools.
Thanks @ze97286
Some additional info
the one that's missing from datanode is this one:
id:"346e3f6271453f149cfd8df2aff5996b8bcde173d473db6f0a3096f3d81c5c8f" party_id:"de57914db91d4bdcb31ac406895da4d91d0c01ab652e81f1b97844c347ce5080" created_at:1683767578347485000 updated_at:1683767578347485000 market_id:"50ea1a1b4c65ac836b1145f690b1965ca0d00294792bac96728959e975097191" commitment_amount:"390500000000000000" fee:"0.3" sells:{order_id:"9465e4e578ea31cf8478fd158d7aca6312f5dcce51a7e6fa1d57e74cef50729e" liquidity_order:{reference:PEGGED_REFERENCE_BEST_ASK proportion:13 offset:"1000000000000"}} buys:{order_id:"478ba09795193a8e05dfbfc0174c0fbbc9c2229aed1cd7a60012dc04738cf837" liquidity_order:{reference:PEGGED_REFERENCE_BEST_BID proportion:2 offset:"1000000000000"}} version:1 status:STATUS_PENDING reference:"LIQPROV-test_List_Markets-1dc663e9"
[11:12](https://vegaprotocol.slack.com/archives/D02QGGS6TKK/p1684231948591849)
which is the only one that's pending. need to look at the API if it's expected to return LPs with status pending or if it doesn't is it a matter of passing different parameters to the API
[11:14](https://vegaprotocol.slack.com/archives/D02QGGS6TKK/p1684232041364109)
we filter them out in the tool, out of the result returned from datanode:
func (dnc *dataNodeClient) listLiquidityProvisions(market string) ([]*vega.LiquidityProvision, error) {
live := true
resp, err := dnc.datanode.ListLiquidityProvisions(context.Background(), &dn.ListLiquidityProvisionsRequest{MarketId: &market, Live: &live})
if err != nil {
return nil, err
}
lps := make([]*vega.LiquidityProvision, 0, len(resp.LiquidityProvisions.Edges))
for _, lpe := range resp.LiquidityProvisions.Edges {
if lpe.Node.Status == vega.LiquidityProvision_STATUS_ACTIVE || lpe.Node.Status == vega.LiquidityProvision_STATUS_UNDEPLOYED {
lps = append(lps, lpe.Node)
}
}
return lps, nil
}
The vegatools - difftool is reporting mismatches for liquidityProvisions table.
The actual difference being reported is:
Full output of the vegatools difftool command: