ACP2E-5017: GraphQL customer role query fails for customers without a company
The ACP2E-5017 patch fixes the issue where the role field of the GraphQL customer query returns Internal server error for a customer who is not assigned to a company. This patch is available when the Quality Patches Tool (QPT) 1.1.84 is installed. The patch ID is ACP2E-5017. Please note that this issue is scheduled to be fixed in Adobe Commerce B2B 1.5.4.
Affected products and versions
The patch is created for Adobe Commerce version:
- Adobe Commerce (all deployment methods) B2B 1.5.3
Compatible with Adobe Commerce versions:
- Adobe Commerce (all deployment methods) B2B 1.5.0 - 1.5.3
magento/quality-patches package to the latest version and check the compatibility on the Quality Patches Tool: Search for patches page. Use the patch ID as a search keyword to locate the patch.Issue
The role field of the GraphQL customer query returns Internal server error for a customer who is not assigned to a company.
Prerequisites:
B2B is installed.
Steps to reproduce:
- In the Admin, go to Stores > Settings > Configuration > General > B2B Features, set Enable Company to Yes, and click Save Config.
- Create a customer account that is not assigned to a company.
- Send the following GraphQL query using a valid customer token:
query {
customer {
email
firstname
role {
id
name
}
}
}
Expected results:
The query returns the customer data with the role set to null, without errors.
Actual results:
The query returns Internal server error.
Apply the patch
To apply individual patches, use the following links depending on your deployment method:
- Adobe Commerce or Magento Open Source on-premises: Quality Patches Tool > Usage in the Quality Patches Tool guide
- Adobe Commerce on cloud infrastructure: Upgrades and Patches > Apply Patches in the Commerce on Cloud Infrastructure guide
Related reading
To learn more about Quality Patches Tool, refer to:
- Quality Patches Tool: A self-service tool for quality patches in the Tools guide