name: Martian Issue Triage on: issues: types: [opened, labeled] concurrency: group: triage-martian-${{ github.event.issue.number }} cancel-in-progress: true jobs: martian-issue-triage: if: | (github.event.action == 'opened' && github.actor == 'strawgate') || (github.event.action == 'labeled' && github.event.label.name == 'triage-martian') runs-on: ubuntu-latest timeout-minutes: 10 permissions: contents: read issues: write pull-requests: read id-token: write steps: - name: Checkout base repository uses: actions/checkout@v5 with: repository: ${{ github.repository }} ref: ${{ github.event.repository.default_branch }} # Install UV package manager - name: Install UV uses: astral-sh/setup-uv@v7 with: enable-cache: true cache-dependency-glob: "uv.lock" - name: Generate Marvin App token id: marvin-token uses: actions/create-github-app-token@v2 with: app-id: ${{ secrets.MARVIN_APP_ID }} private-key: ${{ secrets.MARVIN_APP_PRIVATE_KEY }} - name: Set triage prompt id: triage-prompt run: | cat >> $GITHUB_OUTPUT << 'EOF' PROMPT< and tags. You shouldn't put everything in collapsible sections, especially if the response is short. Use your discretion to determine when to use collapsible sections to avoid overwhelming the reader with too much detail -- think of them like an appendix that can be expanded if the reader is interested. # Example output for "Recommendation" part of the response PR #654 already implements the requested feature but is incomplete. The Pull Request is not in a mergeable state yet, the remaining work should be completed: 1) update the Calculator.divide method to utilize the new DivisionByZeroError or the safe_divide function, and 2) update the tests to ensure that the Calculator.divide method raises the new DivisionByZeroError when the divisor is 0.
Findings ...details from the code analysis that are relevant to the issue and the recommendation...
Detailed Action Plan ...a detailed plan that a junior developer could follow to implement the recommendation...
# Example Output for "Related Items" part of the response
Related Issues and Pull Requests | Repository | Issue or PR | Relevance | | --- | --- | --- | | jlowin/fastmcp | [Add matrix operations support](https://github.com/jlowin/fastmcp/pull/680) | This pull request directly addresses the feature request for adding matrix operations to the calculator. | | jlowin/fastmcp | [Add matrix operations support](https://github.com/jlowin/fastmcp/issues/681) | This issue directly addresses the feature request for adding matrix operations to the calculator. |
Related Files | Repository | File | Relevance | Sections | | --- | --- | --- | --- | | modelcontextprotocol/python-sdk | [test_calculator.py](https://github.com/modelcontextprotocol/python-sdk/blob/main/test_calculator.py) | This file contains the test cases for the Calculator class, including a test that specifically asserts a ValueError is raised for division by zero, confirming the current intended behavior. | [25-27](https://github.com/modelcontextprotocol/python-sdk/blob/main/test_calculator.py#L25-L27) | | modelcontextprotocol/python-sdk | [calculator.py](https://github.com/modelcontextprotocol/python-sdk/blob/main/calculator.py) | This file contains the implementation of the Calculator class, specifically the `divide` method which raises the ValueError when dividing by zero, matching the bug report. | [29-32](https://github.com/modelcontextprotocol/python-sdk/blob/main/calculator.py#L29-L32) |
Related Webpages | Name | URL | Relevance | | --- | --- | --- | | Handling Division by Zero Best Practices | https://my-blog-about-division-by-zero.com/handling+division+by+zero+in+calculator | This webpage provides general best practices for handling division by zero in calculator applications and in Python, which is directly relevant to the issue and potential solutions. |
PROMPT_END EOF - name: Setup GitHub MCP Server run: | mkdir -p /tmp/mcp-config cat > /tmp/mcp-config/mcp-servers.json << 'EOF' { "mcpServers": { "repository-summary": { "type": "http", "url": "https://agents-md-generator.fastmcp.app/mcp" }, "code-search": { "type": "http", "url": "https://public-code-search.fastmcp.app/mcp" }, "github-research": { "type": "stdio", "command": "uvx", "args": [ "github-research-mcp" ], "env": { "DISABLE_SUMMARIES": "true", "GITHUB_PERSONAL_ACCESS_TOKEN": "${{ steps.marvin-token.outputs.token }}" } } } } EOF - name: Run Martian for Issue Triage uses: anthropics/claude-code-action@v1 with: github_token: ${{ steps.marvin-token.outputs.token }} bot_name: "Marvin Context Protocol" prompt: ${{ steps.triage-prompt.outputs.PROMPT }} anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY_FOR_CI }} track_progress: true claude_args: | --model claude-sonnet-4-5-20250929 --allowedTools mcp__repository-summary,mcp__code-search__search_code,mcp__github-research__get_repository,mcp__github-research__get_issue,mcp__github-research__get_pull_request,mcp__github-research__search_issues,mcp__github-research__search_pull_requests,mcp__github-research__get_files --mcp-config /tmp/mcp-config/mcp-servers.json settings: | { "GH_TOKEN": "${{ steps.marvin-token.outputs.token }}" }