Configuration core.entity_view_display.paragraph.nested.default depends on the field.field.paragraph.nested.layout_builder__layout configuration that will not exist after import.

Created on 20 January 2023, over 1 year ago
Updated 23 January 2023, over 1 year ago

Problem/Motivation

Two 9.5.0 Drupal systems. Almost identical. Trying to import a view from one to the other. Import fails with:

Configuration core.entity_view_display.paragraph.nested.default depends on the field.field.paragraph.nested.layout_builder__layout configuration that will not exist after import.

I compared the paragraphs nested field from the source with the destination, and I cannot discern any difference whatsoever. The layout builder isn't even selected for this field!

I cannot delete the configuration from the config file (which I've seen as a common suggestion). Is there any way I can override this limitation without deleting the configuration?

I have attached the view in question.




There is one difference I can think of. The Destination site has two content types which reference the nested paragraph entity. The source site only has one. Would this make a difference? If so, how would I get around it?

I can't figure out, for the life of me, what the layout builder even has to do with this view!

πŸ’¬ Support request
Status

Fixed

Version

9.5

Component
ConfigurationΒ  β†’

Last updated 1 day ago

Created by

πŸ‡ΊπŸ‡ΈUnited States SomebodySysop

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡¦πŸ‡ΊAustralia larowlan πŸ‡¦πŸ‡ΊπŸ.au GMT+10

    This is saying it thinks you have layout builder for that view mode.
    If you don't, edit the yml file and remove the dependency on that field and try again.
    Drastic but safe to do if you know you don't use layout builder on that view mode.

  • πŸ‡ΊπŸ‡ΈUnited States SomebodySysop

    Excellent idea! But, how? There is no reference in the yml to paragraph, nested, layout or builder or configuration.

    I've looked at his code again and again and again, and I can't figure out how it even *knows* about layout builder when there doesn't appear to be anything in the yml file that references it!

    I tried removing the group and user module dependencies. No change. I even removed the language contexts. Nothing.

    Layout builder *is* on both the source and destination sites, and I did find this:

    Since the base table is groups_field_data, perhaps this has something to do with it? But, the nested paragraph is not associated with this view at all. Arrrrrggghhhh!!!!

    Oh yes, I'm trying to import it as a view. Should I try view mode?

    uuid: fa8d93c8-d171-4532-9fd8-7c3cca7912bc
    langcode: en
    status: true
    dependencies:
      module:
        - group
        - user
    id: user_groups
    label: 'User groups'
    module: views
    description: 'Shows all of the groups a user is part of'
    tag: ''
    base_table: groups_field_data
    base_field: id
    display:
      default:
        id: default
        display_title: Master
        display_plugin: default
        position: 0
        display_options:
          title: 'User groups'
          fields:
            label:
              id: label
              table: groups_field_data
              field: label
              relationship: none
              group_type: group
              admin_label: ''
              entity_type: null
              entity_field: label
              plugin_id: field
              label: Group(s)
              exclude: false
              alter:
                alter_text: false
                text: ''
                make_link: false
                path: ''
                absolute: false
                external: false
                replace_spaces: false
                path_case: none
                trim_whitespace: false
                alt: ''
                rel: ''
                link_class: ''
                prefix: ''
                suffix: ''
                target: ''
                nl2br: false
                max_length: 0
                word_boundary: true
                ellipsis: true
                more_link: false
                more_link_text: ''
                more_link_path: ''
                strip_tags: false
                trim: false
                preserve_tags: ''
                html: false
              element_type: ''
              element_class: ''
              element_label_type: ''
              element_label_class: ''
              element_label_colon: false
              element_wrapper_type: ''
              element_wrapper_class: ''
              element_default_classes: true
              empty: ''
              hide_empty: false
              empty_zero: false
              hide_alter_empty: true
              click_sort_column: value
              type: string
              settings:
                link_to_entity: true
              group_column: value
              group_columns: {  }
              group_rows: true
              delta_limit: 0
              delta_offset: 0
              delta_reversed: false
              delta_first_last: false
              multi_type: separator
              separator: ', '
              field_api_classes: false
            user_roles_field:
              id: user_roles_field
              table: views
              field: user_roles_field
              relationship: none
              group_type: group
              admin_label: ''
              plugin_id: user_roles_field
              label: Role(s)
              exclude: false
              alter:
                alter_text: false
                text: ''
                make_link: false
                path: ''
                absolute: false
                external: false
                replace_spaces: false
                path_case: none
                trim_whitespace: false
                alt: ''
                rel: ''
                link_class: ''
                prefix: ''
                suffix: ''
                target: ''
                nl2br: false
                max_length: 0
                word_boundary: true
                ellipsis: true
                more_link: false
                more_link_text: ''
                more_link_path: ''
                strip_tags: false
                trim: false
                preserve_tags: ''
                html: false
              element_type: ''
              element_class: ''
              element_label_type: ''
              element_label_class: ''
              element_label_colon: false
              element_wrapper_type: ''
              element_wrapper_class: ''
              element_default_classes: true
              empty: ''
              hide_empty: false
              empty_zero: false
              hide_alter_empty: false
          pager:
            type: none
            options:
              offset: 0
              items_per_page: 0
          exposed_form:
            type: basic
            options:
              submit_button: Apply
              reset_button: false
              reset_button_label: Reset
              exposed_sorts_label: 'Sort by'
              expose_sort_order: true
              sort_asc_label: Asc
              sort_desc_label: Desc
          access:
            type: perm
            options:
              perm: 'administer users'
          cache:
            type: tag
            options: {  }
          empty: {  }
          sorts:
            label:
              id: label
              table: groups_field_data
              field: label
              relationship: none
              group_type: group
              admin_label: ''
              entity_type: group
              entity_field: label
              plugin_id: standard
              order: ASC
              expose:
                label: ''
                field_identifier: ''
              exposed: false
          arguments:
            entity_id:
              id: entity_id
              table: group_content_field_data
              field: entity_id
              relationship: group_content_id
              group_type: group
              admin_label: 'Filter by user ID'
              entity_type: group_content
              entity_field: entity_id
              plugin_id: numeric
              default_action: 'not found'
              exception:
                value: all
                title_enable: false
                title: All
              title_enable: false
              title: ''
              default_argument_type: fixed
              default_argument_options:
                argument: ''
              default_argument_skip_url: false
              summary_options:
                base_path: ''
                count: true
                override: false
                items_per_page: 25
              summary:
                sort_order: asc
                number_of_records: 0
                format: default_summary
              specify_validation: true
              validate:
                type: 'entity:user'
                fail: 'access denied'
              validate_options:
                access: true
                operation: view
                multiple: 0
                restrict_roles: false
                roles: {  }
              break_phrase: false
              not: false
          filters: {  }
          style:
            type: table
            options:
              grouping: {  }
              row_class: ''
              default_row_class: true
              columns:
                label: label
                user_roles_field: user_roles_field
              default: '-1'
              info:
                label:
                  sortable: false
                  default_sort_order: asc
                  align: ''
                  separator: ''
                  empty_column: false
                  responsive: ''
                user_roles_field:
                  sortable: false
                  default_sort_order: asc
                  align: ''
                  separator: ''
                  empty_column: false
                  responsive: ''
              override: true
              sticky: false
              summary: ''
              empty_table: false
              caption: ''
              description: ''
          row:
            type: fields
          query:
            type: views_query
            options:
              query_comment: ''
              disable_sql_rewrite: false
              distinct: false
              replica: false
              query_tags: {  }
          relationships:
            group_content_id:
              id: group_content_id
              table: groups_field_data
              field: group_content_id
              relationship: none
              group_type: group
              admin_label: Membership
              entity_type: group
              plugin_id: group_to_group_content
              required: true
              group_content_plugins:
                group_membership: group_membership
          header: {  }
          footer: {  }
          display_extenders: {  }
        cache_metadata:
          max-age: -1
          contexts:
            - 'languages:language_content'
            - 'languages:language_interface'
            - url
            - user.permissions
          tags: {  }
      page_1:
        id: page_1
        display_title: Page
        display_plugin: page
        position: 1
        display_options:
          display_extenders: {  }
          path: user/%user/groups
          menu:
            type: tab
            title: Groups
            description: ''
            weight: 5
            expanded: false
            menu_name: account
            parent: ''
            context: '0'
        cache_metadata:
          max-age: -1
          contexts:
            - 'languages:language_content'
            - 'languages:language_interface'
            - url
            - user.permissions
          tags: {  }
  • πŸ‡ΊπŸ‡ΈUnited States SomebodySysop

    Relating this to this issue: https://www.drupal.org/project/drupal/issues/3335483 ✨ configuration override on single item imports Closed: works as designed

    If this sort of problem can't be solved logically, how about an option to override blocking of configurations which the import program incorrectly identifies as missing?

  • πŸ‡¦πŸ‡ΊAustralia larowlan πŸ‡¦πŸ‡ΊπŸ.au GMT+10

    So what has happened here is at some point the system you're trying to import into has gotten itself into a state where the configuration dependencies cannot be reconciled. Moving isolated pieces of content from one site to another isn't recommended, instead we expect you to sync a complete config set. However it sounds like you've started on this process, so we can try to help you reconcile it.

    It sounds like the default view mode for the nested paragraph type thinks it depends on layout builder, but it doesn't. Your best bet is to navigate to the 'manage display' tab for the nested paragraph type and save it, hopefully that is enough to fix the dependency issue. If that does fix it, then happy days.

    However, if that doesn't work, I'd suggest a complete export of your configuration on the site where you're trying to import, then find the file named core.entity_view_display.paragraph.nested.default.yml.

    Inside that file, it has a dependency on field.field.paragraph.nested.layout_builder__layout, remove that line and then try a complete import. Because you've been doing partial syncs, you may find there is another error, and it will likely be a process of working through them one by one. Feel free to keep posting updates here and we'll try to help.

  • πŸ‡ΊπŸ‡ΈUnited States SomebodySysop

    @larowlan

    It sounds like the default view mode for the nested paragraph type thinks it depends on layout builder, but it doesn't. Your best bet is to navigate to the 'manage display' tab for the nested paragraph type and save it, hopefully that is enough to fix the dependency issue. If that does fix it, then happy days.

    This absolutely worked! I just saved the existing "Manage display" config on the destination site and the import went through with no issues.

    Actually, there were three config errors on import. These were the other two:

    Configuration block.block.drupal8_w3css_subtheme_custombooknavigation depends on the Custom Book Block module that will not be installed after import.
    Configuration block.block.somebody_custombooknavigation depends on the Custom Book Block module that will not be installed after import.
    

    This made sense because the Custom Book Block module was installed but not enabled on the destination site. Enabling it solved those two issues. I was stymied by the fact that the layout builder configurations were exactly the same on the source and destination sites.

    This helps tremendously moving forward. Thank you so much!

  • πŸ‡ΊπŸ‡ΈUnited States SomebodySysop

    Forgot to give credit where credit was due!

  • Status changed to Fixed over 1 year ago
  • πŸ‡¦πŸ‡ΊAustralia larowlan πŸ‡¦πŸ‡ΊπŸ.au GMT+10

    πŸŽ‰πŸŽ‰

  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024