1

I am using the windows 8 operating system and I am trying to install the WWW::Mechanize::Firefox module in ActiveState Perl, from CPAN. I have successfully downloaded and installed all the dependencies and also installed the MozRepl module on Firefox. I do not have noScript running on my firefox and hence I am assuming that Javascript is enabled across all files (I am not sure how or where to check that). Here is my error message when I try to install the module.

enter image description here

I also constantly receive this error throughout the installation - "Subroutine-MozRepl-Load Plugins redefined at line 104." Any help is much appreciated ! Thank you !

EDIT - These are the errors - enter image description here

Amritha
  • 795
  • 3
  • 9
  • 26
  • It looks like some of the tests actually need Firefox and Mozrepl to be running before they begin, as they are testing javascript interaction within the browser. Note these are only warnings, did they stop module installation?. You could try running a sample program to see if the module is working – Kim Ryan Jan 27 '15 at 23:22
  • Yes, I did try out a sample script. But this is the error I am receiving - "Can't locate WWW/Mechanize/Firefox.pm in @INC (you may need to install the WWW::Mechanize::Firefox module)" - I also ensured that MozRepl is activated. – Amritha Jan 28 '15 at 02:26
  • 1
    It was never installed because of the test failures – ikegami Jan 28 '15 at 04:10
  • 1
    It might help to show the errors rather than the summary – ikegami Jan 28 '15 at 04:11

2 Answers2

0

As Kim suggested in comments, you will need Mozrepl and Firefox.

Please refer WWW::Mechanize::Firefox::Installation page for detailed instructions on how to install this module.

If you use ActiveStates package manager, you can find some pre-packaged but untested PPMs at https://github.com/Corion/www-mechanize-firefox/downloads .

Chankey Pathak
  • 21,187
  • 12
  • 85
  • 133
0

I needed to use this module on Windows, and couldn't get it running with ActivePerl. So I installed http://strawberryperl.com/ and it worked. This version of perl seems to handle installs form the cpan command line utility better than Activestate, who expect you to use their perl package manager as the default module installer (and don't supply a dmake program). Strawberry Perl also comes with a C compiler so can build modules that are a mixture of Perl and C code.

And make sure mozrepl is running before you try to install.

Kim Ryan
  • 515
  • 1
  • 3
  • 11
  • I am trying using Strawberry Perl. Should we have Cygwin installed or can we install through windows command prompt itself ? I am installing some of the module's dependencies and they are giving me errors. It would be helpful if you can tell me which version of Perl and Firefox you used. Thanks ! – Amritha Feb 03 '15 at 20:57
  • I am using Perl version 20 and Firefox 33.0. Strawberry Perl doesn't need cygwin. Make sure you are running Strawberry Perl and not the Activestate version. If you just type 'perl' in command line, you run the one that appears first in the $PATH environment variable. – Kim Ryan Feb 04 '15 at 07:48
  • 1
    Or for a Python based solution, look at https://splinter.readthedocs.org/en/latest/ . It may not even require mzrepl – Kim Ryan Feb 04 '15 at 22:40