Anthony-Nolan / Atlas

A free & open-source Donor Search Algorithm Service
GNU General Public License v3.0
9 stars 5 forks source link

Repeat search failing at matching algorithm #1100

Closed zabeen closed 1 year ago

zabeen commented 1 year ago
Inner exception System.Collections.Generic.KeyNotFoundException handled at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw
System.ThrowHelper.ThrowKeyNotFoundException |   |  
Atlas.RepeatSearch.Services.Search.RepeatSearchDifferentialCalculator.LookupDonorIdFromCode | RepeatSearchDifferentialCalculator.cs | 81

Example from AI

Example failed repeat search request from UAT-WMDA-ATLAS on 18th Oct 2023:

  "SearchRequestId": "349ce783-cfaa-4b00-88d0-c3728e6f64fc",
  "RepeatSearchRequestId": "a14375d6-f5e2-4770-aa85-7f3ec3725c5d"
zabeen commented 1 year ago

Testing Notes

daria-sorokina-da commented 1 year ago

Scenarios

  1. Some of the donors in the search are the same as they were (not updated since cut-off date)

First search (Canonical) returns donors [1, 2] Repeat search returns donors [2, 3] Updated donors since cut-off date returns [1,3,5,6] - needed only to figure out which donors were updated

New: [3] -> [{3, <atlas id of donor 3}>}] Updated: [2] -> filter out only the ones that were updated since cut-off date -> [] Delete: [1] -> [{1,<atlas id of donor 1}>}]

  1. Some of the donors in the search have been updated

First search (Canonical) returns donors [1,2] Repeat returns donors [2,3] Updated since cut-off date returns [1,2,5,6] - needed only to figure out which donors were updated

New: [3] -> [{3, <atlas id of donor 3}>}] Updated: [2] -> filter out only the ones that were updated since cut-off date -> [2,<atlas id of donor 2}>}] Delete: [1] -> [{1,<atlas id of donor 1}>}]

==============================================================

Test scenarios:

  1. Donor gets deleted First search: [1,2] Delete donor 2 (via donor update file) Repeat searct => {new: [], updated: [], deleted: [2]}
  2. Donor gets added First search: [1,2] Add donor 3 that matches the search (via donor update file) Repeat search => {new: [3], updated: [], deleted: []}
  3. Donor gets updated but still a match First search: [1,2] Update donor 2 with update file, but make sure that the donor is still a match Repeat search => {new: [], updated: [2], deleted: []}
  4. Donor gets updated and not a match anymore First search: [1,2] Update donor 2 with update file, and change its HLA so that it's not a match anymore Repeat search => {new: [], updated: [], deleted: [2]}
daria-sorokina-da commented 1 year ago

During testing, please pay attention to Atlas Donor Ids - make sure that they are filled, and valid.

DmitriyShcherbina commented 1 year ago

@zabeen @daria-sorokina-da @IgorKupreychik Testing status: Ok But during testing process I faced with strange behaviour, so I created this ticket https://github.com/Anthony-Nolan/Atlas/issues/1108

RimkePostel commented 12 months ago

Testing in SBX approved