Commit 5f6dec4
committed
fix: normalize WebSocket URI path to prevent /task/service duplication
String concatenation in _get_websocket_uri produced malformed URLs in
two cases:
- If the URI already contained /task/service, it was appended again
- A trailing slash produced a double slash before /task/service
Fix: strip trailing slash, check for existing /task/service suffix,
then build the final URL with urlunparse instead of string formatting.
Added two parametrized test cases covering both failure modes.
Resolves #7551 parent d7b29aa commit 5f6dec4
2 files changed
Lines changed: 10 additions & 2 deletions
Lines changed: 6 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
314 | 314 | | |
315 | 315 | | |
316 | 316 | | |
317 | | - | |
318 | | - | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
319 | 323 | | |
320 | 324 | | |
321 | 325 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2370 | 2370 | | |
2371 | 2371 | | |
2372 | 2372 | | |
| 2373 | + | |
| 2374 | + | |
| 2375 | + | |
| 2376 | + | |
2373 | 2377 | | |
2374 | 2378 | | |
2375 | 2379 | | |
| |||
0 commit comments