Skip to content

Commit

Permalink
Merge pull request #9792 from vegaprotocol/9787-copy-input0slice-befo…
Browse files Browse the repository at this point in the history
…re-sorting

fix: only sort what has comes from maps, and not input
  • Loading branch information
jeremyletang authored Oct 16, 2023
2 parents e067171 + ead89a1 commit a32e296
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 11 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,7 @@
- [9658](https://github.com/vegaprotocol/vega/issues/9658) - Fix `updateVolumeDiscountProgram` GraphQL resolver.
- [9672](https://github.com/vegaprotocol/vega/issues/9672) - Fix margin being non-zero on `PERPS`, add tests to ensure distressed parties are handled correctly
- [9280](https://github.com/vegaprotocol/vega/issues/9280) - Get block height directly from `blocks` table.
- [9787](https://github.com/vegaprotocol/vega/issues/9787) - Do not sort market input so that tracking of dispatch strategies are not disturbed.
- [9675](https://github.com/vegaprotocol/vega/issues/9675) - Fix snapshot issue with not applying `providersCalculationStep` at epoch start.
- [9693](https://github.com/vegaprotocol/vega/issues/9693) - Add missing validation for general account public key in governance transfer
- [9691](https://github.com/vegaprotocol/vega/issues/9691) - Refactor referral engine snapshot
Expand Down
10 changes: 1 addition & 9 deletions core/banking/recurring_transfers.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,15 +107,7 @@ func (e *Engine) recurringTransfer(
// in the recurringTransfer map/slice
e.recurringTransfers = append(e.recurringTransfers, transfer)
e.recurringTransfersMap[transfer.ID] = transfer

if transfer.DispatchStrategy != nil {
hash := e.hashDispatchStrategy(transfer.DispatchStrategy)
if _, ok := e.hashToStrategy[hash]; !ok {
e.hashToStrategy[hash] = &dispatchStrategyCacheEntry{ds: transfer.DispatchStrategy, refCount: 1}
} else {
e.hashToStrategy[hash].refCount++
}
}
e.registerDispatchStrategy(transfer.DispatchStrategy)

return nil
}
Expand Down
3 changes: 1 addition & 2 deletions core/execution/common/market_activity_tracker.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,10 +221,9 @@ func (mat *MarketActivityTracker) GetMarketsWithEligibleProposer(asset string, m
}
}
}
sort.Strings(mkts)
}

sort.Strings(mkts)

assets := []string{}
if len(asset) > 0 {
assets = append(assets, asset)
Expand Down

0 comments on commit a32e296

Please sign in to comment.