Caseflow: Fix CASEFLOW-charged VACOLS appeals with no active tasks

Created on 24 Jun 2019  路  22Comments  路  Source: department-of-veterans-affairs/caseflow

While working on resolving the problem of ColocatedTasks for LegacyAppeals being charged to the wrong VACOLS location when they were completed, I decided to look into the question of whether there were any appeals charged to the "CASEFLOW" VACOLS location that do not have active tasks in Caseflow and discovered that there are 10 appeals in this state.

One case charged to "CASEFLOW" in VACOLS does not have an associated LegacyAppeal in Caseflow. The other nine cases have associated LegacyAppeals but the only tasks they have in Caseflow are RootTasks. Caseflow will never change the VACOLS location of these 10 appeals away from "CASEFLOW".

Immediate recovery actions

  • Charge these cases away from CASEFLOW in VACOLS (probably to the most recent prior location?)

Long-term prevention actions

  • Determine how these 10 appeals ended up in this situation and prevent it from reoccurring

It may be difficult to determine how this happened (prior location table may provide some clues though) and it may have little return on the time investment. A more efficient solution might be to set up a regular (daily?) alert that notifies us when there are any appeals charged to "CASEFLOW" in VACOLS so that we can check the logs when this situation reoccurs.

Commands run in production that discovered this data integrity issue:

  rails c> vacols_ids = VACOLS::Case.where(bfcurloc: "CASEFLOW").pluck(:bfkey)
  rails c> vacols_ids.count
  # 28222
  rails c> appeal_ids = LegacyAppeal.where(vacols_id: vacols_ids).pluck(:id)
  rails c> appeal_ids.count
  # 28221
  # Which case charged to CASEFLOW in VACOLS does not exist in Caseflow?
  rails c> vacols_ids.sort - LegacyAppeal.where(id: appeal_ids).pluck(:vacols_id).sort
  # ["2832564"] <- bfkey
  rails c> appeal_with_tasks_ids = Task.where.not(type: [RootTask.name, TrackVeteranTask.name]).where(appeal_type: LegacyAppeal.name, appeal_id: appeal_ids).pluck(:appeal_id)
  rails c> appeal_with_tasks_ids = appeal_with_tasks_ids.uniq
  rails c> appeal_with_tasks_ids.count
  # 28212
  # Which appeals don't have active tasks?
  rails c> appeal_ids.sort - appeal_with_tasks_ids.sort
  # [25783, 54167, 68653, 195819, 292731, 346504, 557722, 730558, 761769] <- Appeal IDs
  # Spot check!
  rails c> LegacyAppeal.find(25783).tasks
  # Only a root task and nothing else.
  rails c> LegacyAppeal.find(54167).tasks
  # Root task and nothing else.
  rails c> LegacyAppeal.where(id: [25783, 54167, 68653, 195819, 292731, 346504, 557722, 730558, 761769]).map { |a| [a.id, a.tasks.pluck(:type)] }.to_h
  # {25783=>["RootTask"], 54167=>["RootTask"], 68653=>["RootTask"], 195819=>["RootTask"], 292731=>["RootTask"], 346504=>["RootTask"], 557722=>["RootTask"], 730558=>["RootTask"], 761769=>["RootTask"]}
  # They all only have root tasks.
  # When were these tasks created?
  rails c> Task.where(appeal_type: LegacyAppeal.name, appeal_id: [25783, 54167, 68653, 195819, 292731, 346504, 557722, 730558, 761769]).pluck(:created_at).sort
  # [Thu, 03 Jan 2019 20:49:40,
     Mon, 28 Jan 2019 22:42:01,
     Mon, 04 Feb 2019 17:23:50,
     Thu, 14 Feb 2019 17:44:13,
     Wed, 17 Apr 2019 13:21:41,
     Mon, 29 Apr 2019 14:42:23,
     Tue, 30 Apr 2019 13:01:42,
     Tue, 30 Apr 2019 14:10:48,
     Fri, 17 May 2019 17:31:05]
  # All created at different times.

