Commit 51e6a9a
committed
Fix test failures from httpx_client API changes
This commit fixes all test failures introduced by the API change from
httpx_client_factory to direct httpx_client parameter:
1. Updated deprecated imports: Changed streamablehttp_client to
streamable_http_client in test files
2. Fixed 307 redirect errors: Replaced httpx.AsyncClient with
create_mcp_http_client which includes follow_redirects=True by default
3. Fixed test assertion: Updated test_session_group.py to mock
create_mcp_http_client and verify the new API signature where
streamable_http_client receives httpx_client parameter instead of
individual headers/timeout parameters
4. Removed unused httpx import from main.py after inlining client creation
All tests now pass with the new API.1 parent 8196fec commit 51e6a9a
File tree
4 files changed
+42
-11
lines changed- examples/clients/simple-auth-client/mcp_simple_auth_client
- tests
- client
4 files changed
+42
-11
lines changedLines changed: 0 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | | - | |
20 | 18 | | |
21 | 19 | | |
22 | 20 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
| 21 | + | |
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| |||
127 | 127 | | |
128 | 128 | | |
129 | 129 | | |
130 | | - | |
| 130 | + | |
131 | 131 | | |
132 | 132 | | |
133 | 133 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
292 | 292 | | |
293 | 293 | | |
294 | 294 | | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
295 | 309 | | |
296 | 310 | | |
297 | 311 | | |
| |||
354 | 368 | | |
355 | 369 | | |
356 | 370 | | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
357 | 384 | | |
358 | 385 | | |
359 | | - | |
360 | | - | |
361 | | - | |
| 386 | + | |
362 | 387 | | |
363 | 388 | | |
364 | 389 | | |
| |||
382 | 407 | | |
383 | 408 | | |
384 | 409 | | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | | - | |
31 | 30 | | |
32 | 31 | | |
33 | 32 | | |
| |||
41 | 40 | | |
42 | 41 | | |
43 | 42 | | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| |||
1539 | 1539 | | |
1540 | 1540 | | |
1541 | 1541 | | |
1542 | | - | |
| 1542 | + | |
1543 | 1543 | | |
1544 | 1544 | | |
1545 | 1545 | | |
| |||
1577 | 1577 | | |
1578 | 1578 | | |
1579 | 1579 | | |
1580 | | - | |
1581 | | - | |
| 1580 | + | |
| 1581 | + | |
| 1582 | + | |
| 1583 | + | |
| 1584 | + | |
| 1585 | + | |
1582 | 1586 | | |
1583 | 1587 | | |
1584 | 1588 | | |
| |||
0 commit comments