在Adobe Commerce 2.4.6-p1内部部署上安装B2B 1.4.0失败

本文为Adobe Commerce 2.4.6-p1内部部署问题提供了解决方法,该问题导致B2B版本1.4.0安装失败。

受影响的产品和版本

  • Adobe Commerce 2.4.6-p1 本地
  • B2B版本1.4.0
NOTE
B2B版本1.4.0已成功安装在​ Adobe Commerce Cloud 2.4.6-p1 ​上。

问题

重现步骤

  1. 安装Adobe Commerce 2.4.6-p1。

    code language-bash
    m2install.sh -s composer --ee -v 2.4.6-p1
    
  2. 尝试安装B2B版本1.4.0。

    code language-bash
    composer require magento/extension-b2b:1.4.0
    

预期的结果

已成功在Adobe Commerce 2.4.6-p1上安装B2B版本1.4.0。

实际结果

安装失败并出现以下错误:

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Root composer.json requires magento/extension-b2b 1.4.0 -> satisfiable by magento/extension-b2b[1.4.0].
    - magento/extension-b2b 1.4.0 requires magento/security-package-b2b 1.0.4-beta1 -> found magento/security-package-b2b[1.0.4-beta1] but it does not match your minimum-stability.


Installation failed, reverting ./composer.json and ./composer.lock to their original content.

解决方法

通过为带有稳定性标记的B2B安全包添加手动依赖项,在Adobe Commerce 2.4.6-p1上成功安装或升级到B2B版本1.4.0。

  1. 从Adobe Commerce安装目录中,使用所需的依赖项更新composer.json

    code language-bash
    composer require magento/module-re-captcha-company=1.0.3-beta1@beta magento/security-package-b2b=1.0.4-beta1@beta
    

    命令输出:

    code language-bash
    Running composer update magento/module-re-captcha-company magento/security-package-b2b
    Loading composer repositories with package information
    Updating dependencies
    Lock file operations: 2 installs, 0 updates, 0 removals
      - Locking magento/module-re-captcha-company (1.0.3-beta1)
      - Locking magento/security-package-b2b (1.0.4-beta1)
    Writing lock file
    Installing dependencies from lock file (including require-dev)
    Package operations: 2 installs, 0 updates, 0 removals
      - Downloading magento/module-re-captcha-company (1.0.3-beta1)
      - Installing magento/module-re-captcha-company (1.0.3-beta1): Extracting archive
      - Installing magento/security-package-b2b (1.0.4-beta1)
    1 package suggestions were added by new dependencies, use `composer suggest` to see details.
    Package sebastian/phpcpd is abandoned, you should avoid using it. No replacement was suggested.
    Generating autoload files
    132 packages you are using are looking for funding.
    Use the `composer fund` command to find out more!
    No security vulnerability advisories found
    
  2. 更新composer.json以添加B2B版本1.4.0。

    code language-bash
    composer require magento/extension-b2b=1.4.0
    

    命令输出:

    code language-bash
    ./composer.json has been updated
    Running composer update magento/extension-b2b
    Loading composer repositories with package information
    Updating dependencies
    ...
    Generating autoload files
    132 packages you are using are looking for funding.
    Use the `composer fund` command to find out more!
    No security vulnerability advisories found
    
  3. 完成安装或升级过程。

recommendation-more-help
8bd06ef0-b3d5-4137-b74e-d7b00485808a