lobehub / lobe-chat

🤯 Lobe Chat - an open-source, modern-design AI chat framework. Supports Multi AI Providers( OpenAI / Claude 3 / Gemini / Ollama / Azure / DeepSeek), Knowledge Base (file upload / knowledge management / RAG ), Multi-Modals (Vision/TTS) and plugin system. One-click FREE deployment of your private ChatGPT/ Claude application.
https://chat-preview.lobehub.com
Other
44.03k stars 9.84k forks source link

[Bug] #4416

Closed bakamake closed 1 week ago

bakamake commented 1 week ago

📦 Environment

Vercel

📌 Version

1.22.9

💻 Operating System

Windows

🌐 Browser

Edge

🐛 Bug Description

fork后deploy vercel server版失败 一键deploy vercel也失败

📷 Recurrence Steps

[00:45:56.946] Running build in Washington, D.C., USA (East) – iad1 [00:45:57.100] Cloning github.com/bakamake/databaseless-lobe-chat (Branch: main, Commit: 6a0600f) [00:45:57.451] Previous build cache not available [00:45:57.879] Cloning completed: 778.606ms [00:45:58.806] Running "vercel build" [00:45:59.227] Vercel CLI 37.9.0 [00:45:59.913] Running "install" command: bun install... [00:45:59.963] bun install v1.1.30 (7996d06b) [00:45:59.978] Resolving dependencies [00:46:18.140] Resolved, downloaded and extracted [9646] [00:46:18.140] warn: incorrect peer dependency "eslint@8.57.1" [00:46:18.140] [00:46:18.140] warn: incorrect peer dependency "stylelint@15.11.0" [00:46:18.140] [00:46:18.141] warn: incorrect peer dependency "stylelint@15.11.0" [00:46:18.141] [00:46:18.141] warn: incorrect peer dependency "stylelint@15.11.0" [00:46:18.141] [00:46:18.141] warn: incorrect peer dependency "stylelint@15.11.0" [00:46:18.141] [00:46:18.141] warn: incorrect peer dependency "@octokit/core@5.2.0" [00:46:51.991] Saved lockfile [00:46:51.992] [00:46:51.992] $ husky [00:46:52.051] [00:46:52.052] + @commitlint/cli@19.5.0 [00:46:52.052] + @edge-runtime/vm@4.0.3 [00:46:52.052] + @huggingface/tasks@0.12.22 [00:46:52.052] + @lobehub/i18n-cli@1.20.0 [00:46:52.052] + @lobehub/lint@1.24.4 [00:46:52.052] + @lobehub/seo-cli@1.4.2 [00:46:52.053] + @next/bundle-analyzer@14.2.15 [00:46:52.053] + @next/eslint-plugin-next@14.2.15 [00:46:52.053] + @peculiar/webcrypto@1.5.0 [00:46:52.053] + @testing-library/jest-dom@6.6.2 [00:46:52.053] + @testing-library/react@16.0.1 [00:46:52.053] + @types/chroma-js@2.4.4 [00:46:52.054] + @types/debug@4.1.12 [00:46:52.054] + @types/diff@5.2.3 [00:46:52.054] + @types/ip@1.1.3 [00:46:52.054] + @types/json-schema@7.0.15 [00:46:52.054] + @types/lodash@4.17.12 [00:46:52.054] + @types/lodash-es@4.17.12 [00:46:52.054] + @types/node@20.16.13 [00:46:52.055] + @types/numeral@2.0.5 [00:46:52.055] + @types/pg@8.11.10 [00:46:52.055] + @types/react@18.3.11 [00:46:52.056] + @types/react-dom@18.3.1 [00:46:52.056] + @types/rtl-detect@1.0.3 [00:46:52.056] + @types/semver@7.5.8 [00:46:52.056] + @types/systemjs@6.15.1 [00:46:52.056] + @types/ua-parser-js@0.7.39 [00:46:52.056] + @types/unist@3.0.3 [00:46:52.056] + @types/uuid@10.0.0 [00:46:52.057] + @types/ws@8.5.12 [00:46:52.057] + @vitest/coverage-v8@1.2.2 [00:46:52.057] + ajv-keywords@5.1.0 [00:46:52.057] + commitlint@19.5.0 [00:46:52.057] + consola@3.2.3 [00:46:52.057] + dotenv@16.4.5 [00:46:52.057] + dpdm@3.14.0 [00:46:52.058] + drizzle-kit@0.25.0 [00:46:52.058] + eslint@8.57.1 [00:46:52.058] + eslint-plugin-mdx@2.3.4 [00:46:52.058] + eslint-plugin-unused-imports@4.0.1 [00:46:52.058] + fake-indexeddb@6.0.0 [00:46:52.058] + glob@11.0.0 [00:46:52.060] + gray-matter@4.0.3 [00:46:52.060] + happy-dom@15.7.4 [00:46:52.060] + husky@9.1.6 [00:46:52.060] + just-diff@6.0.2 [00:46:52.060] + lint-staged@15.2.10 [00:46:52.060] + lodash@4.17.21 [00:46:52.060] + markdown-table@3.0.3 [00:46:52.060] + node-fetch@3.3.2 [00:46:52.060] + node-gyp@10.2.0 [00:46:52.060] + openapi-typescript@6.7.6 [00:46:52.061] + p-map@7.0.2 [00:46:52.061] + prettier@3.3.3 [00:46:52.061] + remark-cli@11.0.0 [00:46:52.061] + remark-parse@10.0.2 [00:46:52.061] + semantic-release@21.1.2 [00:46:52.061] + serwist@9.0.9 [00:46:52.061] + stylelint@15.11.0 [00:46:52.061] + supports-color@8.1.1 [00:46:52.061] + tsx@4.19.1 [00:46:52.062] + typescript@5.6.3 [00:46:52.062] + unified@11.0.5 [00:46:52.062] + unist-util-visit@5.0.0 [00:46:52.062] + vite@5.4.9 [00:46:52.062] + vitest@1.2.2 [00:46:52.062] + vitest-canvas-mock@0.3.3 [00:46:52.062] + @ant-design/icons@5.5.1 [00:46:52.062] + @ant-design/pro-components@2.7.18 [00:46:52.062] + @anthropic-ai/sdk@0.29.2 [00:46:52.062] + @auth/core@0.34.2 [00:46:52.062] + @aws-sdk/client-bedrock-runtime@3.675.0 [00:46:52.062] + @aws-sdk/client-s3@3.675.0 [00:46:52.062] + @aws-sdk/s3-request-presigner@3.675.0 [00:46:52.062] + @azure/core-rest-pipeline@1.16.0 [00:46:52.062] + @azure/openai@1.0.0-beta.12 [00:46:52.062] + @baiducloud/qianfan@0.1.9 [00:46:52.063] + @cfworker/json-schema@2.0.1 [00:46:52.063] + @clerk/localizations@3.3.0 [00:46:52.063] + @clerk/nextjs@5.7.5 [00:46:52.063] + @clerk/themes@2.1.37 [00:46:52.063] + @codesandbox/sandpack-react@2.19.9 [00:46:52.063] + @cyntler/react-doc-viewer@1.17.0 [00:46:52.063] + @google/generative-ai@0.16.1 [00:46:52.063] + @huggingface/inference@2.8.1 [00:46:52.063] + @icons-pack/react-simple-icons@9.6.0 [00:46:52.064] + @khmyznikov/pwa-install@0.3.9 [00:46:52.064] + @langchain/community@0.2.33 [00:46:52.064] + @lobehub/chat-plugin-sdk@1.32.4 [00:46:52.064] + @lobehub/chat-plugins-gateway@1.9.0 [00:46:52.064] + @lobehub/icons@1.35.4 [00:46:52.064] + @lobehub/tts@1.25.1 [00:46:52.064] + @lobehub/ui@1.151.5 [00:46:52.064] + @neondatabase/serverless@0.10.1 [00:46:52.064] + @next/third-parties@14.2.15 [00:46:52.064] + @react-spring/web@9.7.5 [00:46:52.064] + @sentry/nextjs@7.119.2 [00:46:52.064] + @serwist/next@9.0.9 [00:46:52.064] + @t3-oss/env-nextjs@0.11.1 [00:46:52.064] + @tanstack/react-query@5.59.15 [00:46:52.064] + @trpc/client@11.0.0-rc.586 [00:46:52.064] + @trpc/next@11.0.0-rc.586 [00:46:52.064] + @trpc/react-query@11.0.0-rc.586 [00:46:52.064] + @trpc/server@11.0.0-rc.586 [00:46:52.064] + @vercel/analytics@1.3.1 [00:46:52.064] + @vercel/edge-config@1.3.0 [00:46:52.064] + @vercel/speed-insights@1.0.12 [00:46:52.064] + ahooks@3.8.1 [00:46:52.064] + ai@3.4.16 [00:46:52.064] + antd@5.21.4 [00:46:52.064] + antd-style@3.7.0 [00:46:52.064] + brotli-wasm@3.0.1 [00:46:52.064] + chroma-js@2.6.0 [00:46:52.064] + dayjs@1.11.13 [00:46:52.064] + debug@4.3.7 [00:46:52.068] + dexie@3.2.7 [00:46:52.068] + diff@5.2.0 [00:46:52.068] + drizzle-orm@0.34.1 [00:46:52.068] + drizzle-zod@0.5.1 [00:46:52.068] + fast-deep-equal@3.1.3 [00:46:52.068] + file-type@19.6.0 [00:46:52.068] + framer-motion@11.11.9 [00:46:52.068] + gpt-tokenizer@2.5.0 [00:46:52.069] + i18next@23.16.1 [00:46:52.069] + i18next-browser-languagedetector@7.2.1 [00:46:52.069] + i18next-resources-to-backend@1.2.1 [00:46:52.069] + idb-keyval@6.2.1 [00:46:52.069] + immer@10.1.1 [00:46:52.069] + ip@2.0.1 [00:46:52.069] + jose@5.9.4 [00:46:52.069] + js-sha256@0.11.0 [00:46:52.069] + jsonl-parse-stringify@1.0.3 [00:46:52.069] + langchain@0.3.2 [00:46:52.069] + langfuse@3.27.0 [00:46:52.069] + langfuse-core@3.27.0 [00:46:52.070] + lodash-es@4.17.21 [00:46:52.070] + lucide-react@0.453.0 [00:46:52.070] + mammoth@1.8.0 [00:46:52.070] + modern-screenshot@4.4.39 [00:46:52.070] + nanoid@5.0.7 [00:46:52.070] + next@14.2.8 [00:46:52.070] + next-auth@5.0.0-beta.23 [00:46:52.070] + next-mdx-remote@4.4.1 [00:46:52.070] + nextjs-toploader@3.7.15 [00:46:52.070] + numeral@2.0.6 [00:46:52.070] + nuqs@1.20.0 [00:46:52.070] + officeparser@4.2.0 [00:46:52.071] + ollama@0.5.9 [00:46:52.071] + openai@4.68.1 [00:46:52.075] + openapi-fetch@0.9.8 [00:46:52.075] + partial-json@0.1.7 [00:46:52.076] + pdf-parse@1.1.1 [00:46:52.076] + pdfjs-dist@4.4.168 [00:46:52.076] + pg@8.13.0 [00:46:52.076] + pino@9.5.0 [00:46:52.076] + polished@4.3.1 [00:46:52.076] + posthog-js@1.174.2 [00:46:52.076] + pwa-install-handler@2.6.1 [00:46:52.076] + query-string@9.1.1 [00:46:52.076] + random-words@2.0.1 [00:46:52.077] + react@18.3.1 [00:46:52.077] + react-confetti@6.1.0 [00:46:52.077] + react-dom@18.3.1 [00:46:52.077] + react-fast-marquee@1.6.5 [00:46:52.077] + react-hotkeys-hook@4.5.1 [00:46:52.077] + react-i18next@14.0.2 [00:46:52.077] + react-layout-kit@1.9.0 [00:46:52.077] + react-lazy-load@4.0.1 [00:46:52.077] + react-pdf@9.1.1 [00:46:52.077] + react-virtuoso@4.12.0 [00:46:52.077] + react-wrap-balancer@1.1.1 [00:46:52.080] + remark@14.0.3 [00:46:52.080] + remark-gfm@3.0.1 [00:46:52.080] + remark-html@15.0.2 [00:46:52.080] + request-filtering-agent@2.0.1 [00:46:52.080] + resolve-accept-language@3.1.8 [00:46:52.080] + rtl-detect@1.1.2 [00:46:52.080] + semver@7.6.3 [00:46:52.080] + sharp@0.33.5 [00:46:52.080] + shiki@1.22.0 [00:46:52.081] + stripe@15.12.0 [00:46:52.081] + superjson@2.2.1 [00:46:52.082] + svix@1.37.0 [00:46:52.082] + swr@2.2.5 [00:46:52.082] + systemjs@6.15.1 [00:46:52.082] + ts-md5@1.3.1 [00:46:52.082] + ua-parser-js@1.0.39 [00:46:52.082] + unstructured-client@0.18.1 [00:46:52.083] + url-join@5.0.0 [00:46:52.083] + use-merge-value@1.2.0 [00:46:52.083] + utility-types@3.11.0 [00:46:52.083] + uuid@10.0.0 [00:46:52.083] + ws@8.18.0 [00:46:52.083] + y-protocols@1.0.6 [00:46:52.083] + y-webrtc@10.3.0 [00:46:52.083] + yaml@2.6.0 [00:46:52.083] + yjs@13.6.20 [00:46:52.083] + zod@3.23.8 [00:46:52.083] + zustand@4.5.5 [00:46:52.083] + zustand-utils@1.3.2 [00:46:52.083] [00:46:52.083] 2618 packages installed [52.14s] [00:46:52.084] [00:46:52.084] Blocked 7 postinstalls. Run bun pm untrusted for details. [00:46:52.123] Detected Next.js version: 14.2.8 [00:46:52.134] Running "bun run build" [00:46:52.139] $ next build [00:46:52.998] Attention: Next.js now collects completely anonymous telemetry regarding usage. [00:46:52.999] This information is used to shape Next.js' roadmap and prioritize features. [00:46:52.999] You can learn more, including how to opt-out if you'd not like to participate in this anonymous program, by visiting the following URL: [00:46:52.999] https://nextjs.org/telemetry [00:46:53.000] [00:46:53.070] ▲ Next.js 14.2.8 [00:46:53.070] [00:46:53.198] Creating an optimized production build ... [00:46:53.762] ○ (serwist) The service worker will not be automatically registered, please call 'window.serwist.register()' in 'componentDidMount' or 'useEffect'. [00:46:53.769] ✓ (serwist) Bundling the service worker script with the URL '/sw.js' and the scope '/'... [00:52:41.811] ✓ Compiled successfully [00:52:41.834] Linting and checking validity of types ... [00:54:56.447] Failed to compile. [00:54:56.447] [00:54:56.447] ./src/libs/next-auth/sso-providers/azure-ad.ts:17:5 [00:54:56.448] Type error: Object literal may only specify known properties, and 'tenantId' does not exist in type 'OIDCUserConfig & { profilePhotoSize?: 48 | 64 | 96 | 120 | 240 | 360 | 432 | 504 | 648 | undefined; }'. [00:54:56.448] [00:54:56.448]   15 | clientId: authEnv.AZURE_AD_CLIENT_ID ?? process.env.AUTH_AZURE_AD_ID, [00:54:56.448]   16 | clientSecret: authEnv.AZURE_AD_CLIENT_SECRET ?? process.env.AUTH_AZURE_AD_SECRET, [00:54:56.448] > 17 | tenantId: authEnv.AZURE_AD_TENANT_ID ?? process.env.AUTH_AZURE_AD_TENANT_ID, [00:54:56.448]   | ^ [00:54:56.448]   18 | // Remove end [00:54:56.449]   19 | // TODO(NextAuth): map unique user id to providerAccountId field [00:54:56.449]   20 | 00:54:56.828 { [00:54:56.828] error: script "build" exited with code 1 [00:54:56.841] Error: Command "bun run build" exited with 1 [00:55:00.115]

