【问题标题】:Magento 2.3.5 fresh installtion using composer results in errorMagento 2.3.5 全新安装使用 composer 导致错误
【发布时间】:2021-09-20 19:40:49
【问题描述】:

我正在尝试使用 composer 安装 Magento 2.3.5。

muk@muk:/var/www/html$ composer create-project --repository-url=https://repo.magento.com/magento/project-community-edition=2.3.5 magento23

Creating a "magento/project-community-edition" project at "./magento23"
Installing magento/project-community-edition (2.3.5-p1)
  - Installing magento/project-community-edition (2.3.5-p1): Loading from cache
Created project in /var/www/html/magento23
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 463 installs, 0 updates, 0 removals
  - Installing magento/magento-composer-installer (0.1.13): Loading from cache
  - Installing laminas/laminas-dependency-plugin (1.0.3): Loading from cache
Plugin installation failed (include(/var/www/html/magento23/vendor/laminas/laminas-dependency-plugin/src/DependencyRewriterPlugin.php): failed to open stream: No such file or directory), rolling back
  - Removing laminas/laminas-dependency-plugin (1.0.3)


  [ErrorException]
  include(/var/www/html/magento23/vendor/laminas/laminas-dependency-plugin/src/DependencyRewriterPlugin.php): failed to open stream: No such file or directory


create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--repository REPOSITORY] [--repository-url REPOSITORY-URL] [--add-repository] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-vcs] [--remove-vcs] [--no-install] [--ignore-platform-reqs] [--] [<package>] [<directory>] [<version>]

我收到以下错误。

Plugin installation failed (include(/var/www/html/magento23/vendor/laminas/laminas-dependency-plugin/src/DependencyRewriterPlugin.php): failed to open stream: No such file or directory), rolling back
      - Removing laminas/laminas-dependency-plugin (1.0.3)

我的作曲家版本

muk@muk:/var/www/html$ composer --version

Composer version 1.10.5 2020-04-10 11:44:22

我正在使用带有共享文件夹的 VirtualBox。

我该如何解决?

注意:为了解决这个问题,我停止使用共享文件夹。现在我将整个代码保存在 VM 中,并且不使用共享文件夹。对于文件同步,我正在使用诱变剂。

【问题讨论】:

  • 您最终解决了这个问题吗?我想我有同样的问题
  • 没有@Erfan 仍然面临同样的问题。

标签: magento2


【解决方案1】:

如果有人遇到这个问题,它看起来是 virtualBox 和共享文件夹的问题。解压缩文件时,它们不会立即在环境中可用。

解决方案由rkamp 提供,也可在此处获得:

https://stackoverflow.com/a/66413857/1470145

简而言之,需要覆盖 unzip 以在解压缩后添加一个短暂的延迟。

【讨论】:

    【解决方案2】:

    我以为我有同样的问题,但结果是别的问题。

    升级对我来说很顺利,安装了沙盒/干净的 2.3.4 和运行 2.3.4 的客户端项目。

    一些事情:

    • 这可能是您的缓存问题,请尝试清除您的 composer laminas 缓存(通常为~/.composer/cache/files/laminas
    • 虽然它会抱怨,但您可能有未满足的平台要求(php 版本等)
    • 尝试清除整个作曲家缓存 (~/.composer)
    • 仔细检查存储库 URL(应该是 2.3.5 还是 2.3.5-p1?)

    希望有帮助

    【讨论】:

    • 这些都不起作用,我正在使用带有共享文件夹的 VirtualBox。
    猜你喜欢
    • 1970-01-01
    • 2020-07-08
    • 2022-11-15
    • 1970-01-01
    • 2014-12-21
    • 1970-01-01
    • 1970-01-01
    • 2018-11-09
    • 2012-12-29
    相关资源
    最近更新 更多