infiniflow / infiniflow/ragflow

[Bug]: Source startup guide routes Python frontend requests to inactive Go backend

Open Beginner friendly
#19,600 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
91k
Forks
10.8k
Avg merge
1d 14h
Merged PRs (30d)
705

Description

Self Checks
  • I have searched for existing issues, including closed ones.
  • I confirm that I am using English to submit this report.
  • I understand that non-English titles may be closed directly.
  • I have provided the required environment and reproduction details.
RAGFlow workspace code commit ID

a024bea0cd93f39e6652a42bf84dd20c55bc560b

RAGFlow image version

N/A (source-code deployment based on v0.27.2)

Other environment information
  • Branch: support/v0.27.2
  • Deployment: RAGFlow started from source code
  • Backend: Python backend
  • Frontend: Vite development server (npm run dev)
  • Host environment: Linux in an unprivileged LXC container
  • Docker: Docker Compose is used only for dependency services
Actual behavior

When following the source startup instructions, the Python backend is started with:

python api/ragflow_server.py

The Python backend listens on 127.0.0.1:9380 and responds successfully. However, starting the frontend with:

cd web
npm run dev

causes requests such as /api/v1/chats to be proxied to 127.0.0.1:9384, resulting in:

[vite] http proxy error: /api/v1/chats?keywords=&page_size=50&page=1
Error: connect ECONNREFUSED 127.0.0.1:9384

The current web/.env.development contains:

API_PROXY_SCHEME='go'
Expected behavior

When following the Python source startup instructions, frontend API requests should be proxied to the Python backend on port 9380.

Alternatively, the documentation should clearly instruct users to start the Go backend when API_PROXY_SCHEME=go is used.

Steps to reproduce
  1. Check out a branch based on v0.27.2.
  2. Start the dependency services with Docker Compose.
  3. Start the Python backend and task executor from source.
  4. Run cd web && npm run dev.
  5. Open the frontend and trigger a request such as /api/v1/chats.
  6. Observe that Vite tries to connect to 127.0.0.1:9384, while the Python backend is listening on 127.0.0.1:9380.
Additional information

The source startup documentation still instructs users to update server.proxy.target in vite.config.ts, but the current Vite configuration uses proxySchemes selected by API_PROXY_SCHEME.

Suggested documentation fix:

cd web
API_PROXY_SCHEME=python npm run dev

The documentation should also clarify the difference between Python, Go, and hybrid backend startup modes.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with web/.env.development and web/vite.config.ts, then read the source startup documentation and api/ragflow_server.py startup command. Verify how API_PROXY_SCHEME selects the proxy target, test the frontend in Python mode, and confirm that the documentation distinguishes Python, Go, and hybrid startup modes.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, typescript, vite
Domain
backend, documentation, frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
75/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.