发布

  • 15508 fd76171604

    Expire Instead of Clear Insights In Base PCM In OnSecuritiesChanged (#7251)

    frostbyte_neo 发布于 2023-05-18 14:20:17 +00:00 | 1424 次提交 在此版本后已推送到 master

    • Expire Instead of Clear Insights In Base PCM In OnSecuritiesChanged

    • Fixes Regression Test

    The regression was incorrect because _removedSymbols didn't retain the removed symbols from previous OnSecuritiesChanged calls, and the algorithm relances once per month. E.g. On day 1, SPY and FB were removed, on day 3 AAPL and IBM were removed and removedSymbols would only include AAPL and IBM.

    We should hve fixed this problem before with:

    if (_removedSymbols == null) _removedSymbols = new List<Symbol>();
    _removedSymbols.AddRange(changes.RemovedSecurities.Select(x => x.Symbol));
    

    However the change to use Expire fixes the issue.

    • Removes Unused List of Removed Symbols
    下载附件