{"record":{"id":"32c585d1bcf67de0","repo":"langgenius/dify","slug":"invalid-dev-proxy-route-path-path-paths-must","errorCode":null,"errorMessage":"Invalid dev proxy route path \"${path}\". Paths must start with \"/\".","messagePattern":"Invalid dev proxy route path \"(.+?)\"\\. Paths must start with \"/\"\\.","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/dev-proxy/src/server.ts","lineNumber":438,"sourceCode":"  return (request: IncomingMessage, clientSocket: Duplex, head: Buffer) => {\n    try {\n      handleUpgrade(request, clientSocket, head)\n    } catch (error) {\n      logger.error('[dev-proxy]', error)\n      if (!clientSocket.destroyed) closeUpgradeRequest(clientSocket, 502, 'Bad Gateway')\n    }\n  }\n}\n\nconst registerProxyRoute = (\n  app: Hono,\n  route: DevProxyRoute,\n  path: string,\n  fetchImpl: typeof globalThis.fetch,\n  allowedOrigins: DevProxyCorsAllowedOrigins,\n) => {\n  if (!path.startsWith('/'))\n    throw new Error(`Invalid dev proxy route path \"${path}\". Paths must start with \"/\".`)\n\n  app.all(path, (context) => proxyRequest(context, route, fetchImpl, allowedOrigins))\n  app.all(`${path}/*`, (context) => proxyRequest(context, route, fetchImpl, allowedOrigins))\n}\n\nconst registerProxyRoutes = (\n  app: Hono,\n  routes: readonly DevProxyRoute[],\n  fetchImpl: typeof globalThis.fetch,\n  allowedOrigins: DevProxyCorsAllowedOrigins,\n) => {\n  routes.forEach((route) => {\n    normalizeRoutePaths(route.paths).forEach((path) => {\n      registerProxyRoute(app, route, path, fetchImpl, allowedOrigins)\n    })\n  })\n}\n","sourceCodeStart":420,"sourceCodeEnd":456,"githubUrl":"https://github.com/langgenius/dify/blob/ef8544b173fd6cd7a8e71df2cab576e52bebbfbc/packages/dev-proxy/src/server.ts#L420-L456","documentation":"Error \"Invalid dev proxy route path \"${path}\". Paths must start with \"/\".\" thrown in langgenius/dify.","triggerScenarios":"Thrown at packages/dev-proxy/src/server.ts:438 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"ef8544b173fd6cd7a8e71df2cab576e52bebbfbc","analyzedAt":"2026-08-12T05:15:17.394Z","schemaVersion":2},"datasetVersion":"2026-08-12T13:17:24.610Z"}