Subject: | Grep doesn't check that the stripped file exists |
Trying the example for Grep, I get:
$ perl -MMath::OEIS::Grep=-search,123,456,789
Can't use an undefined value as a symbol reference at /.../perlbrew/perls/perl-5.20.0/lib/site_perl/5.20.0/Math/OEIS/Grep.pm line 224.
BEGIN failed--compilation aborted.
This is caused by:
$fh = Math::OEIS::Stripped->fh;
returning undef.
This happens both with and without File::Map installed. In neither case does use_mmap get set.
If I put the stripped file in OEIS/stripped, then things mostly work. I believe two changes need to be made:
1) The documentation needs to be much clearer about the need to manually download the stripped file, including simple instructions using wget
2) Either Stripped or Grep needs to check whether the OEIS directory and stripped file exists, and give a clear error if so.