MDVA-40601:无法检索有关通过GraphQL的计划更新更改的类别的数据

MDVA-40601 Adobe Commerce质量修补程序修复了以下问题:用户通过GraphQL获取有关按计划更新更改的类别的信息时出现错误。 安装Quality Patches Tool (QPT) 1.1.3时,此修补程序可用。 修补程序ID为MDVA-40601。 请注意,该问题计划在Adobe Commerce 2.4.4中修复。

受影响的产品和版本

为Adobe Commerce版本创建了修补程序:

Adobe Commerce(所有部署方法) 2.3.3和2.4.2

与Adobe Commerce版本兼容:

Adobe Commerce(所有部署方法) 2.3.1 - 2.4.2-p2

NOTE
该修补程序可能适用于具有新的Quality Patches Tool版本的其他版本。 要检查修补程序是否与您的Adobe Commerce版本兼容,请将magento/quality-patches包更新到最新版本,并在Quality Patches Tool:搜索修补程序页面上检查兼容性。 使用修补程序ID作为搜索关键字来查找修补程序。

问题

用户在尝试通过GraphQL检索有关计划更新更改的类别的信息时,收到错误。

重现步骤

  1. 使用子类别设置类别结构,如下所示:

    code language-graphql
    
    - Root
     - Some category
          - Some child category
    
  2. 执行ID为“Some Category”的GraphQL查询。

    code language-graphql
    
     query {
      category(id: 49) {
       name
       children {
         name
        }
      }
    }
    

    结果:

    code language-graphql
    
     {
       "data": {
         "category": {
           "name": "Some category",
           "children": [
             {
               "name": "Some child category"
             }
           ]
         }
       }
     }
    
    
  3. 使用其他类别名称为“某些类别”创建计划更新。

  4. 等待计划更新激活。

  5. 执行与上述相同的查询。

预期的结果

您会收到相同的结果,但具有更新的类别名称。

实际结果

您会收到以下错误:


{
  "errors": [
    {
      "debugMessage": "uasort() expects parameter 1 to be array, string given",
      "message": "Internal server error",
      "extensions": {
        "category": "internal"
      },
      "locations": [
        {
          "line": 2,
          "column": 3
        }
      ],
      "path": [
        "category"
      ]
    }
  ],
  "data": {
    "category": null
  }
}

应用修补程序

要应用单个修补程序,请根据您的部署类型使用以下链接:

​* 在开发人员文档中,参阅Adobe Commerce或Magento Open Source内部部署: 软件更新指南>应用修补程序
​* 云基础架构上的Adobe Commerce:我们的开发人员文档中的升级和修补程序>应用修补程序

相关阅读

要了解有关Adobe Commerce质量修补程序的更多信息,请参阅:

​* 已发布质量修补程序工具:用于自助提供质量修补程序的新工具
​* 使用Quality Patches Tool检查是否有可用于Adobe Commerce问题的修补程序。

有关QPT中其他可用修补程序的信息,请参阅QPT🔗中可用的修补程序部分。

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