Open kedarisetti opened 2 years ago
Hi @philippjfr , as per current implementation for processing the Video URL, we are only checking if provided URL contains valid media type at the end of the path after removing query parameters. for ex.: https://www.videoserver.com/watch/path/to/video.mp4
is a valid URL but https://www.videoserver.com/watch?v=/path/to/video.mp4
is not.
ref: https://github.com/holoviz/panel/blob/main/panel/util/checks.py#L37
If we try to get video resource URL from query parameter, then it'll be server specific implementation as another server may have resource path in any key of query parameter. Parsing query parameters for resource does not look right thing to me. What are your thoughts on this?
ALL software version info
Panel version '0.12.6' Python 3.9.2 OS Mac Monterey
Description of expected behavior and the observed behavior
when a given video URL contains query parameter, the URL is not recognized as an URL
Complete, minimal, self-contained example code that reproduces the issue
the following error is raised
Workaround
set
Video._formats = None
once you set the formats to None, the url passes the isUrl check