Skip to content

Commit f7c9000

Browse files
committed
set default job_id
1 parent 9fc7110 commit f7c9000

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

roboflow/models/inference.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ def poll_for_video_results(self, job_id: Optional[str] = None) -> dict:
302302
if job_id is None:
303303
job_id = self.job_id
304304

305-
url = urljoin(API_URL, "/videoinfer/?api_key=" + self.__api_key + "&job_id=" + self.job_id)
305+
url = urljoin(API_URL, "/videoinfer/?api_key=" + self.__api_key + "&job_id=" + job_id)
306306
try:
307307
response = requests.get(url, headers={"Content-Type": "application/json"})
308308
except Exception as e:
@@ -354,7 +354,7 @@ def poll_until_video_results(self, job_id) -> dict:
354354
while True:
355355
time.sleep(60)
356356
print(f"({attempts * 60}s): Checking for inference results")
357-
response = self.poll_for_video_results()
357+
response = self.poll_for_video_results(job_id)
358358
attempts += 1
359359

360360
if response != {}:

0 commit comments

Comments
 (0)