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

BLT + Standard Profile Configuration Issues #4244

Closed
mikemadison13 opened this issue Sep 11, 2020 · 8 comments · Fixed by #4249
Closed

BLT + Standard Profile Configuration Issues #4244

mikemadison13 opened this issue Sep 11, 2020 · 8 comments · Fixed by #4249
Labels
11.x Affects or applies to 11.x 12.x Affects or applies to 12.x Bug Something isn't working

Comments

@mikemadison13
Copy link
Contributor

I should state right up front that this isn't necessarily a BLT bug. But I think we need a way to work around it.

Describe the bug
After spinning up a new site and exporting configuration the first time, config imports and updates fail immediately due to https://www.drupal.org/node/2583113

  The import failed due to the following reasons:                              
  Entities exist of type <em class="placeholder">Shortcut link</em> and <em c  
  lass="placeholder">Shortcut set</em> <em class="placeholder">Default</em>.   
  These entities need to be deleted before importing.  

To Reproduce
Steps to reproduce the behavior, ideally starting from a fresh install of BLT:

  1. Run composer create-project acquia/drupal-recommended-project --no-interaction
  2. Add drupal vm and setup a box
  3. SSH into the container
  4. Run blt setup:drupal:install -n
  5. export configuration w/ drush cex -y
  6. re-run blt setup:drupal:install -n

Expected behavior
Config Import will run

Detailed error output

blt setup
Setting up local environment for site default.
Using drush alias @self
> source:build
[warning] The active configuration is not identical to the configuration in the export directory.
[warning] This means that you have not exported all of your active configuration.
[warning] Run drush cex to export the active config to the sync directory.
[warning] Continuing will overwrite the active configuration.
 Continue? (y/n) y
> setup:behat
Generating Behat configuration files...
> source:build:composer
Gathering patches for root package.
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Nothing to install or update
Package container-interop/container-interop is abandoned, you should avoid using it. Use psr/container instead.
Generating autoload files
45 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
> blt:init:git-hooks
Installing pre-commit git hook...
Installing pre-push git hook...
Installing commit-msg git hook...
> blt:init:settings
Could not find blt/example.local.blt.yml/. Create and commit this file if you'd like to automatically generate blt/local.blt.yml/ based on this template.
Hash salt already exists.
> source:build:frontend
> source:build:frontend-reqs
> source:build:frontend-assets
> drupal:deployment-identifier:init
Generating deployment identifier...
> drupal:install
> internal:drupal:install
[Acquia\Blt\Robo\Tasks\DrushTask] Running /var/www/scenario/vendor/bin/drush @self site-install standard install_configure_form.enable_update_status_module=NULL --sites-subdir=default --site-name='My BLT site' --site-mail=no-reply@acquia.com --account-name='w4AL+95jdG' --account-mail=no-reply@acquia.com --locale=en -v --ansi in /var/www/scenario/docroot
 [info] Executing: command -v mysql
 [info] Executing: mysql --defaults-file=/tmp/drush_tYpKYk --database=drupal --host=localhost --port=3306 --silent -A < /tmp/drush_NQB8uL

 You are about to:
 * DROP all tables in your 'drupal' database.

 Do you want to continue? (yes/no) [yes]:
 > yes 

 [info] Sites directory sites/default already exists - proceeding.
 [info] Executing: mysql --defaults-file=/tmp/drush_ZAdktK --database=drupal --host=localhost --port=3306 --silent -A < /tmp/drush_XyT0I2
 [info] Executing: mysql --defaults-file=/tmp/drush_VsxA09 --database=drupal --host=localhost --port=3306 --silent -A < /tmp/drush_vZcWes
 [info] Executing: mysql --defaults-file=/tmp/drush_1KncAz --database=drupal --host=localhost --port=3306 --silent -A < /tmp/drush_xAGmNR
 [notice] Starting Drupal installation. This takes a while.
 [notice] Performed install task: install_select_language
 [notice] Performed install task: install_select_profile
 [notice] Performed install task: install_load_profile
 [notice] Performed install task: install_verify_requirements
 [notice] Performed install task: install_verify_database_ready
 [info] system module installed.
 [info] user module installed.
 [notice] Performed install task: install_base_system
 [notice] Performed install task: install_bootstrap_full
 [info] path_alias module installed.
 [info] help module installed.
 [info] field module installed.
 [info] tour module installed.
 [info] automated_cron module installed.
 [info] search module installed.
 [info] color module installed.
 [info] config module installed.
 [info] dblog module installed.
 [info] big_pipe module installed.
 [info] dynamic_page_cache module installed.
 [info] page_cache module installed.
 [info] rdf module installed.
 [info] file module installed.
 [info] filter module installed.
 [info] text module installed.
 [info] options module installed.
 [info] block module installed.
 [info] block_content module installed.
 [info] node module installed.
 [info] breakpoint module installed.
 [info] editor module installed.
 [info] ckeditor module installed.
 [info] comment module installed.
 [info] contact module installed.
 [info] contextual module installed.
 [info] datetime module installed.
 [info] field_ui module installed.
 [info] history module installed.
 [info] taxonomy module installed.
 [info] image module installed.
 [info] link module installed.
 [info] views module installed.
 [info] menu_link_content module installed.
 [info] menu_ui module installed.
 [info] path module installed.
 [info] quickedit module installed.
 [info] toolbar module installed.
 [info] shortcut module installed.
 [info] views_ui module installed.
 [notice] Performed install task: install_profile_modules
 [info] bartik theme installed.
 [info] seven theme installed.
 [notice] Performed install task: install_profile_themes
 [info] standard module installed.
 [notice] Performed install task: install_install_profile
 [notice] Performed install task: install_configure_form
 [notice] Cron run completed.
 [notice] Performed install task: install_finished
 [success] Installation complete.  User name: w4AL+95jdG  User password: tVqxrvJ7vE
