Skip to content

Fix: pass mcp to useExportMcp for correct JSON export filename - #16564

Merged
wangq8 merged 1 commit into
infiniflow:mainfrom
dcc123456:fix/bug-mcp
Jul 2, 2026
Merged

wangq8 merged 1 commit into
infiniflow:mainfrom
dcc123456:fix/bug-mcp

Conversation

@dcc123456

Copy link
Copy Markdown
Collaborator

Summary

Fix: pass mcp to useExportMcp for correct JSON export filename

@dosubot dosubot Bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Jul 2, 2026
@dcc123456
dcc123456 marked this pull request as draft July 2, 2026 07:35
@dcc123456
dcc123456 marked this pull request as ready for review July 2, 2026 07:35
@coderabbitai

coderabbitai Bot commented Jul 2, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: bcfb2fa1-8236-4362-be74-e4ae53de0d1b

📥 Commits

Reviewing files that changed from the base of the PR and between 404ef4c and 41e32e2.

📒 Files selected for processing (2)
  • web/src/pages/user-setting/mcp/mcp-operation.tsx
  • web/src/pages/user-setting/mcp/use-export-mcp.ts

📝 Walkthrough

Walkthrough

The useExportMcp hook now requires an IMcpServer argument, used to name the exported JSON file based on mcp.name (falling back to mcp), and only exports when mcp is present. mcp-operation.tsx updates its call site accordingly.

Changes

MCP Export Filename Update

Layer / File(s) Summary
Hook parameterization and caller update
web/src/pages/user-setting/mcp/use-export-mcp.ts, web/src/pages/user-setting/mcp/mcp-operation.tsx
useExportMcp now accepts an IMcpServer argument, requires it before exporting, and names the downloaded file using mcp.name (or "mcp" as fallback); mcp-operation.tsx passes the current mcp instance into the hook.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Poem

A rabbit hops with a file so bright,
Named just right, no more "mcp.json" plight,
One little mcp, passed with care,
Now every export knows whose name to wear! 🐇📄

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly matches the main change: passing mcp into useExportMcp to fix the exported JSON filename.
Description check ✅ Passed The description includes the required Summary section and states the fix, though it is brief and lacks extra background context.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@dcc123456
dcc123456 requested a review from wangq8 July 2, 2026 07:35
@wangq8
wangq8 merged commit 2ef7818 into infiniflow:main Jul 2, 2026
9 checks passed
xugangqiang pushed a commit to xugangqiang/ragflow that referenced this pull request Jul 3, 2026
xugangqiang pushed a commit to xugangqiang/ragflow that referenced this pull request Jul 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S This PR changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants