Skip to content

Commit 1a72bfa

Browse files
authored
Merge branch 'main' into main
2 parents 6575768 + 94b1eb9 commit 1a72bfa

File tree

119 files changed

+5776
-2547
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

119 files changed

+5776
-2547
lines changed

.github/pull_request_template.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
## Description
2+
<!--
3+
Please provide a clear and concise description of the changes made in this pull request.
4+
5+
Using AI to generate code? Please include a note in the description with which AI tool you used.
6+
-->
7+
8+
**Contributors Checklist**
9+
<!--
10+
NOTE:
11+
1. You must create an issue in the repository before making a Pull Request.
12+
2. You must not create a Pull Request for an issue that is already assigned to someone else.
13+
14+
If you do not follow these steps, your Pull Request will be closed without review.
15+
-->
16+
17+
- [ ] My change is related to issue #(issue number)
18+
- [ ] I have followed the repository's development workflow
19+
- [ ] I have tested my changes manually and by adding relevant tests
20+
- [ ] I have performed all required documentation updates
21+
22+
**Review Checklist**
23+
<!-- Your Pull Request will not be reviewed if tests are failing, you have not self-reviewed your changes, or you have not checked all of the following: -->
24+
25+
- [ ] I have self-reviewed my changes
26+
- [ ] My Pull Request is ready for review
27+
28+
---

.github/workflows/auto-close-duplicates.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,10 @@ jobs:
1515

1616
steps:
1717
- name: Checkout repository
18-
uses: actions/checkout@v4
18+
uses: actions/checkout@v5
1919

2020
- name: Install uv
21-
uses: astral-sh/setup-uv@v4
21+
uses: astral-sh/setup-uv@v6
2222

2323
- name: Auto-close duplicate issues
2424
run: uv run scripts/auto_close_duplicates.py

.github/workflows/marvin-dedupe-issues.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020

2121
steps:
2222
- name: Checkout repository
23-
uses: actions/checkout@v4
23+
uses: actions/checkout@v5
2424

2525
- name: Generate Marvin App token
2626
id: marvin-token
@@ -45,7 +45,7 @@ jobs:
4545
4646
4. Next, feed the results from steps 2 and 3 into another agent using the Task tool, so that it can filter out false positives that are likely not actually duplicates of the original issue. If there are no duplicates remaining, do not proceed.
4747
48-
5. Finally, comment back on the issue with a list of up to three duplicate issues (or zero, if there are no likely duplicates)
48+
5. Finally, comment back on the issue with a list of up to three duplicate issues (or zero, if there are no likely duplicates). If there are no duplicates, DO NOT COMMENT. Just exit.
4949
5050
Notes for your agents:
5151
- Use `gh` to interact with GitHub, rather than web fetch
@@ -72,8 +72,9 @@ jobs:
7272
- name: Run Marvin dedupe command
7373
uses: anthropics/claude-code-base-action@beta
7474
with:
75+
model: claude-3-5-haiku-latest
7576
prompt_file: /tmp/claude-prompts/dedupe-prompt.txt
7677
allowed_tools: "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh api:*),Bash(gh issue comment:*),Task"
77-
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
78+
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY_FOR_CI }}
7879
claude_env: |
7980
GH_TOKEN: ${{ steps.marvin-token.outputs.token }}

.github/workflows/marvin-label-triage.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727

2828
steps:
2929
- name: Checkout base repository
30-
uses: actions/checkout@v4
30+
uses: actions/checkout@v5
3131
with:
3232
repository: ${{ github.repository }}
3333
ref: ${{ github.event.repository.default_branch }}
@@ -151,7 +151,7 @@ jobs:
151151
prompt_file: /tmp/claude-prompts/triage-prompt.txt
152152
allowed_tools: "Bash(gh label list),mcp__github__get_issue,mcp__github__get_issue_comments,mcp__github__update_issue,mcp__github__get_pull_request_files"
153153
timeout_minutes: "5"
154-
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
154+
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY_FOR_CI }}
155155
mcp_config: /tmp/mcp-config/mcp-servers.json
156156
claude_env: |
157157
GH_TOKEN: ${{ steps.marvin-token.outputs.token }}

.github/workflows/marvin.yml

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -31,24 +31,18 @@ jobs:
3131
(github.event_name == 'issues' && github.event.action == 'labeled' && github.event.label.name == 'marvin')
3232
runs-on: ubuntu-latest
3333
steps:
34-
- uses: actions/checkout@v4
35-
36-
# Set up Python environment
37-
- name: Set up Python
38-
uses: actions/setup-python@v5
39-
with:
40-
python-version: "3.12"
34+
- uses: actions/checkout@v5
4135

4236
# Install UV package manager
4337
- name: Install UV
44-
uses: astral-sh/setup-uv@v5
38+
uses: astral-sh/setup-uv@v6
4539
with:
4640
enable-cache: true
4741
cache-dependency-glob: "uv.lock"
4842

