forked from lix-project/hydra
Fix build
This commit is contained in:
parent
93ed7f81cb
commit
639c660abf
|
@ -102,9 +102,9 @@ bool State::getQueuedBuilds(Connection & conn,
|
||||||
if (id > newLastBuildId) newLastBuildId = id;
|
if (id > newLastBuildId) newLastBuildId = id;
|
||||||
if (builds_->count(id)) continue;
|
if (builds_->count(id)) continue;
|
||||||
|
|
||||||
auto build = std::make_shared<Build>();
|
auto build = std::make_shared<Build>(
|
||||||
|
localStore->parseStorePath(row["drvPath"].as<string>()));
|
||||||
build->id = id;
|
build->id = id;
|
||||||
build->drvPath = localStore->parseStorePath(row["drvPath"].as<string>());
|
|
||||||
build->projectName = row["project"].as<string>();
|
build->projectName = row["project"].as<string>();
|
||||||
build->jobsetName = row["jobset"].as<string>();
|
build->jobsetName = row["jobset"].as<string>();
|
||||||
build->jobName = row["job"].as<string>();
|
build->jobName = row["job"].as<string>();
|
||||||
|
@ -402,8 +402,7 @@ Step::ptr State::createStep(ref<Store> destStore,
|
||||||
|
|
||||||
/* If it doesn't exist, create it. */
|
/* If it doesn't exist, create it. */
|
||||||
if (!step) {
|
if (!step) {
|
||||||
step = std::make_shared<Step>();
|
step = std::make_shared<Step>(drvPath.clone());
|
||||||
step->drvPath = drvPath.clone();
|
|
||||||
isNew = true;
|
isNew = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -136,6 +136,9 @@ struct Build
|
||||||
|
|
||||||
std::atomic_bool finishedInDB{false};
|
std::atomic_bool finishedInDB{false};
|
||||||
|
|
||||||
|
Build(nix::StorePath && drvPath) : drvPath(std::move(drvPath))
|
||||||
|
{ }
|
||||||
|
|
||||||
std::string fullJobName()
|
std::string fullJobName()
|
||||||
{
|
{
|
||||||
return projectName + ":" + jobsetName + ":" + jobName;
|
return projectName + ":" + jobsetName + ":" + jobName;
|
||||||
|
@ -201,6 +204,9 @@ struct Step
|
||||||
|
|
||||||
nix::Sync<State> state;
|
nix::Sync<State> state;
|
||||||
|
|
||||||
|
Step(nix::StorePath && drvPath) : drvPath(std::move(drvPath))
|
||||||
|
{ }
|
||||||
|
|
||||||
~Step()
|
~Step()
|
||||||
{
|
{
|
||||||
//printMsg(lvlError, format("destroying step %1%") % drvPath);
|
//printMsg(lvlError, format("destroying step %1%") % drvPath);
|
||||||
|
|
Loading…
Reference in a new issue