hydra-eval-jobset: Support flakes

[?]
May 10, 2019, 10:10 PM
ZPHREC7X2TVM4OQJGTPA3Y3WOOJGTV3RXSPRI2ZFTZKIPIRRCUYQC

Dependencies

  • [2] HP5WJLQU hydra-eval-{jobs,jobset}: Pass file name as <...>
  • [3] QMW24O5S Add support for Guile & Guix.
  • [4] N22GPKYT * Put info about logs / build products in the DB.
  • [5] POPU2ATH * hydra_scheduler: use eval-jobs.
  • [6] 3XTHEUMP * Implemented the clone feature.
  • [7] DVLDHOUZ hydra-evaluator: Reduce verbosity
  • [8] RXVJFQ5A Evaluator cleanups
  • [9] FTPCV25M Store aggregate members in the database
  • [10] MPFSVI5X Pedantry: CLOCK_REALTIME -> CLOCK_MONOTONIC
  • [11] TULPZ62Y * Perform builds in parallel.
  • [12] IMQRX4MP hydra-eval-jobs: Use JSON instead of XML
  • [13] RFE6T5LG * Store jobset evaluations in the database explicitly. This includes
  • [14] SRBU2RAE Warn against multiple jobs with the same name
  • [15] ZDENAYQI * email notification of evaluation errors to project owner (if desired)
  • [16] PHNLYPKB Call buildFinished when a cached build is added
  • [17] NS7SND6R hydra-evaluator: Send statistics to statsd
  • [18] VU2OLHD2 Move most of AddBuilds to hydra-eval-jobset
  • [19] LAJHRL6O Fix tests
  • [20] AFTXA575 * $HYDRA_DATA environment variable.
  • [21] X27GNHDV * Basic job info in the database.
  • [22] JOYONH2K Prevent multiple builds with the same (job, outPath) tuple from being added
  • [23] PXTSKX4G Add buildQueued plugin hook
  • [24] JQQYF4S3 Fix build-queued plugin hook
  • [25] KZJZSCQB Remove redundant check

Change contents

  • replacement in src/script/hydra-eval-jobset at line 355
    [3.11074][3.11074:11144]()
    my ($inputInfo, $exprType, $nixExprInputName, $nixExprPath) = @_;
    [3.11074]
    [3.1424]
    my ($inputInfo, $exprType, $nixExprInputName, $nixExprPath, $flakeRef) = @_;
    my @cmd;
  • replacement in src/script/hydra-eval-jobset at line 359
    [3.1425][3.11145:11277]()
    my $nixExprInput = $inputInfo->{$nixExprInputName}->[0]
    or die "cannot find the input containing the job expression\n";
    [3.1425]
    [3.11508]
    if (defined $flakeRef) {
    @cmd = ("hydra-eval-jobs",
    "--flake", $flakeRef,
    "--gc-roots-dir", getGCRootsDir,
    "--max-jobs", 1);
    } else {
    my $nixExprInput = $inputInfo->{$nixExprInputName}->[0]
    or die "cannot find the input containing the job expression\n";
  • replacement in src/script/hydra-eval-jobset at line 368
    [3.11509][3.11509:11599]()
    my $evaluator = ($exprType eq "guile") ? "hydra-eval-guile-jobs" : "hydra-eval-jobs";
    [3.11509]
    [3.11599]
    my $evaluator = ($exprType eq "guile") ? "hydra-eval-guile-jobs" : "hydra-eval-jobs";
  • replacement in src/script/hydra-eval-jobset at line 370
    [3.11600][2.100:319]()
    my @cmd = ($evaluator,
    "<" . $nixExprInputName . "/" . $nixExprPath . ">",
    "--gc-roots-dir", getGCRootsDir,
    "-j", 1,
    inputsToArgs($inputInfo, $exprType));
    [3.11600]
    [3.11725]
    @cmd = ($evaluator,
    "<" . $nixExprInputName . "/" . $nixExprPath . ">",
    "--gc-roots-dir", getGCRootsDir,
    "--max-jobs", 1,
    inputsToArgs($inputInfo, $exprType));
    }
  • replacement in src/script/hydra-eval-jobset at line 388
    [3.12055][3.12055:12146]()
    die "$evaluator returned " . ($res & 127 ? "signal $res" : "exit code " . ($res >> 8))
    [3.12055]
    [3.12146]
    die "hydra-eval-jobs returned " . ($res & 127 ? "signal $res" : "exit code " . ($res >> 8))
  • replacement in src/script/hydra-eval-jobset at line 394
    [3.12266][3.12266:12318]()
    return (decode_json($jobsJSON), $nixExprInput);
    [3.12266]
    [3.12318]
    return decode_json($jobsJSON);
  • replacement in src/script/hydra-eval-jobset at line 412
    [3.12772][3.12772:12887]()
    my ($db, $jobset, $inputInfo, $nixExprInput, $buildInfo, $buildMap, $prevEval, $jobOutPathMap, $plugins) = @_;
    [3.12772]
    [3.12887]
    my ($db, $jobset, $inputInfo, $buildInfo, $buildMap, $prevEval, $jobOutPathMap, $plugins) = @_;
  • replacement in src/script/hydra-eval-jobset at line 640
    [3.217][3.2570:2680](),[3.534][3.2570:2680](),[3.5549][3.2570:2680]()
    my ($jobs, $nixExprInput) = evalJobs($inputInfo, $exprType, $jobset->nixexprinput, $jobset->nixexprpath);
    [3.217]
    [3.218]
    my $jobs = evalJobs($inputInfo, $exprType, $jobset->nixexprinput, $jobset->nixexprpath, $jobset->flake);
  • replacement in src/script/hydra-eval-jobset at line 685
    [3.471][3.4506:4626](),[3.2411][3.4506:4626]()
    checkBuild($db, $jobset, $inputInfo, $nixExprInput, $job, \%buildMap, $prevEval, $jobOutPathMap, $plugins);
    [3.471]
    [3.5911]
    checkBuild($db, $jobset, $inputInfo, $job, \%buildMap, $prevEval, $jobOutPathMap, $plugins);