CESM-Development / cime

Common Infrastructure for Modeling the Earth
Other
16 stars 13 forks source link

Problems with BatchUtils.pm with some perl versions #461

Closed billsacks closed 7 years ago

billsacks commented 8 years ago

Helping Cecilia Bitz port cesm1_5_beta06 to the U Washington machine, perl (5.16?) complained about a bunch of stuff in BatchUtils.pm, in doResubmit and submitSingleJob. We managed to get past the problems by deleting the bodies of both of those routines. Comments list those as only applying to ALCF / mira, but we weren't sure whether that's really true.

@fischer-ncar has an email containing the full error messages.

fischer-ncar commented 8 years ago

Here is the full error message.

Warning: no access to tty (Bad file descriptor). Thus no job control in this shell. Bareword found where operator expected at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 636, near "my $issta = ($scriptname =~ /archive" (#1) (S syntax) The Perl lexer knows whether to expect a term or an operator. If it sees what it knows to be a term when it was expecting to see an operator, it gives you this warning. Usually it indicates that an operator or delimiter was omitted, such as a semicolon.

(Do you need to predeclare my?)

"my" variable $submitargs masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 667 (#2) (W misc) A "my" or "our" variable has been redeclared in the current scope or statement, effectively eliminating all access to the previous instance. This is almost always a typographical error. Note that the earlier variable will still exist until the end of the scope or until all closure referents to it are destroyed.

"my" variable $runcmd masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 671 (#2) "my" variable $starchivescript masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 689 (#2) "my" variable $submitargs masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 695 (#2) "my" variable $submitstuff masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 697 (#2) "my" variable $runcmd masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 698 (#2) "my" variable $submitargs masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 724 (#2) "my" variable $submitstuff masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 726 (#2) "my" variable $runcmd masks earlier declaration in same scope at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 739 (#2)

Global symbol "$RUN" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. Global symbol "$RUN" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. Global symbol "$exitstatus" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. Global symbol "$exitstatus" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. syntax error at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 636, near "my $issta = ($scriptname =~ /archive" Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 638. Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 659. Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 686. Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 712. syntax error at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 759, near "sub getSubmitArguments() " /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm has too many errors. Compilation failed in require at /var/spool/torque/mom_priv/jobs/73382.challenger.SC line 44 (#3) (F) You've said "use strict vars", which indicates that all variables must either be lexically scoped (using "my"), declared beforehand using "our", or explicitly qualified to say which package the global variable is in (using "::").

Uncaught exception from user code: Global symbol "$RUN" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. Global symbol "$RUN" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. Global symbol "$exitstatus" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. Global symbol "$exitstatus" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 609. syntax error at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 636, near "my $issta = ($scriptname =~ /archive" Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 638. Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 659. Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 686. Global symbol "$issta" requires explicit package name at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 712. syntax error at /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm line 759, near "sub getSubmitArguments() " /home/disk/eos11/bitz/cesm1_5_beta06c/cime/utils/perl5lib/Batch/BatchUtils.pm has too many errors. Compilation failed in require at /var/spool/torque/mom_priv/jobs/73382.challenger.SC line 44. at /var/spool/torque/mom_priv/jobs/73382.challenger.SC line 44

fischer-ncar commented 8 years ago

Hobart uses perl 5.16.3, and there hasn't been any perl script issues.

billsacks commented 7 years ago

Presumably no longer relevant with the python port