Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow browser configuration by user context and not only globally (capabilities) #789

Open
whimboo opened this issue Sep 24, 2024 · 1 comment
Labels
enhancement New feature or request module-browser Browser module needs-discussion Issues to be discussed by the working group

Comments

@whimboo
Copy link
Contributor

whimboo commented Sep 24, 2024

This is a request coming from Playwright:

Allow to configure options (aka capabilities) such as proxy and acceptInsecureCerts per user context rather than per session, so that same browser process can be reused for testing with different options.

We could use the capabilities as default settings, and allow to override those when creating a new user context by specifying new values via optional arguments.

Note that it's not clear if all those settings can be actually handled per user context for all the browsers.

@whimboo whimboo added enhancement New feature or request needs-discussion Issues to be discussed by the working group module-browser Browser module labels Sep 24, 2024
@css-meeting-bot
Copy link
Member

The Browser Testing and Tools Working Group just discussed Allow browser configuration by user context and not only globally.

The full IRC log of that discussion <simonstewart> Topic: Allow browser configuration by user context and not only globally
<simonstewart> github: https://github.com//issues/789
<simonstewart> jgraham: some people would like to treat different user contexts as completely separate sessions so that they can have a single browser process
<simonstewart> jgraham: from a gecko point of view, I don't think we can implement this in general
<simonstewart> jgraham: we use containers, which are extra attributes on storage. I don't think we have proxies per user context, etc
<simonstewart> gsnedders: we already create a separate NSURLSession for ephemeral browsing contexts, so I think we should be able to configure the NSURLSessions we're using for each top-level navigable separately. However, I'm not totally sure
<gsnedders> s/for ephemeral browsing context/for each ephemeral browsing contexts/
<simonstewart> simonstewart: presumably this is for "speed"?
<simonstewart> <general agreement>
<simonstewart> sadym: for use, proxies are per process.
<simonstewart> sadym: accepting insecure certs, we can per user context
<simonstewart> sadym: ah! You can set proxy
<simonstewart> jgraham: the thing we can do here is to add some configuration options to create user context, which are roughly equivalent to ones from capabilities that we can set.
<simonstewart> jgraham: per thing we try and set, we need to check whether or not it's possible for people to do
<simonstewart> sadym: do we want to use capabilities when creating user contexts?
<simonstewart> jgraham: very much no
<simonstewart> jgraham: you can always return "unsupported operation" if someone asks for something you can't implement
<simonstewart> simonstewart: we may just want to limit the capabilities we can pass through
<simonstewart> jgraham: yes, to the things in capabilities that are configuration values
<simonstewart> simonstewart: limiting to useInsecureCerts and proxy seems like something people can implement
<simonstewart> sadym: unhandledPromptHandling too
<AutomatedTester> RRSAgent: make minutes
<RRSAgent> I have made the request to generate https://www.w3.org/2024/09/27-webdriver-minutes.html AutomatedTester

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request module-browser Browser module needs-discussion Issues to be discussed by the working group
Projects
None yet
Development

No branches or pull requests

2 participants