Skip to content

Commit f4842cd

Browse files
authored
Fix ty 0.0.14 compatibility and upgrade dependencies (#3027)
1 parent 46e0e01 commit f4842cd

5 files changed

Lines changed: 284 additions & 274 deletions

File tree

.github/workflows/run-static.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ jobs:
2929
steps:
3030
- uses: actions/checkout@v6
3131

32-
- uses: ./.github/actions/setup-uv
32+
- name: Setup uv
33+
uses: ./.github/actions/setup-uv
3334
with:
3435
resolution: locked
3536

.github/workflows/run-tests.yml

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -38,14 +38,17 @@ jobs:
3838
steps:
3939
- uses: actions/checkout@v6
4040

41-
- uses: ./.github/actions/setup-uv
41+
- name: Setup uv
42+
uses: ./.github/actions/setup-uv
4243
with:
4344
python-version: ${{ matrix.python-version }}
4445
resolution: locked
4546

46-
- uses: ./.github/actions/run-pytest
47+
- name: Run unit tests
48+
uses: ./.github/actions/run-pytest
4749

48-
- uses: ./.github/actions/run-pytest
50+
- name: Run client process tests
51+
uses: ./.github/actions/run-pytest
4952
with:
5053
test-type: client_process
5154

@@ -57,13 +60,16 @@ jobs:
5760
steps:
5861
- uses: actions/checkout@v6
5962

60-
- uses: ./.github/actions/setup-uv
63+
- name: Setup uv (lowest-direct)
64+
uses: ./.github/actions/setup-uv
6165
with:
6266
resolution: lowest-direct
6367

64-
- uses: ./.github/actions/run-pytest
68+
- name: Run unit tests
69+
uses: ./.github/actions/run-pytest
6570

66-
- uses: ./.github/actions/run-pytest
71+
- name: Run client process tests
72+
uses: ./.github/actions/run-pytest
6773
with:
6874
test-type: client_process
6975

@@ -75,11 +81,13 @@ jobs:
7581
steps:
7682
- uses: actions/checkout@v6
7783

78-
- uses: ./.github/actions/setup-uv
84+
- name: Setup uv
85+
uses: ./.github/actions/setup-uv
7986
with:
8087
resolution: locked
8188

82-
- uses: ./.github/actions/run-pytest
89+
- name: Run integration tests
90+
uses: ./.github/actions/run-pytest
8391
with:
8492
test-type: integration
8593
env:

.github/workflows/run-upgrade-checks.yml

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ jobs:
3232
steps:
3333
- uses: actions/checkout@v6
3434

35-
- uses: ./.github/actions/setup-uv
35+
- name: Setup uv (upgrade)
36+
uses: ./.github/actions/setup-uv
3637
with:
3738
resolution: upgrade
3839

@@ -57,14 +58,17 @@ jobs:
5758
steps:
5859
- uses: actions/checkout@v6
5960

60-
- uses: ./.github/actions/setup-uv
61+
- name: Setup uv (upgrade)
62+
uses: ./.github/actions/setup-uv
6163
with:
6264
python-version: ${{ matrix.python-version }}
6365
resolution: upgrade
6466

65-
- uses: ./.github/actions/run-pytest
67+
- name: Run unit tests
68+
uses: ./.github/actions/run-pytest
6669

67-
- uses: ./.github/actions/run-pytest
70+
- name: Run client process tests
71+
uses: ./.github/actions/run-pytest
6872
with:
6973
test-type: client_process
7074

@@ -76,11 +80,13 @@ jobs:
7680
steps:
7781
- uses: actions/checkout@v6
7882

79-
- uses: ./.github/actions/setup-uv
83+
- name: Setup uv (upgrade)
84+
uses: ./.github/actions/setup-uv
8085
with:
8186
resolution: upgrade
8287

83-
- uses: ./.github/actions/run-pytest
88+
- name: Run integration tests
89+
uses: ./.github/actions/run-pytest
8490
with:
8591
test-type: integration
8692
env:

tests/server/test_dependencies.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ async def get_user_id() -> int:
6767
return 42
6868

6969
@mcp.tool()
70-
async def greet_user(name: str, user_id: int = Depends(get_user_id)) -> str: # type: ignore[assignment]
70+
async def greet_user(name: str, user_id: int = Depends(get_user_id)) -> str:
7171
return f"Hello {name}, your ID is {user_id}"
7272

7373
result = await mcp.call_tool("greet_user", {"name": "Alice"})
@@ -198,7 +198,7 @@ async def fetch_config() -> str:
198198
return "loaded_config"
199199

200200
@mcp.tool()
201-
def process_data(value: int, config: str = Depends(fetch_config)) -> str: # type: ignore[assignment]
201+
def process_data(value: int, config: str = Depends(fetch_config)) -> str:
202202
return f"Processing {value} with {config}"
203203

204204
result = await mcp.call_tool("process_data", {"value": 100})

0 commit comments

Comments
 (0)