mirror of
https://github.com/Comfy-Org/ComfyUI.git
synced 2026-08-22 01:03:33 +08:00
Add an optional comma-separated `ids` query parameter to GET /api/jobs so a caller can poll a known set of jobs in a single request instead of one call per job. The filter narrows the result to the requested job ids and composes with the existing status / workflow_id filters; an absent or empty `ids` means no filter. The handler caps the request at 100 ids (checked before validation) and validates each id with the existing validate_job_id helper, returning HTTP 400 on overflow or a malformed id. get_all_jobs gains an optional ids argument that narrows the normalized job list by id. Adds unit coverage for the filter logic and the endpoint's validation contract.
Pytest Unit Tests
Install test dependencies
pip install -r tests-unit/requirements.txt
Run tests
pytest tests-unit/