NEW 264325
run-minibrowser --help seems incorrect about url-loading
https://bugs.webkit.org/show_bug.cgi?id=264325
Summary run-minibrowser --help seems incorrect about url-loading
Karl Dubost
Reported 2023-11-06 23:59:29 PST
Currently the help indicates that you can do run-minibrowser http://example.org/ That is not true. It requires run-minibrowser --url http://example.org/ This is an easy fix.
Attachments
Karl Dubost
Comment 1 2023-11-06 23:59:55 PST
Karl Dubost
Comment 2 2023-11-07 02:50:52 PST
% run-minibrowser http://example.com options Namespace(platform='mac', configuration=None, architecture=None, model=None, url='http://example.com') % run-minibrowser --url http://example.com options Namespace(platform='mac', configuration=None, architecture=None, model=None, url='http://example.com') so far so good. But the example of the help menu says: MiniBrowser options: Pass them after two dashes. Example: run-minibrowser --wpe -- --platform=drm http://url.com Let's try: % run-minibrowser --wpe -- --platform=drm http://example.com options Namespace(platform='wpe', configuration=None, architecture=None, model=None, url='--platform=drm') This is not good. This is not what we are expecting. same with --url % run-minibrowser --wpe -- --platform=drm --url http://example.com options Namespace(platform='wpe', configuration=None, architecture=None, model=None, url='--platform=drm') This is slightly better % run-minibrowser http://example.com -- --platform=drm options Namespace(platform='mac', configuration=None, architecture=None, model=None, url='http://example.com') % run-minibrowser http://example.com -- --platform=drm options Namespace(platform='mac', configuration=None, architecture=None, model=None, url='http://example.com') % run-minibrowser http://example.com --platform=drm options Namespace(platform='drm', configuration=None, architecture=None, model=None, url='http://example.com') So there are issues with the current parsing of arguments. Note: Replace url.com by example.org in all examples.
Karl Dubost
Comment 3 2023-11-07 03:11:07 PST
Philippe Normand
Comment 4 2023-11-07 14:08:43 PST
run-minibrowser --wpe http://example.com -- --platform=drm ?
Philippe Normand
Comment 5 2023-11-07 14:10:28 PST
> Example: run-minibrowser --wpe -- --platform=drm http://url.com That example looks incorrect. The url should be before --
Michael Catanzaro
Comment 6 2023-11-07 15:51:17 PST
(In reply to Philippe Normand from comment #5) > That example looks incorrect. The url should be before -- I guess the -- is used to indicate the end of the list of arguments to run-minibrowser and start the list of arguments to MiniBrowser itself. And the URL to load is surely an argument for MiniBrowser. So I think Karl is probably right that the example matches the intended behavior?
Karl Dubost
Comment 7 2023-11-07 17:40:51 PST
(In reply to Philippe Normand from comment #5) > > Example: run-minibrowser --wpe -- --platform=drm http://url.com > > > That example looks incorrect. The url should be before -- Yes. Exactly, https://github.com/WebKit/WebKit/commit/63d0be648fd8f20ec94cadbb884a358bc6eba18b but that also means the code is not very robust to this kind of mistakes. If I have a bit of bandwidth, I will fix a couple of things there, but if someone else wants to do it.
Note You need to log in before you can comment on or make changes to this bug.