首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >导入配置时出错

导入配置时出错
EN

Drupal用户
提问于 2021-02-11 08:37:57
回答 1查看 1.4K关注 0票数 0

我们有几个与Drupal一起运行的站点。

在本地机器上,我在Docker容器中运行每个站点的测试版本,以添加新特性或测试新特性。

在页面之间切换时,我执行以下操作。

关闭页面的容器-A。

切换到页-B的目录,启动容器。

然后在容器中的终端中执行以下命令:

代码语言:javascript
复制
composer clearcache
composer install
drush sql-drop --yes; 
drush sqlc < page-B_init.sql
drush updb
drush cim

运行drush cim时,将出现以下错误消息:

代码语言:javascript
复制
 [error]  Drupal\Core\Config\ConfigImporterException: There were errors validating the config synchronization.
Entity type mismatch on rename.  not equal to configurable_language for existing configuration system.site and staged configuration language.entity.en.
Rename operation for simple configuration. Existing configuration system.site and staged configuration language.entity.en. in Drupal\Core\Config\ConfigImporter->validate() (line 755 of /var/www/html/docroot/core/lib/Drupal/Core/Config/ConfigImporter.php).

In ConfigImportCommands.php line 261:

  The import failed due to the following reasons:
  Entity type mismatch on rename.  not equal to configurable_language for existing configuration system.site and staged configuration language.entity.en.
  Rename operation for simple configuration. Existing configuration system.site and staged configuration language.entity.en.

我怀疑问题在于UUID,我在文件中有:

代码语言:javascript
复制
environments/_default/config/sync/system.site.yml
environments/_default/config/sync/language.entity.en.yml

适应了。

但我已经不知道了。

有人知道错误在哪里吗?

使用Drupal 8.9.13

EN

回答 1

Drupal用户

发布于 2021-02-18 01:22:12

这可能不是最好的办法,但我今天也有同样的问题。最后,我将language.entity.en.yml重命名为在备份的文件名末尾包含.OLD,然后重新运行drush cim。之后,它接受了我的system.site.yml文件。然后,我查看了language.entity.en.yml文件,由于某种原因,它与system.site文件具有完全相同的UUID。我怀疑导入混淆了哪个文件是哪个文件,因为它们具有相同的UUID。

票数 1
EN
页面原文内容由Drupal提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://drupal.stackexchange.com/questions/300133

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档