Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VACMS-14683: Updating service locations paragraph #15622

Merged
merged 27 commits into from
May 13, 2024

Conversation

swirtSJW
Copy link
Contributor

@swirtSJW swirtSJW commented Oct 10, 2023

Merge / launch planned for Monday 5/13. DO NOT MERGE PRIOR.

Description

Relates to #14683

This is a PR that is tracking the integration-service-location branch which contains work that can not go out until FE and CM have been done.

Note: To run the migration, but this in terminal: drush scr ./scripts/content/VACMS-15559-migrate-service-location-from-node-to-paragraph.php

To build the front end:
Which version of content-build would you like to use?
BRANCH VACMS-16144-VAMC-ServiceLocationParagraphs
Which version of vets-website would you like to use?
BRANCH main

Testing done

Screenshots

QA steps

What needs to be checked to prove this works?
What needs to be checked to prove it didn't break any related things?
What variations of circumstances (users, actions, values) need to be checked?

As user uid with user_role

  1. Do this
    • Validate that
  2. Then
    • Validate that
  3. Then validate Acceptance Criteria from issue
    • a
    • b
    • c

Definition of Done

  • Documentation has been updated, if applicable.
  • Tests have been added if necessary.
  • Automated tests have passed.
  • Code Quality Tests have passed.
  • Acceptance Criteria in related issue are met.
  • Manual Code Review Approved.

Select Team for PR review

  • CMS Team
  • Public websites
  • Facilities
  • User support
  • Accelerated Publishing

Is this PR blocked by another PR?

  • DO NOT MERGE

Does this PR need review from a Product Owner

  • Needs PO review

CMS user-facing announcement

Is an announcement needed to let editors know of this change?

  • Yes, and it's written in issue ____ and queued for publication.
    • Merge and ping the UX writer so they are ready to publish after deployment
  • Yes, but it hasn't yet been written
    • Don't merge yet -- ping the UX writer to write and queue content
  • No announcement is needed for this code change.
    • Merge & carry on unburdened by announcements

@va-cms-bot va-cms-bot temporarily deployed to Tugboat October 10, 2023 14:16 Destroyed
@swirtSJW swirtSJW added Facilities Facilities products (VAMC, Vet Center, etc) DO NOT MERGE Do not merge this PR Awaiting Official Launch Code is approved and ready for merge, but needs a launch. VBA for VBA facilities that are not Regional Offices labels Oct 10, 2023
@va-cms-bot va-cms-bot temporarily deployed to Tugboat October 13, 2023 19:34 Destroyed
@va-cms-bot va-cms-bot temporarily deployed to Tugboat October 24, 2023 19:28 Destroyed
@va-cms-bot va-cms-bot temporarily deployed to Tugboat October 26, 2023 13:47 Destroyed
@davidmpickett davidmpickett added the VAMC CMS managed product owned by Facilities team label Nov 20, 2023
@va-cms-bot va-cms-bot temporarily deployed to Tugboat November 29, 2023 23:27 Destroyed
@va-cms-bot va-cms-bot temporarily deployed to Tugboat January 10, 2024 21:57 Destroyed
@swirtSJW
Copy link
Contributor Author

I am rebasing the integration branch.
You will need to use

git fetch --all 
git reset --hard upstream/integration-service-location 

@swirtSJW swirtSJW force-pushed the integration-service-location branch from b83f4ce to c0d2253 Compare January 18, 2024 19:37
@swirtSJW swirtSJW force-pushed the integration-service-location branch from d5fa239 to bab50cc Compare January 29, 2024 20:41
@va-cms-bot va-cms-bot temporarily deployed to Tugboat February 3, 2024 00:39 Destroyed
@swirtSJW swirtSJW force-pushed the integration-service-location branch from beac8b6 to ad1c1e7 Compare February 3, 2024 02:51
@va-cms-bot va-cms-bot temporarily deployed to Tugboat February 3, 2024 02:51 Destroyed
@swirtSJW
Copy link
Contributor Author

swirtSJW commented Feb 3, 2024

I just touched off the migration on the Tugboat.

@swirtSJW
Copy link
Contributor Author

swirtSJW commented Feb 3, 2024

migration completed
image

@swirtSJW
Copy link
Contributor Author

This is likely going to have a conflict from the cherry-picked script-library that went out with the menu rearranging. I am not going to clear the conflict until after demo so we don't destroy any data in use by FE.

@swirtSJW swirtSJW force-pushed the integration-service-location branch from ad1c1e7 to fa2f54b Compare February 14, 2024 03:36
@va-cms-bot va-cms-bot temporarily deployed to Tugboat February 14, 2024 03:37 Destroyed
@va-cms-bot va-cms-bot temporarily deployed to Tugboat February 14, 2024 06:07 Destroyed
Copy link
Contributor Author

@swirtSJW swirtSJW left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@omahane and @Becapa I left a couple notes on adjustments that will be needed based on changes in #17236

Comment on lines 39 to 42
$batch_size = 25;
$node_storage = get_node_storage();
$nids = array_slice($sandbox['items_to_process'], 0, $batch_size, TRUE);
$facility_services = (empty($nids)) ? [] : $node_storage->loadMultiple(array_values($nids));
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@omahane and @Becapa Because of the new state keeping logic in #17236 this will likely fall apart a bit because the state is tracking per item, not per batch.
The state does not know how to reference which batch of 25 was just finished and would not really be able to pick up where it left off. Also the output would likely be jibberish.

I suggest this be changed to remove the batch size and just grab the top item in the array. Something like this. (not tested)

Suggested change
$batch_size = 25;
$node_storage = get_node_storage();
$nids = array_slice($sandbox['items_to_process'], 0, $batch_size, TRUE);
$facility_services = (empty($nids)) ? [] : $node_storage->loadMultiple(array_values($nids));
$node_storage = get_node_storage();
$nid_to_load = reset($sandbox['items_to_process']);
$facility_services = (empty($nid_to_load)) ? [] : $node_storage->loadMultiple(array_values($nid_to_load));

$node_storage = get_node_storage();
$nids = array_slice($sandbox['items_to_process'], 0, $batch_size, TRUE);
$facility_services = (empty($nids)) ? [] : $node_storage->loadMultiple(array_values($nids));
foreach ($facility_services as $nid => $facility_service_node) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This foreach is no longer needed since there is only one node in $facility_services, but it would require a lot more shifting of logic to unwrap it than is probably necessary to get this working with the state keeping logic and way more than I can do in a PR suggestion.

@va-cms-bot va-cms-bot temporarily deployed to Tugboat May 1, 2024 20:04 Destroyed
@jilladams jilladams changed the title VACMS-14683: Updating service locations paragraph DO NOT MERGE: VACMS-14683: Updating service locations paragraph May 6, 2024
@va-cms-bot va-cms-bot temporarily deployed to Tugboat May 6, 2024 18:03 Destroyed
@jilladams
Copy link
Contributor

jilladams commented May 6, 2024

As of today:

FYI @dsasser @omahane

@jilladams jilladams marked this pull request as ready for review May 6, 2024 18:16
@jilladams jilladams requested review from a team as code owners May 6, 2024 18:16
@jilladams jilladams requested a review from dsasser May 6, 2024 18:16
@va-cms-bot va-cms-bot temporarily deployed to Tugboat May 6, 2024 18:59 Destroyed
Copy link

github-actions bot commented May 6, 2024

GitHub Workflows (.github/workflows/*.yml)

Have you...

  • pinned all affected GitHub Actions at a specific commit by SHA?
  • reviewed the source code of the action at the commit you are pinning?
  • confirmed that no GitHub security measures are being bypassed?
  • checked for any injection of user content into protected contexts?
  • reviewed Security hardening for GitHub Actions?
  • reviewed GitHub Workflows?

* Reverts unwanted composer.lock changes.

* VACMS-14683: Reverts unwanted changes to default-branch-datadog-metrics.yml.
@va-cms-bot va-cms-bot temporarily deployed to Tugboat May 7, 2024 17:45 Destroyed
Copy link
Contributor

@dsasser dsasser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes look great, nice work @omahane!

@jilladams
Copy link
Contributor

@department-of-veterans-affairs/platform-cms-devops-engineers FYI that this PR is ready for review if anyone would like to take a look. We will merge next Monday 5/13 for Monday daily deploy.

After deploy, that'll be the trigger to run the related production script we've been talking to Grace / Tyler about. (cc @gracekretschmer-metrostar)

Copy link

@maxx1128 maxx1128 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a lot of unfamiliar files and languages for me, but I looked through everything and didn't see any red flags or worrying signs. Glad that the merge conflicts get removed 👍

Copy link
Contributor

@7hunderbird 7hunderbird left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Thanks!

@va-cms-bot va-cms-bot temporarily deployed to Tugboat May 13, 2024 12:53 Destroyed
@va-cms-bot va-cms-bot temporarily deployed to Tugboat May 13, 2024 14:29 Destroyed
@omahane omahane merged commit 1c22838 into main May 13, 2024
19 checks passed
@omahane omahane deleted the integration-service-location branch May 13, 2024 16:04
@omahane omahane changed the title DO NOT MERGE: VACMS-14683: Updating service locations paragraph VACMS-14683: Updating service locations paragraph May 13, 2024
@omahane
Copy link
Contributor

omahane commented May 13, 2024

Last minute ministrations around merging on Slack.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Official Launch Code is approved and ready for merge, but needs a launch. DO NOT MERGE Do not merge this PR Facilities Facilities products (VAMC, Vet Center, etc) VAMC CMS managed product owned by Facilities team VBA for VBA facilities that are not Regional Offices
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants