Hi Jo, I recall it didn't work either, nor perldl (but I don't trust my memory). I would have to start again to test them. As I wrote before, my worry is the impression it might cause to new users to have a program installed and then find out it sends error messages (erroneous, as Ed explained above) when first tried.
Regards, Luis On Wed, Jan 22, 2025 at 02:30:01PM +0000, Jörg Sommrey wrote: > Hi Luis, > > you might try 'pdl2' instead of 'pdl'. The latter doesn't work for me > neither after upgrading PDL lately. > Just a guess. > > -jo > > On Wed 22 Jan 2025 04:46:09 AM CET, Luis Mochan <moc...@icf.unam.mx> wrote: > > > Hi Ed, > > > > Maybe I didn't explain the issue, maybe I don't quite understand > > it. And maybe I didn't quite understand your answer: > > > > 1. I made a new account in my laptop > > 2. I installed perlbrew > > 3. I installed perl-5.40.1 > > 4. In installed cpanm > > 5. I installed PDL with cpanm > > 6. I ran pdl > > 7. I obtained the answer: > > > > perlDL shell v1.357 > > PDL comes with ABSOLUTELY NO WARRANTY. For details, see the file > > 'COPYING' in the PDL distribution. This is free software and you > > are welcome to redistribute it under certain conditions, see > > the same file for details. > > ReadLines, NiceSlice, MultiLines enabled > > Reading PDL/default.perldlrc... > > * WARNING: Error loading PDL: 'Can't locate Term/ReadKey.pm in @INC > > (you may need to install the Term::ReadKey module) (@INC entries > > checked: > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1 > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/5.40.1/x86_64-linux > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/5.40.1) at > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/Doc/Perldl.pm > > line 52. > > BEGIN failed--compilation aborted at > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/Doc/Perldl.pm > > line 52. > > Compilation failed in require at > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/default.perldlrc > > line 37. > > BEGIN failed--compilation aborted at > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/default.perldlrc > > line 37. > > Compilation failed in require at (eval 13) line 1. > > ' - trying blib. > > WARNING: PDL startup not found only plain perl available > > > > Note: AutoLoader not enabled ('use PDL::AutoLoader' recommended) > > ** perl> > > > > The line marked with an * above says: 'WARNING: Error loading PDL: > > 'Can't locate Term/ReadKey.pm in @INC (you may need to install the > > Term::ReadKey module)...' > > > > So it is not that I (or my students) care about Term::ReadKey, it is > > that the advice we got is that we'd better install it. > > > > Also, the line marked with ** shows we obtained the prompt 'perl>' > > instead of the expected prompt 'pdl>'. > > > > In my previous installations, I hadn't had this problem, as I > > installed manually many required and optional pre-requisites, > > including Term::ReadLine::Gnu, which I guess is the readline you > > mention in your answer. However, installing Term::Readline::Gnu didn't > > help with the problem above. I obtained again: > > > > $ pdl > > perlDL shell v1.357 > > PDL comes with ABSOLUTELY NO WARRANTY. For details, see the file > > 'COPYING' in the PDL distribution. This is free software and you > > are welcome to redistribute it under certain conditions, see > > the same file for details. > > ReadLines, NiceSlice, MultiLines enabled > > Reading PDL/default.perldlrc... > > WARNING: Error loading PDL: 'Can't locate Term/ReadKey.pm in @INC > > (you may need to install the Term::ReadKey module) (@INC entries > > checked: > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1 > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/5.40.1/x86_64-linux > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/5.40.1) at > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/Doc/Perldl.pm > > line 52. > > BEGIN failed--compilation aborted at > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/Doc/Perldl.pm > > line 52. > > Compilation failed in require at > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/default.perldlrc > > line 37. > > BEGIN failed--compilation aborted at > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/default.perldlrc > > line 37. > > Compilation failed in require at (eval 11) line 1. > > ' - trying blib. > > WARNING: PDL startup not found only plain perl available > > > > Note: AutoLoader not enabled ('use PDL::AutoLoader' recommended) > > > > perl> > > > > But after installing ReadKey things started behaving as usual: > > > > $ cpanm Term::ReadKey > > --> Working on Term::ReadKey > > Fetching > > http://www.cpan.org/authors/id/J/JS/JSTOWE/TermReadKey-2.38.tar.gz ... > > OK > > Configuring TermReadKey-2.38 ... OK > > Building and testing TermReadKey-2.38 ... OK > > Successfully installed TermReadKey-2.38 > > 1 distribution installed > > $ pdl > > perlDL shell v1.357 > > PDL comes with ABSOLUTELY NO WARRANTY. For details, see the file > > 'COPYING' in the PDL distribution. This is free software and you > > are welcome to redistribute it under certain conditions, see > > the same file for details. > > ReadLines, NiceSlice, MultiLines enabled > > Reading PDL/default.perldlrc... > > Found docs database > > /home/mochan2/perl5/perlbrew/perls/perl-5.40.1/lib/site_perl/5.40.1/x86_64-linux/PDL/pdldoc.db > > Type 'help' for online help > > Type 'demo' for online demos > > Loaded PDL v2.098 (supports bad values) > > > > Note: AutoLoader not enabled ('use PDL::AutoLoader' recommended) > > > > pdl> > > > > So, what is the user expected to do? The installation of PDL was declared > > succesful, a program ('pdl') distributed with PDL was installed, the > > program didn't run smoothly and sent error messages asking the user to > > install another package: Term::ReadKey. How would you interpret this > > situation as a new user? Wouldn't you be confused? Wouldn't you > > conclude there is something wrong? > > > > I don't know what is the correct solution. I suggested adding > > Term::ReadKey to the required packages, so it would be installed > > automatically. Maybe that is not the correct solution, but then, I > > don't know, what would be the correct solution? > > > > Best regards, > > Luis > > > > > > > > > > On Tue, Jan 21, 2025 at 10:40:32PM +0000, Ed . wrote: > > > Hi Luis, > > > > > > PDL isn't just an interactive environment. "Required" would be > > > wrong. I use the interactive part very heavily (which isn't very > > > surprising), and wouldn't want to use it without readline (which I > > > have faced when debugging in a qemu environment on a weird > > > architecture). I am not going to make any of the Term::* be > > > "required" for PDL. I hope you understand. > > > > > > If it helps, the REPL script was installed, but not all of the > > > components. It does sound like you're asking me to make a separate > > > PDL::REPL repo where that stuff would live, but I don't want to do > > > that. > > > > > > Best regards, > > > Ed > > > > > > ________________________________ > > > From: Luis Mochan <moc...@icf.unam.mx> > > > Sent: 21 January 2025 20:07 > > > To: Ed . <ej...@hotmail.com> > > > Cc: perldl <pdl-gene...@lists.sourceforge.net>; perldl > > > <pdl-devel@lists.sourceforge.net> > > > Subject: Re: [Pdl-devel] pdl scripts > > > > > > Hi Ed, > > > > > > On Tue, Jan 21, 2025 at 05:13:09PM +0000, Ed . wrote: > > > > Hi Luis, > > > > > > > > That's a really good question! > > > > > > > > PDL's "requirements" (when you say e.g. cpanm PDL) are hard > > > requirements for PDL to run: largely File::Map and File::Which. CPAN > > > has a mechanism to "recommend" other modules, including > > > Term::ReadKey. It has done so for a long time. cpanm can be told to > > > install recommended modules. > > > > > > The doubt I have now is, should Term::ReadKey be recommended or should > > > it be required? The problem is that the repl's were installed, but > > > they didn't work without it. > > > > > > > The demos will be sparse... > > > > > > Ok, thanks. I'll pass that info to the students. > > > > > > Regards, > > > Luis > > > > > > -- > > > > > > o > > > W. Luis Mochán, | tel:(52)(777)329-1734 /<(*) > > > Instituto de Ciencias Físicas, UNAM | fax:(52)(777)317-5388 `>/ /\ > > > Av. Universidad s/n CP 62210 | (*)/\/ \ > > > Cuernavaca, Morelos, México | moc...@fis.unam.mx /\_/\__/ > > > GPG: 791EB9EB, C949 3F81 6D9B 1191 9A16 C2DF 5F0A C52B 791E B9EB > > > -- o W. Luis Mochán, | tel:(52)(777)329-1734 /<(*) Instituto de Ciencias Físicas, UNAM | fax:(52)(777)317-5388 `>/ /\ Av. Universidad s/n CP 62210 | (*)/\/ \ Cuernavaca, Morelos, México | moc...@fis.unam.mx /\_/\__/ GPG: 791EB9EB, C949 3F81 6D9B 1191 9A16 C2DF 5F0A C52B 791E B9EB _______________________________________________ pdl-devel mailing list pdl-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/pdl-devel