[Acquia\Blt\Robo\Tasks\DrushTask] Done in 18.859s
> drupal:config:import
[Acquia\Blt\Robo\Tasks\DrushTask] Running /var/www/scenario/vendor/bin/drush @self config:set system.site uuid 8cdda79a-f19b-4c36-bbee-d24a5630f1da --no-interaction --ansi &&
 /var/www/scenario/vendor/bin/drush @self pm-enable config_split --no-interaction --ansi &&
 /var/www/scenario/vendor/bin/drush @self config-import sync --no-interaction --ansi &&
 /var/www/scenario/vendor/bin/drush @self config-import sync --no-interaction --ansi &&
 /var/www/scenario/vendor/bin/drush @self cache-rebuild --no-interaction --ansi in /var/www/scenario/docroot
The following module(s) will be enabled: config_split, config_filter
 [success] Successfully enabled: config_split, config_filter
+------------+------------------------------------------------------+-----------+
| Collection | Config                                               | Operation |
+------------+------------------------------------------------------+-----------+
|            | block.block.bartik_local_actions                     | Create    |
|            | block.block.bartik_local_tasks                       | Create    |
|            | block.block.bartik_page_title                        | Create    |
|            | block_content.type.basic                             | Create    |
|            | comment.type.comment                                 | Create    |
|            | core.date_format.fallback                            | Create    |
|            | core.date_format.html_date                           | Create    |
|            | core.date_format.html_datetime                       | Create    |
|            | core.date_format.html_month                          | Create    |
|            | core.date_format.html_time                           | Create    |
|            | core.date_format.html_week                           | Create    |
|            | core.date_format.html_year                           | Create    |
|            | core.date_format.html_yearless_date                  | Create    |
|            | core.date_format.long                                | Create    |
|            | core.date_format.medium                              | Create    |
|            | core.date_format.short                               | Create    |
|            | core.entity_view_mode.block_content.full             | Create    |
|            | core.entity_view_mode.comment.full                   | Create    |
|            | block.block.bartik_help                              | Create    |
|            | image.style.large                                    | Create    |
|            | image.style.medium                                   | Create    |
|            | image.style.thumbnail                                | Create    |
|            | field.storage.node.field_image                       | Create    |
|            | field.storage.node.comment                           | Create    |
|            | core.entity_view_mode.node.teaser                    | Create    |
|            | core.entity_view_mode.node.search_result             | Create    |
|            | core.entity_view_mode.node.search_index              | Create    |
|            | core.entity_view_mode.node.rss                       | Create    |
|            | core.entity_view_mode.node.full                      | Create    |
|            | node.type.article                                    | Create    |
|            | field.field.node.article.field_image                 | Create    |
|            | field.field.node.article.comment                     | Create    |
|            | node.type.page                                       | Create    |
|            | core.base_field_override.node.page.promote           | Create    |
|            | rdf.mapping.comment.comment                          | Create    |
|            | rdf.mapping.node.article                             | Create    |
|            | rdf.mapping.node.page                                | Create    |
|            | block.block.bartik_search                            | Create    |
|            | search.page.node_search                              | Create    |
|            | block.block.seven_secondary_local_tasks              | Create    |
|            | block.block.seven_primary_local_tasks                | Create    |
|            | block.block.seven_page_title                         | Create    |
|            | block.block.seven_local_actions                      | Create    |
|            | block.block.seven_help                               | Create    |
|            | block.block.seven_messages                           | Create    |
|            | block.block.seven_content                            | Create    |
|            | block.block.seven_breadcrumbs                        | Create    |
|            | block.block.bartik_powered                           | Create    |
|            | block.block.bartik_messages                          | Create    |
|            | block.block.bartik_content                           | Create    |
|            | block.block.bartik_breadcrumbs                       | Create    |
|            | block.block.bartik_branding                          | Create    |
|            | system.action.comment_delete_action                  | Create    |
|            | system.action.comment_publish_action                 | Create    |
|            | system.action.comment_save_action                    | Create    |
|            | system.action.comment_unpublish_action               | Create    |
|            | system.action.node_delete_action                     | Create    |
|            | system.action.node_make_sticky_action                | Create    |
|            | system.action.node_make_unsticky_action              | Create    |
|            | system.action.node_promote_action                    | Create    |
|            | system.action.node_publish_action                    | Create    |
|            | system.action.node_save_action                       | Create    |
|            | system.action.node_unpromote_action                  | Create    |
|            | system.action.node_unpublish_action                  | Create    |
|            | system.menu.account                                  | Create    |
|            | block.block.bartik_account_menu                      | Create    |
|            | system.menu.admin                                    | Create    |
|            | system.menu.footer                                   | Create    |
|            | block.block.bartik_footer                            | Create    |
|            | system.menu.main                                     | Create    |
|            | block.block.bartik_main_menu                         | Create    |
|            | system.menu.tools                                    | Create    |
|            | block.block.bartik_tools                             | Create    |
|            | system.action.taxonomy_term_unpublish_action         | Create    |
|            | system.action.taxonomy_term_publish_action           | Create    |
|            | field.storage.node.field_tags                        | Create    |
|            | core.entity_view_mode.taxonomy_term.full             | Create    |
|            | taxonomy.vocabulary.tags                             | Create    |
|            | rdf.mapping.taxonomy_term.tags                       | Create    |
|            | field.field.node.article.field_tags                  | Create    |
|            | field.storage.node.body                              | Create    |
|            | field.storage.comment.comment_body                   | Create    |
|            | field.storage.block_content.body                     | Create    |
|            | field.field.node.page.body                           | Create    |
|            | field.field.node.article.body                        | Create    |
|            | field.field.comment.comment.comment_body             | Create    |
|            | field.field.block_content.basic.body                 | Create    |
|            | core.entity_view_display.comment.comment.default     | Create    |
|            | core.entity_view_display.block_content.basic.default | Create    |
|            | core.entity_form_display.node.page.default           | Create    |
|            | core.entity_form_display.node.article.default        | Create    |
|            | core.entity_form_display.comment.comment.default     | Create    |
|            | core.entity_form_display.block_content.basic.default | Create    |
|            | system.action.user_unblock_user_action               | Create    |
|            | system.action.user_cancel_user_action                | Create    |
|            | system.action.user_block_user_action                 | Create    |
|            | search.page.user_search                              | Create    |
|            | rdf.mapping.user.user                                | Create    |
|            | field.storage.user.user_picture                      | Create    |
|            | field.field.user.user.user_picture                   | Create    |
|            | core.entity_view_mode.user.full                      | Create    |
|            | core.entity_view_mode.user.compact                   | Create    |
|            | core.entity_view_display.user.user.default           | Create    |
|            | core.entity_view_display.user.user.compact           | Create    |
|            | core.entity_view_display.node.page.teaser            | Create    |
|            | core.entity_view_display.node.page.default           | Create    |
|            | core.entity_view_display.node.article.teaser         | Create    |
|            | core.entity_view_display.node.article.rss            | Create    |
|            | core.entity_view_display.node.article.default        | Create    |
|            | core.entity_form_mode.user.register                  | Create    |
|            | core.entity_form_display.user.user.default           | Create    |
|            | user.role.administrator                              | Create    |
|            | system.action.user_remove_role_action.administrator  | Create    |
|            | system.action.user_add_role_action.administrator     | Create    |
|            | user.role.anonymous                                  | Create    |
|            | user.role.authenticated                              | Create    |
|            | views.view.archive                                   | Create    |
|            | views.view.block_content                             | Create    |
|            | views.view.comment                                   | Create    |
|            | views.view.comments_recent                           | Create    |
|            | views.view.content                                   | Create    |
|            | views.view.content_recent                            | Create    |
|            | views.view.files                                     | Create    |
|            | filter.format.basic_html                             | Create    |
|            | views.view.frontpage                                 | Create    |
|            | editor.editor.basic_html                             | Create    |
|            | views.view.glossary                                  | Create    |
|            | filter.format.full_html                              | Create    |
|            | views.view.taxonomy_term                             | Create    |
|            | editor.editor.full_html                              | Create    |
|            | views.view.user_admin_people                         | Create    |
|            | contact.form.feedback                                | Create    |
|            | filter.format.plain_text                             | Create    |
|            | views.view.watchdog                                  | Create    |
|            | contact.form.personal                                | Create    |
|            | filter.format.restricted_html                        | Create    |
|            | views.view.who_s_new                                 | Create    |
|            | shortcut.set.default                                 | Create    |
|            | tour.tour.views-ui                                   | Create    |
|            | views.view.who_s_online                              | Create    |
|            | core.extension                                       | Update    |
|            | views.view.who_s_online                              | Delete    |
|            | tour.tour.views-ui                                   | Delete    |
|            | shortcut.set.default                                 | Delete    |
|            | views.view.who_s_new                                 | Delete    |
|            | filter.format.restricted_html                        | Delete    |
|            | contact.form.personal                                | Delete    |
|            | views.view.watchdog                                  | Delete    |
|            | filter.format.plain_text                             | Delete    |
|            | contact.form.feedback                                | Delete    |
|            | views.view.user_admin_people                         | Delete    |
|            | editor.editor.full_html                              | Delete    |
|            | views.view.taxonomy_term                             | Delete    |
|            | filter.format.full_html                              | Delete    |
|            | views.view.glossary                                  | Delete    |
|            | editor.editor.basic_html                             | Delete    |
|            | views.view.frontpage                                 | Delete    |
|            | filter.format.basic_html                             | Delete    |
|            | views.view.files                                     | Delete    |
|            | views.view.content_recent                            | Delete    |
|            | views.view.content                                   | Delete    |
|            | views.view.comments_recent                           | Delete    |
|            | views.view.comment                                   | Delete    |
|            | views.view.block_content                             | Delete    |
|            | views.view.archive                                   | Delete    |
|            | user.role.authenticated                              | Delete    |
|            | user.role.anonymous                                  | Delete    |
|            | system.action.user_add_role_action.administrator     | Delete    |
|            | system.action.user_remove_role_action.administrator  | Delete    |
|            | user.role.administrator                              | Delete    |
|            | core.entity_form_display.user.user.default           | Delete    |
|            | core.entity_form_mode.user.register                  | Delete    |
|            | core.entity_view_display.node.article.default        | Delete    |
|            | core.entity_view_display.node.article.rss            | Delete    |
|            | core.entity_view_display.node.article.teaser         | Delete    |
|            | core.entity_view_display.node.page.default           | Delete    |
|            | core.entity_view_display.node.page.teaser            | Delete    |
|            | core.entity_view_display.user.user.compact           | Delete    |
|            | core.entity_view_display.user.user.default           | Delete    |
|            | core.entity_view_mode.user.compact                   | Delete    |
|            | core.entity_view_mode.user.full                      | Delete    |
|            | field.field.user.user.user_picture                   | Delete    |
|            | field.storage.user.user_picture                      | Delete    |
|            | rdf.mapping.user.user                                | Delete    |
|            | search.page.user_search                              | Delete    |
|            | system.action.user_block_user_action                 | Delete    |
|            | system.action.user_cancel_user_action                | Delete    |
|            | system.action.user_unblock_user_action               | Delete    |
|            | core.entity_form_display.block_content.basic.default | Delete    |
|            | core.entity_form_display.comment.comment.default     | Delete    |
|            | core.entity_form_display.node.article.default        | Delete    |
|            | core.entity_form_display.node.page.default           | Delete    |
|            | core.entity_view_display.block_content.basic.default | Delete    |
|            | core.entity_view_display.comment.comment.default     | Delete    |
|            | field.field.block_content.basic.body                 | Delete    |
|            | field.field.comment.comment.comment_body             | Delete    |
|            | field.field.node.article.body                        | Delete    |
|            | field.field.node.page.body                           | Delete    |
|            | field.storage.block_content.body                     | Delete    |
|            | field.storage.comment.comment_body                   | Delete    |
|            | field.storage.node.body                              | Delete    |
|            | field.field.node.article.field_tags                  | Delete    |
|            | rdf.mapping.taxonomy_term.tags                       | Delete    |
|            | taxonomy.vocabulary.tags                             | Delete    |
|            | core.entity_view_mode.taxonomy_term.full             | Delete    |
|            | field.storage.node.field_tags                        | Delete    |
|            | system.action.taxonomy_term_publish_action           | Delete    |
|            | system.action.taxonomy_term_unpublish_action         | Delete    |
|            | block.block.bartik_tools                             | Delete    |
|            | system.menu.tools                                    | Delete    |
|            | block.block.bartik_main_menu                         | Delete    |
|            | system.menu.main                                     | Delete    |
|            | block.block.bartik_footer                            | Delete    |
|            | system.menu.footer                                   | Delete    |
|            | system.menu.admin                                    | Delete    |
|            | block.block.bartik_account_menu                      | Delete    |
|            | system.menu.account                                  | Delete    |
|            | system.action.node_unpublish_action                  | Delete    |
|            | system.action.node_unpromote_action                  | Delete    |
|            | system.action.node_save_action                       | Delete    |
|            | system.action.node_publish_action                    | Delete    |
|            | system.action.node_promote_action                    | Delete    |
|            | system.action.node_make_unsticky_action              | Delete    |
|            | system.action.node_make_sticky_action                | Delete    |
|            | system.action.node_delete_action                     | Delete    |
|            | system.action.comment_unpublish_action               | Delete    |
|            | system.action.comment_save_action                    | Delete    |
|            | system.action.comment_publish_action                 | Delete    |
|            | system.action.comment_delete_action                  | Delete    |
|            | block.block.bartik_branding                          | Delete    |
|            | block.block.bartik_breadcrumbs                       | Delete    |
|            | block.block.bartik_content                           | Delete    |
|            | block.block.bartik_messages                          | Delete    |
|            | block.block.bartik_powered                           | Delete    |
|            | block.block.seven_breadcrumbs                        | Delete    |
|            | block.block.seven_content                            | Delete    |
|            | block.block.seven_messages                           | Delete    |
|            | block.block.seven_help                               | Delete    |
|            | block.block.seven_local_actions                      | Delete    |
|            | block.block.seven_page_title                         | Delete    |
|            | block.block.seven_primary_local_tasks                | Delete    |
|            | block.block.seven_secondary_local_tasks              | Delete    |
|            | search.page.node_search                              | Delete    |
|            | block.block.bartik_search                            | Delete    |
|            | rdf.mapping.node.page                                | Delete    |
|            | rdf.mapping.node.article                             | Delete    |
|            | rdf.mapping.comment.comment                          | Delete    |
|            | core.base_field_override.node.page.promote           | Delete    |
|            | node.type.page                                       | Delete    |
|            | field.field.node.article.comment                     | Delete    |
|            | field.field.node.article.field_image                 | Delete    |
|            | node.type.article                                    | Delete    |
|            | core.entity_view_mode.node.full                      | Delete    |
|            | core.entity_view_mode.node.rss                       | Delete    |
|            | core.entity_view_mode.node.search_index              | Delete    |
|            | core.entity_view_mode.node.search_result             | Delete    |
|            | core.entity_view_mode.node.teaser                    | Delete    |
|            | field.storage.node.comment                           | Delete    |
|            | field.storage.node.field_image                       | Delete    |
|            | image.style.thumbnail                                | Delete    |
|            | image.style.medium                                   | Delete    |
|            | image.style.large                                    | Delete    |
|            | block.block.bartik_help                              | Delete    |
|            | core.entity_view_mode.comment.full                   | Delete    |
|            | core.entity_view_mode.block_content.full             | Delete    |
|            | core.date_format.short                               | Delete    |
|            | core.date_format.medium                              | Delete    |
|            | core.date_format.long                                | Delete    |
|            | core.date_format.html_yearless_date                  | Delete    |
|            | core.date_format.html_year                           | Delete    |
|            | core.date_format.html_week                           | Delete    |
|            | core.date_format.html_time                           | Delete    |
|            | core.date_format.html_month                          | Delete    |
|            | core.date_format.html_datetime                       | Delete    |
|            | core.date_format.html_date                           | Delete    |
|            | core.date_format.fallback                            | Delete    |
|            | comment.type.comment                                 | Delete    |
|            | block_content.type.basic                             | Delete    |
|            | block.block.bartik_page_title                        | Delete    |
|            | block.block.bartik_local_tasks                       | Delete    |
|            | block.block.bartik_local_actions                     | Delete    |
+------------+------------------------------------------------------+-----------+
 [error]  Drupal\Core\Config\ConfigImporterException: There were errors validating the config synchronization.
