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

Determine whether exclusion types form is necessary and fix if so #3954

Closed swirtSJW closed 1 year ago

swirtSJW commented 3 years ago

Original Background

Describe the defect

This form is suppose to provide the source of truth as to which content types do not have a front end presence. https://prod.cms.va.gov/admin/config/content/exclusion-types-form

Example "CMS Help Page" should be checked off as it does not exist in the front end build.

However the file config/sync/exclusion_types_admin.settings.yml that should house that data does not exist AND when you add it by configuring the UI, and drush cex and then try to import the changes, the following error occurs

10:41:47 » lando drush cim

 Collection  Config                          Operation                
             exclusion_types_admin.settings  create
Import the listed configuration changes? (y/n): y
Drupal\Core\Config\ConfigImporterException: There were errors validating the config synchronization.                                                                                                                                                 [error]
Configuration <em class="placeholder">exclusion_types_admin.settings</em> depends on the <em class="placeholder">exclusion_types_admin</em> extension that will not be installed after import. in Drupal\Core\Config\ConfigImporter->validate() (line
755 of /app/docroot/core/lib/Drupal/Core/Config/ConfigImporter.php).
The import failed due for the following reasons:                                                                                                                                                                                                     [error]
Configuration <em class="placeholder">exclusion_types_admin.settings</em> depends on the <em class="placeholder">exclusion_types_admin</em> extension that will not be installed after import.

This has caused the data to be lost.

To Reproduce

Steps to reproduce the behavior:

  1. Go to '/admin/config/content/exclusion-types-form'
  2. Check off "CMS Help Page"
  3. Save the form
  4. lando drush cex
  5. lando drush cim
  6. See error on import. Import does not occur.

Expected behavior

The appropriate data is added and persists across environments.

Additional context

The config name needs to change to va_gov_backend.exclusion_types

Description

Once #5069 has been completed and a single service for determining whether a node is a page is available, the exclusion types form should be removed if it has been made redundant, or updated to work with the new service if not.

Acceptance Criteria

indytechcook commented 3 years ago

Depending on what happens with #5068 this issue might be closed. For example, we might hard code the list in code instead of it being in config.

TheBoatyMcBoatFace commented 1 year ago

Closing due to inactivity and priority. Reopen if needed.