in reply to PP packaging Mechanize problem

Actually, your problem is not with WWW::Mechanize, but with HTML::DOM respectively HTML::DOM::Interface.

Looking at line 83, I see the following code:

... # (which was just hack after hack), but is now maintained manually +. 0 and q r =for ; our @EXPORT_OK = qw/METHOD VOID READONLY BOOL STR NUM OBJ TYPE/; ...

Which seems to be a weird "comment block" commenting between the q r and the =for line. I don't know why this triggers a Perl error, but it might be that your (unstated) version of Perl copes differently with the POD directives, or some preprocessing part of PAR strips the POD and thus wrongly messes up the code.

If you strip out these three lines, you should get a different error or it should work.

Replies are listed 'Best First'.
Re^2: PP packaging Mechanize problem
by ikegami (Patriarch) on Oct 12, 2008 at 13:10 UTC

    I don't know why this triggers a Perl error,

    Sounds like it's meant to be treated as a q'...' construct with "r" as the delimiter. Sounds like it is treated as such, but doesn't see the "r" in "=for ;" like it is meant to.

    I just tested with Perl 5.8.8 and Perl 5.10.0 and it works for me. Maybe the packager is stripping the pods to reduce the size of the package???

      This diagnosis is spot on. The documentation says:

      By default, PAR strips POD sections from bundled modules. In case that causes trouble, you can turn this off by setting the environment variable PAR_VERBATIM to 1.

      ... so I guess doing that would also help in this case.