-
Notifications
You must be signed in to change notification settings - Fork 2
feat: update manifest parameters to accept YAML string or file path #18
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
feat: update manifest parameters to accept YAML string or file path #18
Conversation
- Replace dictionary/JSON manifest input with string-only input - Add parse_manifest_input utility function with auto-detection logic - Update validate_manifest, execute_stream_test_read, get_resolved_manifest, and populate_dotenv_missing_secrets_stubs functions - Rename manifest parameter to manifest_input for clarity - Support both raw YAML content and file path input - Update all tests to use new string-based API - Maintain backward compatibility through YAML conversion Co-Authored-By: AJ Steers <[email protected]>
Original prompt from AJ Steers
|
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
👋 Greetings, Airbyte Team Member!Here are some helpful tips and reminders for your convenience. Testing This Branch via MCPTo test the changes in this specific branch with an MCP client like Claude Desktop, use the following configuration: {
"mcpServers": {
"connector-builder-mcp-dev": {
"command": "uvx",
"args": ["--from", "git+https://github.com/airbytehq/connector-builder-mcp.git@devin/1754507432-yaml-path-manifest-support", "connector-builder-mcp"]
}
}
} Testing This Branch via CLIYou can test this version of the MCP Server using the following CLI snippet: # Run the CLI from this branch:
uvx 'git+https://github.com/airbytehq/connector-builder-mcp.git@devin/1754507432-yaml-path-manifest-support#egg=airbyte-connector-builder-mcp' --help PR Slash CommandsAirbyte Maintainers can execute the following slash commands on your PR:
|
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 updates the manifest parameters to accept string input (either raw YAML content or file path) instead of dictionary input, eliminating the need for JSON conversion and reducing context window usage.
- Implements auto-detection logic to distinguish between file paths and raw YAML content
- Updates four main functions to use
manifest_input: str
parameter instead ofmanifest: dict[str, Any]
- Converts all test fixtures and assertions to use the new string-based API
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.
Show a summary per file
File | Description |
---|---|
connector_builder_mcp/_util.py | Adds parse_manifest_input() utility function with auto-detection logic |
connector_builder_mcp/_connector_builder.py | Updates three main functions to use string manifest input |
connector_builder_mcp/_secrets.py | Updates populate_dotenv_missing_secrets_stubs() to use string manifest input |
tests/test_integration.py | Converts test fixtures from YAML objects to file paths or YAML strings |
tests/test_secrets.py | Updates test calls to use YAML strings instead of dictionaries |
- Fix long line formatting in Field descriptions - Update string quotes to double quotes for consistency - Add proper line breaks for long error messages - Add blank lines after import statements in tests Co-Authored-By: AJ Steers <[email protected]>
Co-authored-by: Copilot <[email protected]>
- Move import yaml from inside test functions to module level - Addresses @aaronsteers feedback on PR #18 - Follows Python best practices for import organization Co-Authored-By: AJ Steers <[email protected]>
- Revert parameter names in all affected functions as requested by @aaronsteers - Keep string input functionality and auto-detection logic intact - Update function signatures, docstrings, and internal variable references - Update test function calls and assertion messages - Fix OSError handling in parse_manifest_input for YAML strings - Addresses GitHub PR feedback on #18 Co-Authored-By: AJ Steers <[email protected]>
…-path-manifest-support
- Remove config parameter from all validate_manifest test calls - Function now only accepts manifest parameter (YAML string or file path) - Remove unused config variables that were causing linting errors - All 63 tests now pass locally with clean linting checks - Fixes TypeError: validate_manifest() takes 1 positional argument but 2 were given Co-Authored-By: AJ Steers <[email protected]>
- Fix Field description formatting to use proper multi-line style - Resolves Ruff Format Check CI failure - All local checks now pass (ruff, mypy, pytest) Co-Authored-By: AJ Steers <[email protected]>
fix: revert parameter names from manifest_input to manifest
Summary
This PR reverts parameter names from
manifest_input
back tomanifest
across all affected functions in the connector builder MCP server, as requested by @aaronsteers in PR feedback. The changes maintain the string input functionality that accepts either raw YAML content or file paths while restoring the original parameter naming convention.Key Changes:
validate_manifest()
,execute_stream_test_read()
,get_resolved_manifest()
, andpopulate_dotenv_missing_secrets_stubs()
parse_manifest_input()
to properly catch "File name too long" errors when YAML strings are mistaken for file pathsThe core auto-detection logic that distinguishes between YAML strings and file paths remains unchanged, preserving the context window optimization benefits for LLMs.
Review & Testing Checklist for Human
manifest
parameter name (no lingeringmanifest_input
references)Recommended Test Plan:
Diagram
Notes
Important
Auto-merge enabled.
This PR is set to merge automatically when all requirements are met.