PYQuery fails to work for the following html file

Issue #45 resolved
Cal Leeming
created an issue

Hello,

The following HTML file fails to work with pyquery: http://pastebin.com/raw.php?i=v3jd3Gm5

The query failing is: pq(a)("meta")

It simply returns blank data.

Can't see any valid reason why it would reject this file.

Any suggestions??

Cal

Comments (13)

  1. Cal Leeming reporter

    Couldn't find anywhere in the docs stating namespaces were not supported. Re-opening at the very least to have the docs updated, or have an assertion raised on the presence of xmlns.

    Or, display a warning in stderr/stdout saying xmlns may not be supported, so at least its not being silently ignored!

  2. Cal Leeming reporter
    • changed status to open

    Namespaces are not supported if they are within a <html> tag though - correct? Sorry to keep setting this as 'opened' but so far all you have told us is that the function failed because "the html uses namespaces"... But then you say namespaces are supported.

    So far, everytime I have tried using namespaces in the HTML with PYQuery, it has failed. This sounds like a bug to me, no?

  3. Cal Leeming reporter

    Nice - are you planning on making this automatic? I.e. if it detects xhtml namespaces, then it will automatically remove them and convert to html?

  4. Log in to comment