-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
[Feature]: Ability to extend the trace information #30610
Comments
@taras You can use |
It would be nice to be able to write arbitrary data to the trace. |
@dgozman Since we're not using locators, I assume we won't get the traces I highlighted in the image. We want to add these from the node or the browser for interactor interactions. |
@taras Most of Playwright APIs show in the trace, not only locators. What APIs do you use that's missing in the trace viewer? |
We're building a custom testing harness that uses the Playwright library to start up the browser. We have a custom test runner. Our traces would only show HTTP requests because we don't currently use the |
@taras I see, so you basically use Playwright to launch the browser. In this case, there is indeed not much to see in the trace. I will keep this issue open, but the usecase seems to be low priority for Playwright. It looks like it would be easier for you to record your own trace and show it in whatever UI you would like, because there is pretty much nothing from Playwright that could show up in the trace. |
Thank you very much for considering my request. I would like to clarify that we have two separate use cases. The primary use case that prompted this request is supporting Playwright to Interactors. This would make it possible for users of Interactors to use the Playwright runner with interactors for their component library. In this case, they'd be using everything except locators. The second use case is for BigTest, where we're considering replacing WebDriver with Playwright. In the case of BigTest, we have our own declarative test syntax and it's own test runner. The Interactors use case is a much higher priority for us. Can you give some pointers on how we can send trace information to Playwright, even via some unofficial APIs? I would appreciate it. Thank you for your time, |
I think the usual Playwright trace would be almost there. I guess you are using something else instead of locators, probably some kind of
Unfortunately, there is no way to achieve this today. |
The design of Intractors is very similar to Playwright locators. They're both convergent and perform chained DOM look-up in one tick of the event loop. You might find this blog post interesting https://frontside.com/blog/2020-07-16-the-lesson-of-bigtest-interactors/ We only use
In this case, the users would be using Playwright test runner. |
Why was this issue closed?Thank you for your involvement. This issue was closed due to limited engagement (upvotes/activity), lack of recent activity, and insufficient actionability. To maintain a manageable database, we prioritize issues based on these factors. If you disagree with this closure, please open a new issue and reference this one. More support or clarity on its necessity may prompt a review. Your understanding and cooperation are appreciated. |
🚀 Feature Request
If we don't use locators, we'll lose trace information about the elements we're interacting with in the test. Is there a way for us to write to the trace without using locators?
Example
We want to be able to call trace API from the browser or node to add information that locators would otherwise provide.
Motivation
https://frontside.com/interactors
I'm part of the team that maintains Frontside Interactors. We're considering creating an integration with Playwright. We tried using async locators, but Interactors's API design doesn't align well with Locators.
The text was updated successfully, but these errors were encountered: