Prevent ActiveRecord::RecordNotUnique error on appeals redistribution #15163
Labels
Priority: Medium
Blocking issue w/workaround, or "second in" priority for new work.
Product: caseflow-queue
Source: Sentry Alert
created because of a Sentry alert
Stakeholder: BVA
Functionality associated with the Board of Veterans' Appeals workflows/feature requests
Team: Echo 🐬
Type: Bug
Description
This sentry alert uncovered an issue that in the event that a case is redistributed more than once, it will fail as as currently we are hardcoding the
case_id
inScheduleHearingColocatedTask
. Instead, we need to update that line to dynamically assign case ids, the most straightforward way being to inject a timestamp e.g. (case_id: "#{appeal.uuid}-attempt-#{Time.zone.now}")Acceptance criteria
send_to_hearings_branch
function inScheduleHearingColocatedTask
to dynamically assigncase_id
Background/context/resources
Sentry alert
Slack convo
The text was updated successfully, but these errors were encountered: