{"record":{"id":"b54a7a976973dee6","repo":"gatsbyjs/gatsby","slug":"there-is-no-shopifytype-for-child-type-childtyp","errorCode":null,"errorMessage":"There is no shopifyType for child type: ${childType}","messagePattern":"There is no shopifyType for child type: (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/gatsby-source-shopify/src/process-bulk-results.ts","lineNumber":78,"sourceCode":"\n      // Attach children references / objects\n      if (children[result.shopifyId]) {\n        for (const child of children[result.shopifyId]) {\n          const childType =\n            typeof child === `string`\n              ? parseShopifyId(child)[1]\n              : (child.__typename as string)\n          const field = shopifyTypes[childType].key\n\n          if (field) {\n            result[field] = [\n              typeof child === `string`\n                ? createNodeId(child, gatsbyApi, pluginOptions)\n                : child,\n              ...((result[field] || []) as Array<unknown>),\n            ]\n          } else {\n            throw new Error(\n              `There is no shopifyType for child type: ${childType}`\n            )\n          }\n        }\n      }\n\n      if (!isShopifyId(result.shopifyId)) {\n        throw new Error(\n          `Expected an ID in the format gid://shopify/<typename>/<id>`\n        )\n      }\n\n      const node = {\n        ...result,\n        id: createNodeId(result.shopifyId, gatsbyApi, pluginOptions),\n        internal: {\n          type: `${pluginOptions.typePrefix}Shopify${type}`,\n          contentDigest: gatsbyApi.createContentDigest(result),","sourceCodeStart":60,"sourceCodeEnd":96,"githubUrl":"https://github.com/gatsbyjs/gatsby/blob/8b06340921ffdf23125a365b9c9923690cb62ce6/packages/gatsby-source-shopify/src/process-bulk-results.ts#L60-L96","documentation":"While building node relationships in process-bulk-results, for each child reference the plugin looks up shopifyTypes[childType].key to decide which field on the parent to populate. If childType is not a known Shopify type (no entry in the shopifyTypes map), the key is undefined and the helper throws. childType comes from parseShopifyId or the child's __typename.","triggerScenarios":"Bulk results reference a Shopify type the plugin's type map does not include (e.g. a new type added by Shopify, or a custom type); __typename on a child does not match any registered Shopify type; parseShopifyId returns an unexpected typename from a malformed gid.","commonSituations":"Shopify introduces a new type not yet covered by the plugin version in use; apiVersion mismatch causing __typename differences; custom Shopify extensions injecting non-standard types; corrupted gid strings producing strange typenames.","solutions":["Upgrade gatsby-source-shopify to a version whose type map includes the type seen in error (the message names the childType).","Confirm apiVersion matches a Shopify Admin API version that produces the expected typenames.","Inspect the offending bulk result JSONL line to see the unexpected __typename and report it upstream if it is a genuine Shopify type.","If running a fork, extend the shopifyTypes map with the missing type and its key."],"exampleFix":"null","handlingStrategy":"validation","validationCode":"const knownTypes = ['Product', 'ProductVariant', 'Collection', 'Order', 'Customer']\nif (!knownTypes.includes(childType)) { reporter.warn(`Unknown Shopify child type: ${childType}`); return }","typeGuard":"const isKnownShopifyType = (t, shopifyTypes) => Boolean(shopifyTypes[t] && shopifyTypes[t].key)","tryCatchPattern":"try { buildRelationship(child) } catch (e) { if (/no shopifyType for child type/.test(e.message)) { reporter.warn(`Skipping unknown child type: ${childType}`); return } throw e }","preventionTips":["Keep gatsby-source-shopify and the Shopify apiVersion in sync","Inspect bulk result JSONL for unexpected __typenames during staging","Watch the plugin changelog when upgrading apiVersion"],"tags":["shopify","type-map","data"],"backgroundTag":null,"analyzedSha":"8b06340921ffdf23125a365b9c9923690cb62ce6","analyzedAt":"2026-08-13T02:36:21.405Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}