Entities exist of type <em class="placeholder">Shortcut link</em> and <em class="placeholder">Shortcut set</em> <em class="placeholder">Default</em>. These entities need to be deleted before importing. in Drupal\Core\Config\ConfigImporter->validate() (line 748 of /var/www/scenario/docroot/core/lib/Drupal/Core/Config/ConfigImporter.php). 

In ConfigImportCommands.php line 357:
                                                                               
  The import failed due to the following reasons:                              
  Entities exist of type <em class="placeholder">Shortcut link</em> and <em c  
  lass="placeholder">Shortcut set</em> <em class="placeholder">Default</em>.   
  These entities need to be deleted before importing.                          
                                                                               

config:import [--preview [PREVIEW]] [--source SOURCE] [--partial] [--diff] [-h|--help] [-q|--quiet] [-v|vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction] [-d|--debug] [-y|--yes] [--no] [--remote-host REMOTE-HOST] [--remote-user REMOTE-USER] [-r|--root ROOT] [-l|--uri URI] [--simulate] [--pipe] [-D|--define DEFINE] [--notify [NOTIFY]] [--druplicon] [--xh-link XH-LINK] [--] <command> [<label>]

[Acquia\Blt\Robo\Tasks\DrushTask]  Exit code 1  Time 4.496s
[error]  Failed to import configuration!
For troubleshooting guidance and support, see https://docs.acquia.com/blt/support/ 
The command failed. This often indicates a problem with your configuration. Review the command output above for more detailed errors, and consider re-running with verbose output for more information.
[error]  Command `drupal:config:import ` exited with code 1.
For troubleshooting guidance and support, see https://docs.acquia.com/blt/support/ 
The command failed. This often indicates a problem with your configuration. Review the command output above for more detailed errors, and consider re-running with verbose output for more information.
[error]  Command `drupal:install ` exited with code 1.
For troubleshooting guidance and support, see https://docs.acquia.com/blt/support/ 

System information

  • Operating system type: Drupal VM / Ubuntu
  • BLT version: 12.3

Additional context
Based on what's going on, I think we have a few options:

  • use the install from existing config option: while this probably will work, it won't fix the issue on ACSF (as we can't install through the UI from existing config)
  • add a work around in BLT's config command to delete the default shortcuts (this could be hacky and dangerous but seems to work)
  • add a condition to our configuration diff that ignores shortcut diffs (again, perhaps a bit hacky but seems like a valid option for now?)
@mikemadison13 mikemadison13 added Bug Something isn't working 12.x Affects or applies to 12.x labels Sep 11, 2020
@mikemadison13
Copy link
Contributor Author

Update:
this seems to be happening because BLT 12 is now defaulting to the standard profile instead of lightning. See https://github.com/acquia/blt/blob/12.x/config/build.yml#L134

Updating / overriding this to use lightning instead of standard makes this a non-issue.

Is there a reason that we ship Lightning w/ the recommended project but install standard by default in BLT 12? Again, I think if this was exposed in blt.yml it would be much more obvious.

@mikemadison13 mikemadison13 changed the title BLT 12 Configuration Workflow Broken BLT + Standard Profile Configuration Issues Sep 15, 2020
@mikemadison13 mikemadison13 added the 11.x Affects or applies to 11.x label Sep 15, 2020
@mikemadison13
Copy link
Contributor Author

