{"record":{"id":"84502517e91b74b1","repo":"facebook/react","slug":"462","errorCode":"462","errorMessage":"Unexpected SuspendedReason. This is a bug in React.","messagePattern":"Unexpected SuspendedReason\\. This is a bug in React\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/react-reconciler/src/ReactFiberWorkLoop.js","lineNumber":3000,"sourceCode":"            workInProgressThrownValue = null;\n            throwAndUnwindWorkLoop(\n              root,\n              unitOfWork,\n              thrownValue,\n              SuspendedOnDeprecatedThrowPromise,\n            );\n            break;\n          }\n          case SuspendedOnHydration: {\n            // Selective hydration. An update flowed into a dehydrated tree.\n            // Interrupt the current render so the work loop can switch to the\n            // hydration lane.\n            resetWorkInProgressStack();\n            workInProgressRootExitStatus = RootSuspendedAtTheShell;\n            break outer;\n          }\n          default: {\n            throw new Error(\n              'Unexpected SuspendedReason. This is a bug in React.',\n            );\n          }\n        }\n      }\n\n      if (__DEV__ && ReactSharedInternals.actQueue !== null) {\n        // `act` special case: If we're inside an `act` scope, don't consult\n        // `shouldYield`. Always keep working until the render is complete.\n        // This is not just an optimization: in a unit test environment, we\n        // can't trust the result of `shouldYield`, because the host I/O is\n        // likely mocked.\n        workLoopSync();\n      } else if (enableThrottledScheduling) {\n        workLoopConcurrent(includesNonIdleWork(lanes));\n      } else {\n        workLoopConcurrentByScheduler();\n      }","sourceCodeStart":2982,"sourceCodeEnd":3018,"githubUrl":"https://github.com/facebook/react/blob/eafeac097ba51e1eab809c07102126bd5f8e5425/packages/react-reconciler/src/ReactFiberWorkLoop.js#L2982-L3018","documentation":"While the concurrent work loop decides whether to yield, it switches on the current suspension reason (SuspendedOnImmediate, SuspendedOnData, SuspendedOnHydration, and related values). Reaching the default branch means the reason variable held an unknown value — an invariant that guards the yield/interrupt machinery (error code 462) and indicates a reconciler bug, typically in the yielding/component-performance-track paths.","triggerScenarios":"The work loop consults SuspendedReason (e.g. after a fiber suspended and time-slicing checks whether to interrupt) and encounters a value outside the enum — usually from a canary regression in the yield paths or corrupted module state.","commonSituations":"Experimental/canary React builds with enableComponentPerformanceTrack or yielding features enabled; reconciler forks that add suspension reasons; duplicated react-reconciler state.","solutions":["Switch from canary/experimental to the matching stable release to confirm it is an upstream regression","Disable experimental features (component performance track, yielding flags) if you control the build","File a React issue with the exact build version and a stack trace from the throw site"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":["Prefer stable over canary/experimental builds in production","Disable experimental yielding/performance-track flags when reproducing","Capture the SuspendedReason value from the stack when reporting upstream"],"tags":["internal-invariant","work-loop","suspense","time-slicing"],"backgroundTag":"react-internal-invariant","analyzedSha":"eafeac097ba51e1eab809c07102126bd5f8e5425","analyzedAt":"2026-08-21T22:01:08.818Z","schemaVersion":2},"datasetVersion":"2026-08-21T23:17:16.201Z"}