fix route framereader when using signed urls (#21029)

pull/21040/head
Willem Melching 2021-05-26 11:36:53 +02:00 committed by GitHub
parent 6340c2a996
commit 476ee91845
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ class RouteFrameReader(object):
will also be used for frame position indices.
"""
if not isinstance(camera_paths, dict):
camera_paths = {int(k.split('/')[-2]):k for k in camera_paths}
camera_paths = {int(k.split('?')[0].split('/')[-2]): k for k in camera_paths}
self._first_camera_idx = min(key for key, value in camera_paths.items() if value is not None)
self._frame_readers = _FrameReaderDict(camera_paths, cache_paths, kwargs)