Acceptance criteria

  • [ ] Charge these 10 appeals to correct VACOLS location
  • [ ] Set up alert to notify us when this situation reoccurs

    • [ ] Create the job that sends the report (#11258)

    • [ ] Run the job every day (https://github.com/department-of-veterans-affairs/appeals-deployment/pull/2128)

caseflow-queue Echo 馃惉 Bug

All 22 comments

Case| Situation | Who we should talk to
---|---|---
https://appeals.cf.ds.va.gov/queue/appeals/3107555 | Scheduled for video hearing May 17, 2019 (I can see a letter in their file) | Hearing branch
https://appeals.cf.ds.va.gov/queue/appeals/3228567 | Scheduled for a video hearing on May 21, 2019 | Hearing branch
https://appeals.cf.ds.va.gov/queue/appeals/3263705 | Chose DRO Review process on NOD (as opposed to Traditional Appellate Review Process) | LRP
https://appeals.cf.ds.va.gov/queue/appeals/2741402 | Chose DRO Review process on NOD (as opposed to Traditional Appellate Review Process) | LRP
https://appeals.cf.ds.va.gov/queue/appeals/2594151 | Hearing request on the Form 9, but no hearing letter yet saying that it's been scheduled | Hearing branch
https://appeals.cf.ds.va.gov/queue/appeals/2766060 | Hearing request on the Form 9, but no hearing letter yet saying that it's been scheduled | Hearing branch
https://appeals.cf.ds.va.gov/queue/appeals/2891584 | Hearing scheduled for 3/28/2019, the Veteran then requested it be postponed | Hearing branch
https://appeals.cf.ds.va.gov/queue/appeals/3933377 | I can't quite tell what's going on with this one. The Veteran is incarcerated | LRP
https://appeals.cf.ds.va.gov/queue/appeals/2703865 | Hearing request on the Form 9, but no hearing letter yet saying that it's been scheduled | Hearing branch

A more efficient solution might be to set up a regular (daily?) alert that notifies us when there are any appeals charged to "CASEFLOW" in VACOLS so that we can check the logs when this situation reoccurs.

I think this makes sense to do. Any appeals charged to CASEFLOW just without tasks, right?

I think this makes sense to do. Any appeals charged to CASEFLOW just without tasks, right?

Exactly.

We needed to schedule hearings for appeals 2741402, 2873340, and 2594151 pretty urgently, so @lomaxap and I created the ScheduleHearingTasks and HearingTasks for those 3 appeals.

LRP is going to take a look at the cases tagged for them and get back to us.

The incarcerated Veteran one (https://appeals.cf.ds.va.gov/queue/appeals/3933377) is a post-remand (legacy) that has been certified back to the Board and is ready for a decision. I'm not sure why it went through hearing branch, which assigned it to Caseflow. We attempted several times to arrange for a hearing, but the Veteran is incarcerated for life and the facility would not cooperate with us. The Veteran asked us to proceed with a Board decision. This case should ultimately go back to VLJ Scire, since he did the previous decision, but I'm not sure how to get it there. Let me know if you'd like me to ask a VACOLS person for help.

This one (https://appeals.cf.ds.va.gov/queue/appeals/2741402) has a schedule hearing task, but that's not right. It needs to be assigned to VLJ Derek Brown, who held the hearing. Again, let me know if you can do this or if you need me to ask for help.

Last one (https://appeals.cf.ds.va.gov/queue/appeals/3263705) needs an admin action task. Are you able to assign it to VLJ Support with the "missing records in file" task? The notes should say "The case file review worksheet references two Congressional emails dated 10/24/1018 and 5/16/2018, and states that these documents have been associated with the file. However, the Congressionals are not associated with the file or the VACOLS record. Please locate the Congressionals and upload them."

As far as I can tell with the VACOLS prior locations, it was previously with VLJ support, so that's why I want to send it back there. I don't understand how it got into the "CASEFLOW" location, but it does seem like VLJ Support was working the mail item, and it somehow got dropped.

Following up on this. The three appeals that @sharonwarner created hearing tasks for have fallen off our list of legacy appeals charged to CASEFLOW with no active tasks in Caseflow. However, one new case has been charged to CASEFLOW that does not have any tasks in Caseflow (VACOLS ID 3465431), so we have 8 legacy appeals that are "stuck".

Five appeals that we are waiting to hear back from the hearings branch about what the VACOLS location code should be:

Pending action from the Caseflow team:

Legacy appeal charged to CASEFLOW with no active tasks, new since last week:

https://appeals.cf.ds.va.gov/queue/appeals/3933377
@laurjpeterson I can go ahead and charge that appeal to VLJ Scire today if that's okay with you?

  • go for it!

https://appeals.cf.ds.va.gov/queue/appeals/3263705
Related to this comment, who should this be sent to after VLJ support has completed the required work on it? Case storage maybe? I can go ahead and create the tasks in Caseflow after we know where this should go after VLJ support has completed their work.

  • Unfortunately I don't have VACOLS right now so I can't check prior locations. Do you know if this was at an attorney before it went to VLJ Support the first time?

https://appeals.cf.ds.va.gov/queue/appeals/3465431
Appears to have been manually charged to CASEFLOW by a member of the mail team last week. @laurjpeterson can we reach out to the mail team to see how/why this happened?

  • yes, I'll do this

Charged legacy appeal VACOLS ID 3933377 to VLJ Scire.

Do you know if this was at an attorney before it went to VLJ Support the first time?

As far as I can tell, legacy appeal VACOLS ID 3263705 has never been assigned to an attorney. According to our list of VACOLS locations the previous locations for the appeal are as follows:

[[Mon, 25 Feb 2019, "CASEFLOW"],
     [Thu, 14 Feb 2019, "11"],         # VLJ admin 
     [Thu, 14 Feb 2019, "VACOHARPEJ"], # Real person but not on any teams in Caseflow, no VACOLS roles.
     [Mon, 11 Feb 2019, "82"],         # Paralegal Case Review
     [Wed, 02 Jan 2019, "81"],         # Central Case Storage
     [Thu, 28 Dec 2017, "03"],         # Pending Review Caseflow
     [Tue, 19 Jan 2016, "77"]]         # Advance

@laurjpeterson do we have any updates on these cases?

Delayed.

Emailed mail folks about https://appeals.cf.ds.va.gov/queue/appeals/3465431

For legacy appeal VACOLS ID 3263705 - it seems like this case is at VLJ Support / or the paralegal situation for admin action. I'll reach out to Corey and see if we should charge it back to Location 11.

This appeal - https://appeals.cf.ds.va.gov/queue/appeals/3465431 - can go to location 81.

Changed VACOLS location code for 3465431 to 81.

  rails c> appeal = LegacyAppeal.find_by(vacols_id: 3465431)
  rails c> appeal.location_code
  # "CASEFLOW"
  rails c> vacols_case = VACOLS::Case.find(appeal.vacols_id)
  rails c> prior_locs = vacols_case.priorloc
  rails c> prior_locs.order(:locdin).reverse.pluck(:locdout, :locstto, :locstrcv)
  # [[Wed, 26 Jun 2019, "CASEFLOW", nil],
     [Wed, 26 Jun 2019, "01", "LMAIDEN"],
     [Thu, 29 Dec 2016, "77", "LMAIDEN"]]
  rails c> AppealRepository::update_location!(appeal, 81)
  rails c> prior_locs = vacols_case.priorloc
  rails c> prior_locs.order(:locdin).reverse.pluck(:locdout, :locstto, :locstrcv)
  # [[Fri, 12 Jul 2019, "81", nil],
     [Wed, 26 Jun 2019, "CASEFLOW", "DSUSER"],
     [Wed, 26 Jun 2019, "01", "LMAIDEN"],
     [Thu, 29 Dec 2016, "77", "LMAIDEN"]]

There are still 6 lost cases charged to CASEFLOW in VACOLS. Five appeals that we are waiting to hear back from the hearings branch about what the VACOLS location code should be:

And one appeal that we are waiting to hear back from VLJ Support about whether we should charge this case back to VACOLS location code 11.

Corey got back to me. He asked Jed to do an override charge or this appeal (https://appeals.cf.ds.va.gov/queue/appeals/3263705), because it should have been in location 83. There is nothing our team needs to do for this case anymore.


There are still 5 lost cases charged to CASEFLOW in VACOLS. Five appeals that we are waiting to hear back from the hearings branch about what the VACOLS location code should be:

https://appeals.cf.ds.va.gov/queue/appeals/2703865
https://appeals.cf.ds.va.gov/queue/appeals/2766060
https://appeals.cf.ds.va.gov/queue/appeals/2891584
https://appeals.cf.ds.va.gov/queue/appeals/3107555
https://appeals.cf.ds.va.gov/queue/appeals/3228567

re: these. Premal and I set up time with the Hearing Branch today and they did not show up. We will have to try again.

Two legacy appeals were charged to the CASEFLOW VACOLS location without a corresponding Caseflow task being created in the past week (investigation below):

@laurjpeterson Can we confirm that both of these cases were manually charged to CASEFLOW? If they were can we try to figure out _why_ they were? What were these folks trying to accomplish? (Also, if they were manually charged to CASEFLOW in VACOLS, can we ask Jed to prevent location codes from being manually changed to CASEFLOW in VACOLS?).

- https://dsva.slack.com/archives/C4JECDLSE/p1563906758007800
  rails c> stuck_appeals = LegacyAppeal.where(id: [25783, 54167, 346504, 466301, 557722, 761769, 845864])
  rails c> stuck_appeals.pluck(:vacols_id)
  # ["3107555", "3228567", "2766060", "3183219", "2891584", "2703865", "3965597"]
  # 3183219 and 3965597 are new
  rails c> newly_stuck_vacols_ids = [3183219, 3965597]
  rails c> newly_stuck_appeals = LegacyAppeal.where(vacols_id: newly_stuck_vacols_ids)
  # Let's dig into the first one.
  rails c> newly_stuck_appeals.first.tasks
  # One root task. No other tasks. Let's look at the prior locations
  rails c> first_vacols_case = VACOLS::Case.find(newly_stuck_appeals.first.vacols_id)
  rails c> prior_locs = first_vacols_case.priorloc
  # locdout (location check out date)
  # locstto (recipient of case)
  # locstout (sender of case)
  rails c> pp prior_locs.order(:locdin).reverse.pluck(:locdout, :locstto, :locstout)
  # [[Tue, 23 Jul 2019, "CASEFLOW", "JWAGNER"],
     [Tue, 23 Jul 2019, "VACOCARTES1", "JWAGNER"],
     [Tue, 23 Jul 2019, "CASEFLOW", "VACOCARTES1"],
     [Tue, 23 Jul 2019, "57", "VACOCARTES1"],
     [Tue, 16 Jul 2019, "38", "VACOUNSELL"],
     [Fri, 22 Feb 2019, "57", "VACONAUMOA"],
     [Fri, 22 Feb 2019, "01", "VACONAUMOA"],
     [Thu, 14 Feb 2019, "78", "IMBUTLER"],
     [Wed, 02 Sep 2015, "77", "RO62"]]
  # Interesting! It looks like this was charged back to CASEFLOW for some reason.
  # Was this done automatically or by Jed/ Shannon Johnson?

  # On to the second one.
  rails c> newly_stuck_appeals.second.tasks
  # No tasks.
  rails c> second_vacols_case = VACOLS::Case.find(newly_stuck_appeals.second.vacols_id)
  rails c> prior_locs = second_vacols_case.priorloc
  # locdout (location check out date)
  # locstto (recipient of case)
  # locstout (sender of case)
  rails c> pp prior_locs.order(:locdin).reverse.pluck(:locdout, :locstto, :locstout)
  # [[Tue, 16 Jul 2019, "CASEFLOW", "TCASEY"],
     [Fri, 12 Jul 2019, "ESTRUENING", "MELARKIN"],
     [Mon, 08 Jul 2019, "MELARKIN", "MELARKIN"],
     [Mon, 08 Jul 2019, "81", "MCARTER"],
     [Mon, 08 Jul 2019, "01", "MCARTER"]]
  # Looks like Theophilos Casey (a judge) manually charged this case to CASEFLOW.

Premal reached out to hearing branch again today about the hearing ones.

I've emailed both Theo and Jed about the above cases, plus the question about preventing users from charging cases to the CASEFLOW location in VACOLS.

We've received a response about one of the two new cases. That case was manually charged to CASEFLOW in VACOLS. I'm inclined to ask Jed to add a control in the VACOLS UIs to prevent manual charging of cases to CASEFLOW so that cases only get charged to CASEFLOW in VACOLS when the Caseflow application changes their location. Before we make that request though, are there any legitimate reasons Caseflow expects folks to manually change the VACOLS location code to CASEFLOW?

(Related Slack conversation where Anya affirms my suspicion that Caseflow does not expect cases to be manually charged to CASEFLOW in VACOLS).


  • I've asked Theo Casey (Supervisory Senior Counsel) if we can move this case - https://appeals.cf.ds.va.gov/queue/appeals/3965597 - back to the attorney, so they can create an admin action that gets assigned to VLJ Support and it gets into CASEFLOW that way.

    • Confirmed! Back to ESTRUENING works. Thanks!

  • There are still 5 lost cases charged to CASEFLOW in VACOLS. Five appeals that we are waiting to hear back from the hearings branch about what the VACOLS location code should be:

https://appeals.cf.ds.va.gov/queue/appeals/2703865
https://appeals.cf.ds.va.gov/queue/appeals/2766060
https://appeals.cf.ds.va.gov/queue/appeals/2891584
https://appeals.cf.ds.va.gov/queue/appeals/3107555
https://appeals.cf.ds.va.gov/queue/appeals/3228567

Just got confirmation from the hearings branch that the 5 appeals listed above need to be moved into location 57.

Just charged the 5 legacy appeals above to location 57. Going to close this ticket out!

  # Confirm that each of these cases are all still charged to CASEFLOW.
  rails c> vacols_ids = [2703865, 2766060, 2891584, 3107555, 3228567]
  rails c> vacols_ids.each do |vacols_id| 
    prior_locs = VACOLS::Case.find(vacols_id).priorloc
    pp prior_locs.order(:locdin).reverse.pluck(:locdout, :locstto, :locstout)
  end
  # Yup. All still charged to CASEFLOW.
  # Now let's charge them back to location 57.
  rails c> vacols_ids.each do |vacols_id|
    appeal = LegacyAppeal.find_by(vacols_id: vacols_id)
    AppealRepository::update_location!(appeal, LegacyAppeal::LOCATION_CODES[:schedule_hearing])
  end
  # Are they all charged to 57 now?
  rails c> vacols_ids.each do |vacols_id| 
    prior_locs = VACOLS::Case.find(vacols_id).priorloc
    pp prior_locs.order(:locdin).reverse.pluck(:locdout, :locstto, :locstout)
  end
  # Yup!
Was this page helpful?
0 / 5 - 0 ratings