| Summary: | run-minibrowser --help seems incorrect about url-loading | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Karl Dubost <karlcow> |
| Component: | Tools / Tests | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW --- | ||
| Severity: | Normal | CC: | g_squelart, mcatanzaro, philn, webkit-bug-importer |
| Priority: | P2 | Keywords: | GoodFirstBug, InRadar |
| Version: | Safari 17 | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| See Also: |
https://bugs.webkit.org/show_bug.cgi?id=255962 https://bugs.webkit.org/show_bug.cgi?id=256086 https://bugs.webkit.org/show_bug.cgi?id=247378 |
||
|
Description
Karl Dubost
2023-11-06 23:59:29 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. run-minibrowser --wpe http://example.com -- --platform=drm ? > Example: run-minibrowser --wpe -- --platform=drm http://url.com
That example looks incorrect. The url should be before --
(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? (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. |