(session_id: str)
| 22 | |
| 23 | |
| 24 | def get_session_root(session_id: str) -> Path: |
| 25 | if not session_id or not str(session_id).strip(): |
| 26 | raise HTTPException(status_code=400, detail='session_id is required') |
| 27 | |
| 28 | backend_root = get_backend_root() |
| 29 | work_dir = (backend_root / 'work_dir' / str(session_id)).resolve() |
| 30 | work_dir.mkdir(parents=True, exist_ok=True) |
| 31 | return work_dir |
| 32 | |
| 33 | |
| 34 | # Request/Response Models |
no test coverage detected