这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@dexhorthy
Copy link
Contributor

@dexhorthy dexhorthy commented May 21, 2025

Important

Add annotations to MCP tools for metadata about behavior, update CRD, deepcopy functions, and tests, and update dependencies.

  • Annotations:
    • Add MCPToolAnnotations struct in mcpserver_types.go to provide metadata about tool behavior.
    • Update MCPTool struct to include Annotations field in mcpserver_types.go.
    • Update CRD in acp.humanlayer.dev_mcpservers.yaml to include annotations properties.
  • DeepCopy:
    • Add DeepCopy functions for MCPToolAnnotations in zz_generated.deepcopy.go.
    • Update DeepCopyInto for MCPTool to handle Annotations in zz_generated.deepcopy.go.
  • Tests:
    • Add tests for annotations in mcpserver_controller_test.go.
    • Update MockMCPClient in mcpmanager_test.go to handle annotations.
  • Dependencies:
    • Update go.mod and go.sum to use github.com/mark3labs/mcp-go v0.29.0 and other dependency updates.

This description was created by Ellipsis for 25d8c50. You can customize this summary. It will automatically update as commits are pushed.

@dexhorthy dexhorthy requested a review from allisoneer May 21, 2025 01:52
Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Changes requested ❌

Reviewed everything up to 25d8c50 in 2 minutes and 7 seconds. Click for details.
  • Reviewed 367 lines of code in 10 files
  • Skipped 0 files when reviewing.
  • Skipped posting 4 draft comments. View those below.
  • Modify your settings and rules to customize what types of comments Ellipsis leaves. And don't forget to react with 👍 or 👎 to teach Ellipsis.
1. acp/internal/mcpmanager/mcpmanager.go:159
  • Draft comment:
    Avoid using fmt.Printf for error reporting; use a structured logger (or controller-runtime's logging) for better log integration.
  • Reason this comment was not posted:
    Comment was not on a location in the diff, so it can't be submitted as a review comment.
2. acp/internal/mcpmanager/mcpmanager.go:169
  • Draft comment:
    Consider using the manager's logging facility instead of fmt.Printf for cleanup errors in the error branches when closing the client.
  • Reason this comment was not posted:
    Comment was not on a location in the diff, so it can't be submitted as a review comment.
3. acp/internal/mcpmanager/mcpmanager_test.go:472
  • Draft comment:
    Consider expanding unit tests to simulate error cases in ConnectServer (e.g., secret resolution failures) to improve coverage of error paths.
  • Reason this comment was not posted:
    Comment was not on a location in the diff, so it can't be submitted as a review comment.
4. acp/config/samples/mcp_github.yaml:1
  • Draft comment:
    There's a trailing whitespace after the apiVersion value on line 1. Please remove the extra space to keep the YAML clean.
  • Reason this comment was not posted:
    Decided after close inspection that this draft comment was likely wrong and/or not actionable: usefulness confidence = 10% vs. threshold = 50% While trailing whitespace is generally undesirable, it's an extremely minor issue. Most modern editors automatically strip trailing whitespace. This kind of nitpick doesn't require human attention and could be better handled by automated formatting tools or pre-commit hooks. It doesn't affect functionality or readability. The trailing whitespace could cause issues with some YAML parsers or diff tools. It's a valid style consistency concern. While technically correct, this is too minor of an issue to warrant a PR comment. If whitespace is important, it should be enforced through automation rather than manual review. Delete this comment as it's too trivial and would be better handled by automated tooling.

Workflow ID: wflow_tjZ1N0jD16JNNi7v

You can customize Ellipsis by changing your verbosity settings, reacting with 👍 or 👎, replying to comments, or adding code review rules.

}

// Create annotations based on tool properties
annotations := &acp.MCPToolAnnotations{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Potential nil pointer dereference: tool.Annotations is used without checking if it's nil. Consider adding a nil check before accessing its fields.

@dexhorthy dexhorthy closed this May 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant