Replies: 1 comment
-
Tried xpath with regex on several sites. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
There is a way to speed up xpath expressions: https://lxml.de/xpathxslt.html#regular-expressions-in-xpath
expr = BODY_XPATH[0]
expr2 = expr, but using regex
expr time =
0.013
expr2 time =
0.008
If you don't mind, it is possible to rewrite all complex xpath expressions in the library.
There should be a noticeable performance gain.
Beta Was this translation helpful? Give feedback.
All reactions