The problem is that the modules are fighting over the "preferred" SAX parser. XML::Simple has this line:
$XML::SAX::ParserPackage = $preferred_parser if($preferred_parser);
which means that it doesn't set the preferred parser unless you specify it, and falls back to whatever default it finds in ParserDetails.ini. Or it would fall back, except that POE::Filter::XML (used by the POE Jabber module) has this:
$XML::SAX::ParserPackage = "XML::SAX::Expat::Incremental";
It's the XML::SAX::Expat::Incremental throwing the error, because it will only parse strings. I don't know why the XML::SAX::ParserPackage has to be a package variable and can't be set per instance of XML::SAX (or maybe it can, I don't know), or if 'incremental' can be used as some sort of feature for the ParserDetails.ini file (for POE::XML::Filter to use), or maybe XML::Simple should undef the ParserPackage variable (which may screw up POE::Filter::XML since it sets ParserPackage upon module load...maybe POE::Filter::XML should only set it when it needs a SAX parser object). Anyway...your workaround seems the best for your problem for now, but I'm not sure what the best solution should be (they're not my modules, and I don't have the tuits :-)

In reply to Re: XML module conflicts by runrig
in thread XML module conflicts by cLive ;-)

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.