16:53:19 RRSAgent has joined #webdriver 16:53:19 logging to https://www.w3.org/2020/10/28-webdriver-irc 16:53:28 Zakim has joined #webdriver 16:53:55 Meeting: Browser Testing and Tools WG @ TPAC - Day 3 16:54:10 Agenda: https://www.w3.org/wiki/WebDriver/2020-TPAC#Agenda 16:54:25 chair: AutomatedTester 16:54:38 Scribe: David Burns 16:54:45 ScribeNick: AutomatedTester 16:54:49 present+ 16:54:54 RRSAgent: nolisten 17:02:39 jimevans has joined #webdriver 17:02:46 present+ 17:02:46 present+ 17:02:47 present+ 17:02:55 present+ 17:02:59 present+ 17:03:00 john_chen has joined #webdriver 17:03:15 present+ 17:03:20 present+ 17:04:14 present+ 17:04:31 simonstewart has joined #webdriver 17:04:41 present+ 17:04:52 zghadyali has joined #webdriver 17:05:11 mathiasbynens will be here for the second hour 17:05:42 present+ 17:05:55 https://www.w3.org/wiki/WebDriver/2020-TPAC#Topic_Bank 17:07:41 Topic: Network interception 17:08:32 Is there a link to the issue? 17:08:54 jgraham: One of the common use cases for bidi from Selenium and we've seen it in puppeteer is the ability to see when a specific request happens and do a specific case 17:09:02 drousso has joined #webdriver 17:09:04 ... such as basic auth 17:09:07 present+ 17:09:33 ... or the othre request is network requests where we can say if X happens that we mock those network requests 17:09:45 q+ 17:09:50 q+ 17:10:07 ... I think this part of the "value add" feature sets 17:10:36 ... I've been looking around at this and CDP has the Fetch domain 17:10:49 ... [describes how CDP does this case] 17:11:29 ... looking at WebKit it looks very similar 17:11:40 present+ 17:11:57 ... Gecko has a very model in webextensions 17:12:22 https://github.com/w3c/webdriver-bidi/issues/66 17:12:22 q+ 17:12:36 Github topic: https://github.com/w3c/webdriver-bidi/issues/66 17:12:48 ... so we have precendent in this area 17:12:49 a/very model/slightly different model/ 17:12:54 s/very model/slightly different model/ 17:12:54 q? 17:13:03 ack foolip 17:13:09 RRSAgent: make minutes v2 17:13:09 I have made the request to generate https://www.w3.org/2020/10/28-webdriver-minutes.html jgraham 17:13:10 present+ 17:13:13 q+ 17:13:23 lol oops i used the wrong command :P 17:14:04 foolip: is the model to both replace response without doing the response or can we edit and pass it back 17:14:23 ... that's how I think CDP does this 17:14:51 jgraham: I think there is a getResponse type command that you get it and then can edit it 17:15:00 ... both seem like meaningful use cases 17:15:04 q? 17:15:08 ack cb 17:15:26 cb: is the scope of this feature to capture all web resources? 17:15:47 jgraham: I believe that the scope should be to all resource fetches 17:15:57 q+ 17:16:07 ... there is a question that I don't know the answer to which is how would service workers handle this 17:16:09 q? 17:16:13 ack simonstewart 17:16:59 simonstewart: there are a lot of implementations for how intercepting of auth since there are cases like webauthn 17:17:13 ... puppeteer doesn't seem to have a handle on this yet 17:17:23 ... are we going to make it flexible enough 17:17:44 jgraham: yes, those are important cases 17:18:21 ... I am not sure they should be part of this API. I think they have already added webdriver features and they are best placed to handle this 17:18:50 ... I've just looked and they have a VirtualAuthenticator for testing 17:19:02 simonstewart: Ive seen that in the selenium code base 17:19:03 q? 17:19:07 ack drousso 17:19:59 drousso: the reason we have added the support for things like this purely for webinspector, not for automation but can be used there 17:20:25 foolip: can you replace request headers as you see fit? 17:20:58 drousso: yes, and there are some pass throughs that means if people dont have send all the items 17:21:11 q? 17:21:18 ack brwalder 17:22:05 brwalder: re: service workers. In CDP this is set at the network layer and would not work for service workers as that's different 17:22:20 q+ 17:22:52 q? 17:23:03 jgraham: that makes sense. I did have a question around filtering of this. How would we limit this to browsing context/realm? 17:23:13 There is also recent code merge in ChromeDriver for webauth(https://chromium-review.googlesource.com/c/chromium/src/+/2488183) with reference links in commit message. 17:23:18 q? 17:23:27 ack foolip 17:23:45 foolip: a question for brwalder : Does this bypass the cache? 17:24:04 brwalder: Enabling the fetch domain disables the cache 17:24:13 simonstewart: that's not true you need to do it manually 17:24:24 drousso: webkit turns it off 17:24:37 foolip: so we need to be smart here when designing it 17:26:23 simonstewart: I would like to discuss this more indepth 17:26:44 ... I imagine people have in their minds what puppeteer do in the fetch domain 17:27:16 ... are we wanting to have a similar model for the future 17:27:35 ... I don't know how webkit do this 17:27:48 drousso: I dont know CDP but will explain webkit 17:28:15 .... webkit does something similar that it takes a pattern for an interception and at what stage 17:28:23 ... this is only request or response currently 17:28:31 q+ 17:28:43 ... the engine will notice and emit an event to the front end 17:29:06 ... requestContinue - carry on as normal 17:29:34 ... [describes 3 other events] 17:30:03 ... All of this par tof the network domain and not a separate domain 17:30:26 jgraham: I don't think we should have a spralling mass of modukes 17:30:33 ack brwalder 17:30:43 brwalder: that sounds more or less like CDP Fetch 17:30:56 ... and has similar workflow 17:31:20 ... and if you want the cache disabled you have to do it manually 17:31:33 ... and the same for service workers 17:31:44 q? 17:33:20 simonstewart: So my understanding is that there will be a command that takes a regex and then emits events and you can manipulate it as you see fit 17:33:59 ... and when you get an authentication request you will intercept and insert credentials or we can deny it 17:34:18 jgraham: I agree 17:34:31 simonstewart: and one thing more that we implicitly disable the cache 17:35:14 drousso: both chrome and webkit disable the cache if requested 17:35:34 ... but when we are going to override anything we make sure that automatically disable the cache instead 17:36:24 jgraham: I think we need to be clear in the spec and it seems webkit are doing the right thing, especially for automation 17:36:43 ... I cant see a use case for the CDP way other thank creating flaky tests 17:37:05 s/doing the right thing/have the correct cache-disabling behaviour/ 17:37:21 RRSAgent: make logs public 17:37:26 RRSAgent: make minutes v2 17:37:26 I have made the request to generate https://www.w3.org/2020/10/28-webdriver-minutes.html jgraham 17:38:15 Resolution: Create a command that takes a regex and then emits events and users can manipulate requests and responses based on the events sent. When an authentication request is intercepted we can insert credentials or deny them 17:38:22 github-bot: end topic 17:38:59 Topic: Shadow DOM 17:39:45 Github Topic: https://github.com/w3c/webdriver/issues/350 17:40:31 jimevans: With the rising use of web components the ability to interact with Shadow DOM is getting more important 17:40:57 ... right now those components are opaque to webdriver 17:41:10 ... there are some work arounds using executeScript 17:41:50 ... and some XPATH libraries have been able to pierce Shadow DOM because CSS does not have the ability to pierce the shadowroot 17:42:16 q+ 17:42:44 ... we need a way to "switch" or "select" into a shadow dom and test the elements in there 17:42:56 ... I have a straw man proposals 17:43:10 ... THere are some outstanding questions: 17:43:18 ... 1) What do we do with closed roots 17:44:15 ... 2) and how do we handle this. E.g. could we do element.getShadowRoot() and continue from there 17:44:50 https://docs.google.com/document/d/15DYXZyWsahr1peyOWmi2QGgzi3Xb2GlITyywx-2cPXc/edit?usp=sharing 17:47:59 https://github.com/w3c/webdriver/pull/1320/files 17:49:41 q? 17:50:17 ack jgraham 17:50:29 jgraham: I like the shape of the proposal 17:51:27 ... and like going element and being able to pierce this makes sense 17:52:23 q+ 17:52:25 ... and I think that the reason why this hasn't happened hasnt been fundamental opposition to this, purely time 17:53:22 q+ 17:54:48 AutomatedTester: I remember from TPAC last year that the DOM member from Apple said there was opposition to allowing Shadow Roots from being pierced and they said this is the main reason why CSS piercing was not allowed but Jim has told us that XPATH can get around this issue 17:54:50 q? 17:54:55 ack foolip 17:55:37 foolip: if I remember on Monday jgraham said that Shadow Roots would not be interacted the same was as in bidi as http 17:55:47 ack jgraham 17:56:13 jgraham: in answer to foolip the serialisation is more generic 17:56:36 ... we would serialise it and it would just serialise that is has a shadowroot 17:56:51 ... since we have generic concept of node and not a web element 17:56:55 ok that makes sense, if we're talking about merely finding out that something is a shadow host 17:57:35 jgraham: It feels like the DOM are not understanding us here and perhaps we need to go speak to them 17:57:38 q? 17:57:45 ... since this is open to Devtools but not us 17:58:53 ... and the next item is to I wonder if we can simplify the API to accept a now and reusing webelement. 17:59:20 q+ 17:59:26 q+ 17:59:32 ack foolip 18:00:02 present+ 18:00:19 q+ 18:00:37 foolip: Is the frustration that people can not pierce things or are we going to have to do it for every boundary 18:01:38 jimevans: the proposal is to minimize the cognitive load to keep it "similar" to find elements 18:02:13 ... except the sematics would be that you are specifically looking in the shadow 18:02:24 ... no thoughts have been given for chaining 18:02:53 q+ 18:03:09 ... this is purely for http and agree that bidi should be different 18:03:50 ack AutomatedTester 18:04:54 q+ 18:05:00 AutomatedTester: I can't see the how the people trying to reuse findElement as they seem very different to me, could you elaborate it 18:05:17 q+ 18:05:19 jgraham: I think that the DOM hierarchy would be on our side so we will be fine 18:05:22 ack jgraham 18:05:53 jgraham: ffor foolip: re: CSS piercing was seen as bad by other WG 18:06:30 ... and for piercing we need to make sure that piercing the Shadow DOM needs to be explicit 18:07:12 ... I think we should do the simple case first and see how it goes 18:07:17 q? 18:07:22 ack cb 18:07:26 RRSAgent: make minutes v2 18:07:26 I have made the request to generate https://www.w3.org/2020/10/28-webdriver-minutes.html jgraham 18:08:17 cb: I have a counter proposal. It would be good to extend element.findElement(withShadow=true) and that would look inside the shadow 18:08:33 q? 18:08:50 q+ 18:08:59 jimevans: I don't have a problem with that approach either 18:09:06 ... we just need to something 18:09:39 ... the tricky bit we need to think about is that we have a new error code 18:10:06 ... if you want inside a shadowRoot and we cant find it its because of the shadow dom and not the DOM 18:10:15 q? 18:10:20 ack drousso 18:11:26 drousso: regarding piercing, I dont think that we want "special paths" for automation 18:11:49 ... or these special paths need to be infrequent 18:11:51 q? 18:11:57 ack mathiasbynens 18:12:48 mathiasbynens: in puppeteer we allow people to allow people register querySelectors on their own 18:12:59 ... and then people can do what they want from there 18:13:26 ... we have one called `pierce` that pierces shadowROot 18:13:37 and one called `aria` for accessibility 18:13:47 ... I think that playright does something similar 18:13:53 q? 18:14:01 ack jgraham 18:14:39 jgraham: so looking at the PR we had this discussion 2 years ago 18:15:06 ... the backwards compatiblity issue is that if we add new parameters then we can have silent failures 18:15:07 To clarify, in Puppeteer you opt-in to shadow DOM piercing not through some new parameter, but by adding a prefix to the selector string. This was decided because that way, we can make it work for our 10+ APIs that accept selector strings 18:15:30 ... the new end points mean you will get an explicit error here 18:15:51 ... and that is better for everyone 18:17:41 Puppeteer's built-in pierce handler: https://github.com/puppeteer/puppeteer/pull/6509/files 18:18:25 Resolution: Write up spec prose based on jimevans proposal and the for future proposals in this area use the learning from other frameworks to see how we can improve 18:18:31 github-bot: end topic 18:19:10 Topic: BiDi roadmap 18:20:14 foolip: I would like to get a good idea of how far we can go for clients and implementors. What is the MVP/product that we want o enable so that we have a North Star to aim for 18:21:13 mathiasbynens: for puppeteer last year we met at Mozilla to get cross browser support 18:21:27 ... puppeteer is great but it's built on CDP which isnt great 18:21:44 ... and now we have playwright that's very different 18:22:04 ... and playwright is shipping their own browsers 18:22:24 ... which has a limitation that they can never get to Mobile. 18:23:35 ... We see webdriver bidi as the missing piece for getting better support for multiple browsers and since each project has their limitations 18:23:55 q? 18:24:00 q+ 18:24:06 q+ 18:24:11 ... we hope to use webdirver bidi and if need to use the escape hatch 18:25:04 ... in chromium we hope to have a prototype by the end of next year for a few commands and the spec 18:25:29 q+ 18:25:31 q? 18:26:26 simonstewart: As far as selenium as concerned is to try increase the progress so that we can have a stable user API based on the use cases that we have discussed before 18:26:50 ... and the ability to evolve APIs as needed 18:27:29 ... and we dont want people's investments in selenium to be lost 18:27:31 q? 18:27:33 ack simonstewart 18:28:19 jgraham: Mozilla buys into this vision strongly. We are interested in browser interop concerns 18:28:41 ... and we see a lot of feedback from the MDN survey that cross browser testing is hard 18:29:03 ... and we want to work people here and with clients to make sure this all works 18:29:18 ... I am currently working on spec stuff 18:29:28 ... and I think we're on track to adding logging 18:29:48 ... and I will likely look at realms 18:30:10 ... and this will give us the infrastructure to be able to add more meaningful commands in the future 18:30:31 ... and I want to get to a stage where we can get more people working on the spec 18:31:20 ... in terms of implementation. We see this as a priority. We are currently finishing off site isolation but then will move back to this work 18:31:36 q? 18:31:42 ... I can't state where we will be by this time next year 18:31:54 ... and I hope will resource it as best we can 18:31:56 where do we *need* to get to by this time next year? 18:32:09 ack jgraham 18:32:20 ack shengfa 18:32:48 shengfa: in terms of the roadmap... I would like to add that there should be some effort put into WPT 18:32:54 q+ 18:33:03 +1 +1 +100 :) 18:33:06 ... so that we can get some references into the pipeline early 18:33:35 ... I am currently trying to add websockets to wpt 18:33:56 ... and we need to be able have an async style of testing 18:34:14 ... and we need to do commands and perhaps /status would be a good place to start 18:34:18 WIP: https://github.com/web-platform-tests/wpt/commit/61e6da80428d49f8e6efe779658596b6b38e53e4 18:34:21 q? 18:34:33 ack jgraham 18:34:59 jgraham: this is exciting that we are doing this straight away 18:35:16 ... and if I can help with reviewing let me know 18:35:28 q+ 18:35:28 ... and it would be good to see a RFC for this work 18:35:50 q+ 18:35:56 ack foolip 18:36:18 foolip: I would like to summarise and exaggerate what mathiasbynens and jgraham said 18:37:12 ... for browsers having bidi and having tests that pass and using CDP as an escape to CDP 18:37:48 jgraham: that sounds like a good goal and the right direction of the work 18:38:00 ... it's hard to predict how far we will get but its a good idea 18:38:14 ... it would be good to move Selenium over first 18:38:49 ... and prevent baking in CDP items to Selenium 18:39:06 simonstewart: if we could migrate Selenium first that would be awesome 18:39:32 foolip: just to check, this is for new APIS and not rewriting APIs 18:40:09 simonstewart: yea, this is for new APIs so that we don't ahve to rebuilding APIs with each Chromium release 18:40:13 q? 18:40:25 ack AutomatedTester 18:41:10 ack AutomatedTester 18:41:18 AutomatedTester: are we moving things to Py3? 18:41:36 jgraham: Yes, WPT is by the end of the year 18:41:37 Feb 1, 2021 is a date that's been thrown around. 18:42:31 ... there might be something interesting question of 3.6 vs 3.7 18:42:41 ... we have seen that people are moving across 18:43:13 shengfa: There is a plan to do py3 first vs py3 only 18:43:22 ... there are plans for other scenarios 18:43:55 q+ 18:44:06 jgraham: yes, py3 by the end year for being run first and then a month later it will be py3 only. There will be an RFC "soon" 18:44:14 ack foolip 18:45:07 foolip: to our webkit friends, are there client libraries or support for other that are more important than bidi? 18:45:23 drousso: our focus is on standardized or will be standardized 18:45:41 ... we are more interested in webdriver vs others 18:46:29 ... we have a number of security concerns with automation that we can't guarantee with other clients 18:47:10 RRSAgent: make minutes v2 18:47:10 I have made the request to generate https://www.w3.org/2020/10/28-webdriver-minutes.html jgraham 18:49:01 proposal: https://github.com/w3c/webdriver/pull/1552 18:49:28 q+ 18:49:47 topic: Async Session Creation 18:49:59 Github Topic: https://github.com/w3c/webdriver/pull/1552 18:50:32 cb: So the idea is we async session creation job 18:51:02 ... that has a defined set of events 18:51:35 ... and it has the ability to check that session ID creation 18:51:47 ... it has 3 endpoints 18:52:20 ... the question is where does the session get the session ID back from 18:52:48 ... if we allow a single event or all events 18:52:51 q? 18:53:27 q+ 18:53:41 jgraham: I think this should be targeted at browser implementations as it seems really good for areas where are a lot of latency like grid or cloud providers 18:54:23 ... I also am not sure that I can say that this is hard to justify the time to implement it there 18:54:35 ... my suggest is specify in a different spec 18:54:47 ... or make it optional for end nodes 18:55:09 q? 18:55:13 ack jgraham 18:55:16 ack simonstewart 18:55:49 simonstewart: I think you're right it's important for grid and I see what you mean by resourcing 18:56:28 ... in a new spec is overkill 18:56:47 ... and we can definitely mark this as a _may_ 18:58:05 cb: The main thing for us to make sure that have enough time to get the machines ready at sauce and we don't need to have it like it is 18:58:40 jgraham: I think the main use case is definitely yours and I dont think browser vendors should stop you from speccing it 18:59:41 Resolution: Add this to webdriver http and mark the new command as a MAY 18:59:50 present + 18:59:53 I have to run, thanks everyone! (son is calling) 19:02:09 RRSAgent: bye 19:02:09 I see no action items 19:02:48 RRSAgent has joined #webdriver 19:02:48 logging to https://www.w3.org/2020/10/28-webdriver-irc 19:03:05 RRSAgent: make minutes v2 19:03:05 I have made the request to generate https://www.w3.org/2020/10/28-webdriver-minutes.html AutomatedTester 19:03:44 it's lost the async stuff 19:03:46 Nope, all OK 19:04:04 oh... just slow 19:04:06 RRSAgent: stop