choices are:

use lightning (not standard)
allow config-overrides

@justclint
Copy link

Thanks @mikemadison13. Regarding the config-override, Im assuming this would be adding to our settings.php something like:

$config['shortcut.set.default']['key'] = 'something';

Unfortunately we cant remove the actual links since those arent in config so what exactly would we be overriding in this case?

@mikemadison13
Copy link
Contributor Author

no, i would do this in the blt.yml file:

cm:
  allow-overrides: true

@mikemadison13
Copy link
Contributor Author

you could also grab the lightning "fix" for these to iterate through and delete the shortcuts on install: https://github.com/acquia/lightning/blob/5.0.x/lightning.install#L41

@justclint
Copy link

gotcha, now that im looking at another blt project or ours we are using that allow-overrides setting. In this case what worked was that setting plus I had to change the uuid on shortcut.set.default.yml to null.

@danepowell
Copy link
Contributor

danepowell commented Sep 21, 2020

I don't see any way for BLT to solve this, it's a perennial bug with the Drupal config management system (or the standard install profile, however you prefer to look at it). The problem is that many profiles dynamically create content (such as shortcuts) that will generally have different UUIDs than whatever's stored in your config on disk, and so Drupal refuses to import your version from disk.

The only surefire solutions are to use a more well-behaved profile that doesn't dynamically generate config, or install from config (bypassing profile hook_installs).

Is there a reason that we ship Lightning w/ the recommended project but install standard by default in BLT 12?

Because BLT 12 can be added to any distribution, many of which aren't Lightning. The only safe defaults are profiles available in Drupal core, i.e. standard. Even if we change this back to Lightning (not a trivial ask btw, we'd need to dynamically set it in blt.yml during composer installs of BLT) it leaves non-Lightning users in the lurch.

@mikemadison13
Copy link
Contributor Author

i'm fine not doing lightning, but i don't think we can do standard either (unless we want to start shipping a fix for standard, which i agree isn't in our scope). how do you feel about minimal? maybe this isn't an issue there.

all i know is that out of the box our recommended config strategy doesn't work because of our own default settings and the way standard works. that's not cool!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
11.x Affects or applies to 11.x 12.x Affects or applies to 12.x Bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants