Skip to content

Commit cb06bd6

Browse files
yeldarbyclaude
andcommitted
fix(cli): fix video status param name and universe search limit
- video status: API expects `job_id` not `jobId` as query param - universe search: API ignores `limit` param, enforce client-side truncation Verified both fixes against staging API. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 068cd78 commit cb06bd6

3 files changed

Lines changed: 5 additions & 2 deletions

File tree

roboflow/adapters/rfapi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -780,7 +780,7 @@ def get_labeling_stats(api_key, workspace_url, *, start_date=None, end_date=None
780780

781781
def get_video_job_status(api_key, job_id):
782782
"""GET /videoinfer?jobId={id} — check video inference job status."""
783-
response = requests.get(f"{API_URL}/videoinfer", params={"api_key": api_key, "jobId": job_id})
783+
response = requests.get(f"{API_URL}/videoinfer", params={"api_key": api_key, "job_id": job_id})
784784
if response.status_code != 200:
785785
raise RoboflowError(response.text)
786786
return response.json()

roboflow/cli/handlers/universe.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@ def _search(args: argparse.Namespace) -> None:
3939
return
4040

4141
results = data.get("results", [])
42+
# The API may ignore the limit param; enforce it client-side
43+
if args.limit and len(results) > args.limit:
44+
results = results[: args.limit]
4245
rows = []
4346
for r in results:
4447
rows.append(

tests/adapters/test_rfapi_phase2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -496,7 +496,7 @@ def test_success(self, mock_get):
496496
result = get_video_job_status("key", "job-123")
497497
self.assertEqual(result["status"], "completed")
498498
call_kwargs = mock_get.call_args[1]
499-
self.assertEqual(call_kwargs["params"]["jobId"], "job-123")
499+
self.assertEqual(call_kwargs["params"]["job_id"], "job-123")
500500

501501
@patch("roboflow.adapters.rfapi.requests.get")
502502
def test_error(self, mock_get):

0 commit comments

Comments
 (0)