-
Notifications
You must be signed in to change notification settings - Fork 6
fix: cannot find image reference when copying remote server #1037
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
fix: cannot find image reference when copying remote server #1037
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes a bug where copying remote servers to a group would fail because the API call was incorrectly including an image
field for remote servers. The fix conditionally structures the request payload based on whether the server is remote (uses url
) or local (uses image
).
Key Changes
- Conditional payload structure in
useCopyServerToGroup
hook to handle remote vs local servers differently - Added test coverage for the remote server copy scenario to ensure the fix works correctly
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
File | Description |
---|---|
renderer/src/features/mcp-servers/hooks/use-copy-server-to-group.ts |
Restructured the createWorkload payload to conditionally include either remote server fields (url, oauth_config) or local server fields (image, volumes, cmd_arguments) |
renderer/src/features/mcp-servers/hooks/__tests__/use-copy-server-to-group.test.tsx |
Added comprehensive test to verify that remote servers are copied with the correct payload structure |
renderer/src/features/mcp-servers/hooks/use-copy-server-to-group.ts
Outdated
Show resolved
Hide resolved
…nces-groups-feature-maybe
fixes the bug that was mentioned here: https://stacklok.slack.com/archives/C091GRYAG49/p1760022742218379?thread_ts=1760003349.102839&cid=C091GRYAG49