department-of-veterans-affairs / va.gov-cms

Editor-centered management for Veteran-centered content.
https://prod.cms.va.gov
GNU General Public License v2.0
97 stars 69 forks source link

9/19/2024 Content Deploy Failures #19266

Open gracekretschmer-metrostar opened 2 weeks ago

gracekretschmer-metrostar commented 2 weeks ago

User Story or Problem Statement

Content Build's content deploy process is failing due to an unknown reason. The root cause needs to be identified and addressed before content goes 4 hours without being deployed to VA.gov.

Description or Additional Context

Around 12:00pm EST, content build began to fail during the content deploy process, around 10 minutes into the process.

Tim identified the error as this:

`TypeError: Cannot read property 'value' of undefined
    at /home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/health-care-region.js:247:6
    at Array.sort (<anonymous>)
    at eventDateSorter (/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/health-care-region.js:244:31)
    at addPager (/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/health-care-region.js:280:37)
    at pipeDrupalPagesIntoMetalsmith (/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/metalsmith-drupal.js:87:9)
    at Ware.<anonymous> (/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/metalsmith-drupal.js:402:7)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
Failed to pipe Drupal content into Metalsmith!
/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/plugins/download-assets.js:11
  throw up;
  ^

TypeError: Cannot read property 'value' of undefined
    at /home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/health-care-region.js:247:6
    at Array.sort (<anonymous>)
    at eventDateSorter (/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/health-care-region.js:244:31)
    at addPager (/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/health-care-region.js:280:37)
    at pipeDrupalPagesIntoMetalsmith (/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/metalsmith-drupal.js:87:9)
    at Ware.<anonymous> (/home/runner/runner3/_work/content-build/content-build/content-build/src/site/stages/build/drupal/metalsmith-drupal.js:402:7)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
error Command failed with exit code 1.`

Per Tim: This points to potentially faulty data coming from the CMS. The Javascript is trying to act on data that is missing from what graphQL has pulled down. It does not look like a total failure of pulling graphQL. Initially, this looks like a problem with Events that were published or updated between 10:53 and 11:51 ET.

Relevant Links

Steps for Implementation

Acceptance Criteria

edmund-dunn commented 2 weeks ago

An editor created an event at https://prod.cms.va.gov/west-palm-beach-health-care/events/72882 without a date or time. I archived the event and added an arbitrary date and time because I had to in order to save it. Content-build broke because ti sorts on the date field and for this event there was no date.