4943
# Install project dependencies
5044
- name: Install dependencies
51-
run: uv sync --dev
45+
run: uv sync --python 3.12
5246

5347
# Install pre-commit hooks automatically
5448
- name: Install pre-commit hooks

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
id-token: write # For PyPI's trusted publishing
1313
steps:
1414
- name: Checkout
15-
uses: actions/checkout@v4
15+
uses: actions/checkout@v5
1616
with:
1717
fetch-depth: 0
1818

.github/workflows/run-static.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
runs-on: ubuntu-latest
3131

3232
steps:
33-
- uses: actions/checkout@v4
33+
- uses: actions/checkout@v5
3434
- name: Install uv
3535
uses: astral-sh/setup-uv@v6
3636
with:

.github/workflows/run-tests.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
timeout-minutes: 5
3535

3636
steps:
37-
- uses: actions/checkout@v4
37+
- uses: actions/checkout@v5
3838

3939
- name: Install uv
4040
uses: astral-sh/setup-uv@v6
@@ -48,18 +48,18 @@ jobs:
4848
run: uv sync --frozen
4949

5050
- name: Run tests (excluding integration and client_process)
51-
run: uv run pytest tests -m "not integration and not client_process"
51+
run: uv run pytest -v tests -m "not integration and not client_process"
5252

5353
- name: Run client process tests separately
54-
run: uv run pytest tests -m "client_process" -x
54+
run: uv run pytest -v tests -m "client_process" -x
5555

5656
run_integration_tests:
5757
name: "Run integration tests"
5858
runs-on: ubuntu-latest
5959
timeout-minutes: 10
6060

6161
steps:
62-
- uses: actions/checkout@v4
62+
- uses: actions/checkout@v5
6363

6464
- name: Install uv
6565
uses: astral-sh/setup-uv@v6
@@ -73,7 +73,7 @@ jobs:
7373
run: uv sync --frozen
7474

7575
- name: Run integration tests
76-
run: uv run pytest tests -m "integration"
76+
run: uv run pytest -v tests -m "integration"
7777
env:
7878
FASTMCP_GITHUB_TOKEN: ${{ secrets.FASTMCP_GITHUB_TOKEN }}
7979
FASTMCP_TEST_AUTH_GITHUB_CLIENT_ID: ${{ secrets.FASTMCP_TEST_AUTH_GITHUB_CLIENT_ID }}
Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
name: Update FastMCPConfig Schema
2+
3+
# This workflow runs on merges to main to automatically update the config schema
4+
# by creating a PR when changes are needed.
5+
6+
on:
7+
push:
8+
branches: ["main"]
9+
paths:
10+
- "src/fastmcp/utilities/fastmcp_config/**"
11+
- "!src/fastmcp/utilities/fastmcp_config/v1/schema.json" # Exclude the local schema file
12+
workflow_dispatch:
13+
14+
permissions:
15+
contents: write
16+
pull-requests: write
17+
18+
jobs:
19+
update-config-schema:
20+
timeout-minutes: 5
21+
runs-on: ubuntu-latest
22+
23+
steps:
24+
- uses: actions/checkout@v5
25+
26+
- name: Generate Marvin App token
27+
id: marvin-token
28+
uses: actions/create-github-app-token@v2
29+
with:
30+
app-id: ${{ secrets.MARVIN_APP_ID }}
31+
private-key: ${{ secrets.MARVIN_APP_PRIVATE_KEY }}
32+
33+
- name: Install uv
34+
uses: astral-sh/setup-uv@v6
35+
with:
36+
enable-cache: true
37+
cache-dependency-glob: "uv.lock"
38+
39+
- name: Install dependencies
40+
run: uv sync --python 3.12
41+
42+
- name: Generate config schema
43+
run: |
44+
echo "🔄 Generating fastmcp.json schema..."
45+
46+
# Generate schema in docs/public for web access
47+
uv run python -c "
48+
from fastmcp.utilities.fastmcp_config import generate_schema
49+
generate_schema('docs/public/schemas/fastmcp.json/latest.json')
50+
print('✅ Latest schema generated in docs/public')
51+
"
52+
53+
# Also update the v1 schema in docs/public
54+
uv run python -c "
55+
from fastmcp.utilities.fastmcp_config import generate_schema
56+
generate_schema('docs/public/schemas/fastmcp.json/v1.json')
57+
print('✅ v1 schema generated in docs/public')
58+
"
59+
60+
# Generate schema in the source directory for local development
61+
uv run python -c "
62+
from fastmcp.utilities.fastmcp_config import generate_schema
63+
generate_schema('src/fastmcp/utilities/fastmcp_config/v1/schema.json')
64+
print('✅ Schema generated in utilities/fastmcp_config/v1/')
65+
"
66+
67+
- name: Create Pull Request
68+
uses: peter-evans/create-pull-request@v7
69+
with:
70+
token: ${{ steps.marvin-token.outputs.token }}
71+
commit-message: "chore: Update fastmcp.json schema"
72+
title: "chore: Update fastmcp.json schema"
73+
body: |
74+
This PR updates the fastmcp.json schema files to match the current source code.
75+
76+
The schema is automatically generated from `src/fastmcp/utilities/fastmcp_config/` to ensure consistency.
77+
78+
**Note:** This PR is fully automated and will update itself with any subsequent changes to the schema, or close automatically if the schema becomes up-to-date through other means. Feel free to leave it open until you're ready to merge.
79+
80+
🤖 Generated by Marvin
81+
branch: marvin/update-config-schema
82+
delete-branch: true
83+
author: "marvin-context-protocol[bot] <225465937+marvin-context-protocol[bot]@users.noreply.github.com>"
84+
committer: "marvin-context-protocol[bot] <225465937+marvin-context-protocol[bot]@users.noreply.github.com>"
85+
86+
- name: Summary
87+
run: |
88+
echo "✅ Config schema generation workflow completed"
89+
echo "PR will be created if there are changes, or closed if schema is already up to date"
Lines changed: 26 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
name: Update SDK Documentation
22

33
# This workflow runs on merges to main to automatically update SDK docs
4-
# without blocking PRs. SDK doc generation can fail if another PR merges
5-
# first, so handling it post-merge prevents annoying CI failures for contributors.
4+
# by creating a PR when changes are needed.
65

76
on:
87
push:
@@ -22,23 +21,23 @@ jobs:
2221
runs-on: ubuntu-latest
2322

2423
steps:
25-
- uses: actions/checkout@v4
24+
- uses: actions/checkout@v5
25+
26+
- name: Generate Marvin App token
27+
id: marvin-token
28+
uses: actions/create-github-app-token@v2
2629
with:
27-
token: ${{ secrets.GITHUB_TOKEN }}
30+
app-id: ${{ secrets.MARVIN_APP_ID }}
31+
private-key: ${{ secrets.MARVIN_APP_PRIVATE_KEY }}
2832

2933
- name: Install uv
3034
uses: astral-sh/setup-uv@v6
3135
with:
3236
enable-cache: true
3337
cache-dependency-glob: "uv.lock"
3438

35-
- name: Set up Python
36-
uses: actions/setup-python@v5
37-
with:
38-
python-version: "3.12"
39-
4039
- name: Install dependencies
41-
run: uv sync --dev
40+
run: uv sync --python 3.12
4241

4342
- name: Install just
4443
uses: extractions/setup-just@v3
@@ -48,34 +47,26 @@ jobs:
4847
echo "🔄 Generating SDK documentation..."
4948
just api-ref-all
5049
51-
- name: Check for changes
52-
id: check_changes
53-
run: |
54-
if git diff --quiet docs/python-sdk/ docs/docs.json; then
55-
echo "No changes detected in SDK documentation"
56-
echo "has_changes=false" >> $GITHUB_OUTPUT
57-
else
58-
echo "Changes detected in SDK documentation"
59-
echo "has_changes=true" >> $GITHUB_OUTPUT
60-
fi
50+
- name: Create Pull Request
51+
uses: peter-evans/create-pull-request@v7
52+
with:
53+
token: ${{ steps.marvin-token.outputs.token }}
54+
commit-message: "chore: Update SDK documentation"
55+
title: "chore: Update SDK documentation"
56+
body: |
57+
This PR updates the auto-generated SDK documentation to reflect the latest source code changes.
6158
62-
- name: Commit and push changes
63-
if: steps.check_changes.outputs.has_changes == 'true'
64-
run: |
65-
git config --local user.email "[email protected]"
66-
git config --local user.name "GitHub Action"
67-
git add docs/python-sdk/ docs/docs.json
68-
git commit -m "chore: Update SDK documentation
59+
📚 Documentation is automatically generated from the source code docstrings and type annotations.
6960
70-
🤖 Generated with [Claude Code](https://claude.ai/code)
61+
**Note:** This PR is fully automated and will update itself with any subsequent changes to the SDK, or close automatically if the documentation becomes up-to-date through other means. Feel free to leave it open until you're ready to merge.
7162
72-
Co-Authored-By: Claude <[email protected]>"
73-
git push
63+
🤖 Generated by Marvin
64+
branch: marvin/update-sdk-docs
65+
delete-branch: true
66+
author: "marvin-context-protocol[bot] <225465937+marvin-context-protocol[bot]@users.noreply.github.com>"
67+
committer: "marvin-context-protocol[bot] <225465937+marvin-context-protocol[bot]@users.noreply.github.com>"
7468

7569
- name: Summary
7670
run: |
77-
if [ "${{ steps.check_changes.outputs.has_changes }}" == "true" ]; then
78-
echo "✅ SDK documentation updated and committed"
79-
else
80-
echo "✅ SDK documentation is already up to date"
81-
fi
71+
echo "✅ SDK documentation generation workflow completed"
72+
echo "PR will be created if there are changes, or closed if documentation is already up to date"

0 commit comments

Comments
 (0)