Add optional run end time override

This commit is contained in:
Joscha 2023-08-14 14:15:38 +02:00
parent 6b8ae19ba5
commit 01124d719b
3 changed files with 12 additions and 1 deletions

View file

@ -65,10 +65,20 @@ pub struct UnfinishedRun {
pub struct FinishedRun {
#[serde(flatten)]
pub run: Run,
/// Override the server's end time.
///
/// Should not be used in normal operation, but can be used when importing
/// completed runs from other sources.
#[serde(skip_serializing_if = "Option::is_none")]
pub end: Option<OffsetDateTime>,
#[serde(default)]
pub exit_code: i32,
#[serde(default)]
pub output: Vec<(Source, String)>,
#[serde(default)]
pub measurements: HashMap<String, Measurement>,
}