Skip to content

[Bug] [web] Build error occurred 前端构建失败 #2691

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
2 of 15 tasks
EdwinOlders11 opened this issue May 14, 2025 · 1 comment
Open
2 of 15 tasks

[Bug] [web] Build error occurred 前端构建失败 #2691

EdwinOlders11 opened this issue May 14, 2025 · 1 comment
Labels
bug Something isn't working Waiting for reply

Comments

@EdwinOlders11
Copy link

Search before asking

  • I had searched in the issues and found no similar issues.

Operating system information

Windows

Python version information

=3.11

DB-GPT version

latest release

Related scenes

  • Chat Data
  • Chat Excel
  • Chat DB
  • Chat Knowledge
  • Model Management
  • Dashboard
  • Plugins

Installation Information

Device information

gpu:L40

Models information

deepseek-r1-1.5b

What happened

拉取源码后使用package.json中的配置构建web前端,构建失败:

info  - Need to disable some ESLint rules? Learn more here: https://nextjs.org/docs/basic-features/eslint#disabling-rules
- info Linting
- info Collecting page data ..Error [ERR_REQUIRE_ESM]: require() of ES Module G:\DB-GPT_7\web\node_modules\@antv\g2-extension-plot\node_modules\d3-hierarchy\src\index.js from G:\DB-GPT_7\web\node_modules\@antv\g2-extension-plot\lib\utils\hierarchy\partition.js not supported.
Instead change the require of index.js in G:\DB-GPT_7\web\node_modules\@antv\g2-extension-plot\lib\utils\hierarchy\partition.js to a dynamic import() which is available in all CommonJS modules.
    at Object.<anonymous> (G:\DB-GPT_7\web\node_modules\@antv\g2-extension-plot\lib\utils\hierarchy\partition.js:27:34) {
  code: 'ERR_REQUIRE_ESM'
}

> Build error occurred
Error: Failed to collect page data for /construct/knowledge/chunk
    at G:\DB-GPT_7\web\node_modules\next\dist\build\utils.js:1161:15
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
  type: 'Error'
}

What you expected to happen

构建成功

How to reproduce

拉取git,打开./web,运行 NODE_OPTIONS=--max_old_space_size=8192 next build

Additional context

No response

Are you willing to submit PR?

  • Yes I am willing to submit a PR!
@EdwinOlders11 EdwinOlders11 added bug Something isn't working Waiting for reply labels May 14, 2025
@chenliang15405
Copy link
Collaborator

Do you want to build web project? maybe web/README file can help you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Waiting for reply
Projects
None yet
Development

No branches or pull requests

2 participants