Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timeout causes CRS to restart even under PERL_CR_SMOKER_RUNONCE #9

Open
dcollinsn opened this issue Oct 1, 2016 · 0 comments
Open

Comments

@dcollinsn
Copy link

dcollinsn commented Oct 1, 2016

I ran with the following command line:

PERL_CR_SMOKER_RUNONCE=1 install/bin/perl -MCPAN::Reporter::Smoker -e 'start(install => 1, force_trust => 1)'

And found that the smoker was still restarting every 12 hours. The following code is to blame:

  SCAN_LOOP:
  while ( 1 ) {
    # SNIP
    DIST:
    for my $d ( 0 .. $#{$dists} ) {
      # SNIP
      next SCAN_LOOP if time - $loop_start_time > $args{restart_delay}; # <-- HERE
    }
    last SCAN_LOOP if $ENV{PERL_CR_SMOKER_RUNONCE};
    # SNIP
  }

It would behave as (I) expected if the indicated line was replaced with:

next SCAN_LOOP if time - $loop_start_time > $args{restart_delay} && !$ENV{PERL_CR_SMOKER_RUNONCE};

In other words - under runonce, it currently restarts if the timeout it hit before all of CPAN is tested. The above change will prevent the erroneous restart. (I noticed this because I'm trying to smoke perl feature branches against all of CPAN, so I care about getting as deep as possible in CPAN - and restarting and retesting everything that FAILed, NAed, UNKNOWNed, or had a distroprefs'ed dependency is counterproductive.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant