-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
[REGRESSION] Custom selectors no longer able to be last in group #4774
Comments
This has indeed regressed in 1.7, and will be fixed in the next patch by #4754. Some suggestions for writing robust selector engines:
|
I suspect I copied and pasted the comments into the CodeceptJS code and forgot to change, which would explain why they don't make sense. These selectors are implemented to enable us to do arbitrary selectors on properties, in this case value, but we have ones for disabled too, without forcing our users to use any specific selector strat, E.g. xpath/CSS, I suppose you could think of them as filters |
Yes, I found that during my debugging. To my surprise changing that didn't help to solve the issue 😄 . But sure that part should be updated.
Yeah, the use case for this engine is very specific and probably it is a bit of misuse of selector engine as we don't go deeper by the tree but we filter the elements according to some rules. I would say this is a quite smart idea by @Georgegriff . At least we won't need to create various pseudo-CSS selectors (jQuery style) for additional filtration of elements. Anyway, for further usage, we should to stick to your guidelines. |
This will be fixed in v1.7.1. |
Context:
Code Snippet
In CodeceptJS we had this custom selector engine which worked fine since... Playwright 0.13, I think.
The purpose of it was to filter elements by value:
Usage example:
This worked till 1.7.0.
I tried to debug and seems that in 1.7 in
query
andqueryAll
calls I am receivingdocument
object, and not Node object.The text was updated successfully, but these errors were encountered: