python313Packages.splinter: fix build with lxml 6#465719
python313Packages.splinter: fix build with lxml 6#465719dotlambda merged 2 commits intoNixOS:masterfrom
Conversation
|
Initially I thought the latest unstable commit would fix the tests that are currently failing, but it seems upstream just restructured how they run tests for different drivers (they introduced a |
|
lmxl 6 seems to be the culprit. The tests fail because something like |
lxml 6 doesn't find a `<body>` tag via the XPath expression `//body` anymore when the parsed HTML doesn't contain any tags at all. This causes some of splinter's tests to fail when lxml 6 is used.
1290143 to
98d1634
Compare
|
Is there an upstream issue/PR about these test failures? Maybe it would be easier to just disable the specific tests? |
Not yet. But I'm gonna create one when I find the time.
I'd be fine with that, too. I took some time to find the underlying reason for the failures, so I figured why not just write a patch. Your call though. :) |
|
|
Successfully created backport PR for |
|
Thanks! Upstream patch for future reference: cobrateam/splinter#1334 |
lxml 6 doesn't find a
<body>tag via the XPath expression//bodyanymore when the parsed HTML doesn't contain any tags at all. This causes some of splinter's tests to fail when lxml 6 is used.The lxml HTML parser generally seems to behave rather erratically when there is no
<body>tag in the parsed HTML, so consumers probably shouldn't rely on this behavior anyway.Upstream patch: cobrateam/splinter#1334
Hydra: https://hydra.nixos.org/build/314264704/nixlog/1
ZHF: #457852
Things done
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.Add a 👍 reaction to pull requests you find important.