🚦 Expected Behavior

successing deploy vercel server

📝 Additional Information

No response

lobehubbot commented 1 week ago

👀 @bakamake

Thank you for raising an issue. We will investigate into the matter and get back to you as soon as possible. Please make sure you have given us as much context as possible.\ 非常感谢您提交 issue。我们会尽快调查此事,并尽快回复您。 请确保您已经提供了尽可能多的背景信息。

dosubot[bot] commented 1 week ago

There are similar issues and discussions related to deployment failures on Vercel for the Lobe Chat project. Here are some relevant ones:

  1. Deployment on Vercel fails from time to time - This discussion highlights intermittent deployment failures on Vercel [1].

  2. Vercel部署报错出现这种状况改如何解决 - Another discussion about deployment errors on Vercel [2].

  3. [Bug] Deployment failed on vercel](https://github.com/lobehub/lobe-chat/issues/3453) - This issue was resolved by pinning a specific version of a dependency to fix the Vercel build [3].

Regarding the specific error you're encountering, it seems to be related to a type error in the next-auth library configuration for Azure AD. The error message indicates that the tenantId property does not exist in the type OIDCUserConfig<MicrosoftEntraIDProfile>. This might be due to a mismatch in the expected type definition or a missing update in the library.

To resolve this, you can:

If the issue persists, you might need to look into the specific version of the next-auth library you are using and see if there are any known issues or updates related to Azure AD integration.

To continue talking to Dosu, mention @dosu.

lobehubbot commented 1 week ago

✅ @bakamake

This issue is closed, If you have any questions, you can comment and reply.\ 此问题已经关闭。如果您有任何问题,可以留言并回复。

lobehubbot commented 1 week ago

:tada: This issue has been resolved in version 1.22.10 :tada:

The release is available on:

Your semantic-release bot :package::rocket: