forked from DGNum/colmena
Small fixes to eval logging
This commit is contained in:
parent
406e5a6443
commit
21c2bef3ad
2 changed files with 14 additions and 2 deletions
|
@ -147,12 +147,17 @@ impl Host for Local {
|
|||
execution.set_progress_bar(bar.clone());
|
||||
}
|
||||
|
||||
execution.run().await?;
|
||||
let result = execution.run().await;
|
||||
|
||||
let (stdout, stderr) = execution.get_logs();
|
||||
self.logs += stderr.unwrap();
|
||||
|
||||
stdout.unwrap().lines().map(|p| p.to_string().try_into()).collect()
|
||||
match result {
|
||||
Ok(()) => {
|
||||
stdout.unwrap().lines().map(|p| p.to_string().try_into()).collect()
|
||||
}
|
||||
Err(e) => Err(e),
|
||||
}
|
||||
}
|
||||
async fn activate(&mut self, profile: &Profile, goal: DeploymentGoal) -> NixResult<()> {
|
||||
if goal.should_switch_profile() {
|
||||
|
|
|
@ -2,6 +2,7 @@ use std::convert::{TryFrom, TryInto};
|
|||
use std::marker::PhantomData;
|
||||
use std::path::{Path, PathBuf};
|
||||
use std::ops::Deref;
|
||||
use std::fmt;
|
||||
|
||||
use serde::{Serialize, Deserialize};
|
||||
|
||||
|
@ -84,3 +85,9 @@ impl<T: TryFrom<Vec<StorePath>, Error=NixError>> StoreDerivation<T> {
|
|||
paths.try_into()
|
||||
}
|
||||
}
|
||||
|
||||
impl<T: TryFrom<Vec<StorePath>>> fmt::Display for StoreDerivation<T> {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
write!(f, "{:?}", self.path)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue