T
TanStack3mo ago
optimistic-gold

Error after upgrading to v1.121.0 - Invariant failed: Could not find a nearest match!

[vite] connected.
Error in renderToPipeableStream: Error: Invariant failed: Could not find a nearest match!
at invariant (file:///Users/josippapez/Desktop/brisk-fit-web-static/node_modules/tiny-invariant/dist/esm/tiny-invariant.js:12:11)
at Object.select (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/@tanstack/react-router/src/useMatch.tsx:104:7)
at <anonymous> (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/@tanstack/react-router/src/useRouterState.tsx:55:19)
at memoizedSelector (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js:47:30)
at /Users/josippapez/Desktop/brisk-fit-web-static/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js:76:26
at Object.useSyncExternalStore (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/react-dom/cjs/react-dom-server.node.development.js:9126:18)
at process.env.NODE_ENV.exports.useSyncExternalStore (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/react/cjs/react.development.js:1228:34)
at process.env.NODE_ENV.exports.useSyncExternalStoreWithSelector (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js:82:19)
at useStore (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/@tanstack/react-store/src/index.ts:23:17)
at useRouterState (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/@tanstack/react-router/src/useRouterState.tsx:45:10) { componentStack: [Getter] }
[vite] connected.
Error in renderToPipeableStream: Error: Invariant failed: Could not find a nearest match!
at invariant (file:///Users/josippapez/Desktop/brisk-fit-web-static/node_modules/tiny-invariant/dist/esm/tiny-invariant.js:12:11)
at Object.select (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/@tanstack/react-router/src/useMatch.tsx:104:7)
at <anonymous> (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/@tanstack/react-router/src/useRouterState.tsx:55:19)
at memoizedSelector (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js:47:30)
at /Users/josippapez/Desktop/brisk-fit-web-static/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js:76:26
at Object.useSyncExternalStore (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/react-dom/cjs/react-dom-server.node.development.js:9126:18)
at process.env.NODE_ENV.exports.useSyncExternalStore (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/react/cjs/react.development.js:1228:34)
at process.env.NODE_ENV.exports.useSyncExternalStoreWithSelector (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js:82:19)
at useStore (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/@tanstack/react-store/src/index.ts:23:17)
at useRouterState (/Users/josippapez/Desktop/brisk-fit-web-static/node_modules/@tanstack/react-router/src/useRouterState.tsx:45:10) { componentStack: [Getter] }
Before the upgrade and following the migrations, the app worked fine. The project builds normally after the upgrade but even when the built app is trying to start i get the same error
1 Reply
flat-fuchsia
flat-fuchsia3mo ago
1.121 is broken, it had a lot of changes and bugs, just rollback to 1.120 before they fix all of them

Did you find this page helpful?