{"record":{"id":"b5b7284afaf5ed9f","repo":"facebook/react","slug":"248","errorCode":"248","errorMessage":"Not implemented.","messagePattern":"Not implemented\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/react-markup/src/ReactMarkupLegacyClientStreamConfig.js","lineNumber":20,"sourceCode":" * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * @flow\n */\n\nexport type StringDecoder = null;\n\nexport function createStringDecoder(): null {\n  return null;\n}\n\nexport function readPartialStringChunk(\n  decoder: StringDecoder,\n  buffer: Uint8Array,\n): string {\n  throw new Error('Not implemented.');\n}\n\nexport function readFinalStringChunk(\n  decoder: StringDecoder,\n  buffer: Uint8Array,\n): string {\n  throw new Error('Not implemented.');\n}\n","sourceCodeStart":2,"sourceCodeEnd":29,"githubUrl":"https://github.com/facebook/react/blob/eafeac097ba51e1eab809c07102126bd5f8e5425/packages/react-markup/src/ReactMarkupLegacyClientStreamConfig.js#L2-L29","documentation":"ReactMarkupLegacyClientStreamConfig is re-exported as the markup fork of ReactFlightClientConfig (react-client), but its byte-chunk decoding surface is stubbed: readPartialStringChunk always throws 'Not implemented.'. The markup Flight protocol transfers string chunks only, so any code path that asks this config to decode a partial binary chunk is unsupported by design.","triggerScenarios":"Feeding Uint8Array/binary chunks into the markup-mode Flight client - i.e. invoking readPartialStringChunk (directly or through a stream reader built on this config) - instead of delivering string chunks via processFlightStringChunk as experimental_renderToHTML's internal pipeline does.","commonSituations":"Hand-wiring a Flight client under the 'markup' resolve condition; piping Node Buffers or byte streams where the markup string protocol is expected; tooling that assumes the generic Flight client byte API.","solutions":["Deliver chunks as strings: decode bytes yourself and push them through processFlightStringChunk.","If you must stream bytes, use the standard Flight client config (the dom/node forks of ReactFlightClientConfig) rather than the markup fork.","Treat readPartialStringChunk/readFinalStringChunk on the markup config as unsupported and never call them."],"exampleFix":"// before\nreadPartialStringChunk(decoder, uint8ArrayChunk); // throws: not implemented\n\n// after - decode to a string and use the string-chunk path\nprocessFlightStringChunk(\n  flightResponse,\n  streamState,\n  new TextDecoder().decode(uint8ArrayChunk),\n);","handlingStrategy":"type-guard","validationCode":"const isStringChunk = chunk => typeof chunk === 'string';\nfunction feedChunk(flightResponse, streamState, chunk) {\n  const text = isStringChunk(chunk)\n    ? chunk\n    : new TextDecoder().decode(chunk);\n  processFlightStringChunk(flightResponse, streamState, text);\n}","typeGuard":"const isStringChunk = chunk => typeof chunk === 'string';","tryCatchPattern":null,"preventionTips":["Feed the markup Flight client only string chunks; decode bytes yourself.","Use the standard Flight client config (dom/node fork) for byte streams.","Remember the markup config's readPartial/readFinalStringChunk are stubs, not slow paths."],"tags":["flight","react-markup","streaming","not-implemented"],"backgroundTag":"unsupported-byte-chunk-decoding","analyzedSha":"eafeac097ba51e1eab809c07102126bd5f8e5425","analyzedAt":"2026-08-21T22:01:08.818Z","schemaVersion":2},"datasetVersion":"2026-08-21T23:17:16.201Z"}