{"record":{"id":"e25d8937c3e3e8f8","repo":"react/react","slug":"getprofilingdata-not-supported-by-this-renderer","errorCode":null,"errorMessage":"getProfilingData not supported by this renderer","messagePattern":"getProfilingData not supported by this renderer","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"warning","filePath":"packages/react-devtools-shared/src/backend/flight/renderer.js","lineNumber":188,"sourceCode":"      return null;\n    },\n    getSuspenseNodeIDForHostInstance() {\n      return null;\n    },\n    getInstanceAndStyle() {\n      return {\n        instance: null,\n        style: null,\n      };\n    },\n    getOwnersList() {\n      return null;\n    },\n    getPathForElement() {\n      return null;\n    },\n    getProfilingData() {\n      throw new Error('getProfilingData not supported by this renderer');\n    },\n    handleCommitFiberRoot() {},\n    handleCommitFiberUnmount() {},\n    handlePostCommitFiberRoot() {},\n    hasElementWithId() {\n      return false;\n    },\n    inspectElement(\n      requestID: number,\n      id: number,\n      path: Array<string | number> | null,\n    ) {\n      return {\n        id,\n        responseID: requestID,\n        type: 'not-found',\n      };\n    },","sourceCodeStart":170,"sourceCodeEnd":206,"githubUrl":"https://github.com/react/react/blob/22e4f993c7ce9373c95aef093b003f84249e2045/packages/react-devtools-shared/src/backend/flight/renderer.js#L170-L206","documentation":"Thrown by the Flight (React Server Components) DevTools renderer. RSC/Flight inspection is read-only and has no commit/profiling timeline, so getProfilingData — which returns recorded profiling samples — is not implementable. The renderer stubs it to throw so a profiling request against a Flight renderer fails loudly rather than returning empty data.","triggerScenarios":"DevTools requests profiling data (e.g., exporting a profile) and the request is routed to a Flight/RSC renderer's getProfilingData.","commonSituations":"Profiling a React Server Components tree from DevTools; a page where the only attached renderer is the Flight renderer; DevTools automation that calls getProfilingData on every attached renderer without filtering.","solutions":["Profile a client-side (createRoot) renderer instead — Flight/RSC is not profileable.","Ensure the app also exposes a client renderer so DevTools can attach profiling to it.","In automation, skip getProfilingData for renderers that do not support it.","Recognize this is expected behavior, not a crash to fix."],"exampleFix":"// before: requesting a profile from any attached renderer\nconst data = renderer.getProfilingData();\n// after: only from profileable renderers\nif (renderer.supportsProfiling) {\n  const data = renderer.getProfilingData();\n}","handlingStrategy":"validation","validationCode":"// Flight/RSC renderers are read-only and not profileable. Skip them.\nfunction isProfileable(renderer) {\n  // Flight renderer exposes getEnvironmentNames but throws on getProfilingData;\n  // a fiber renderer implements a real getProfilingData.\n  return Boolean(renderer && renderer.supportsProfiling !== false &&\n    typeof renderer.inspectElement === 'function' &&\n    !/flight/i.test(renderer.renderer?.packageName || ''));\n}\n\nif (isProfileable(renderer)) {\n  const data = renderer.getProfilingData();\n}","typeGuard":"function isProfileableRenderer(renderer) {\n  return Boolean(renderer && typeof renderer.getProfilingData === 'function' &&\n    renderer.supportsProfiling !== false);\n}","tryCatchPattern":null,"preventionTips":["Profile client-side (createRoot) renderers; RSC/Flight is read-only and not profileable.","Ensure the inspected app exposes a client renderer for profiling.","In DevTools automation, filter renderers by capability before calling getProfilingData.","Treat the throw as expected unavailability, not a defect."],"tags":["react-devtools","flight","rsc","profiling","unsupported-feature"],"backgroundTag":null,"analyzedSha":"22e4f993c7ce9373c95aef093b003f84249e2045","analyzedAt":"2026-08-12T22:33:25.580Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}