Skip to content

Commit

Permalink
Mark the local benchmarks as 'master'
Browse files Browse the repository at this point in the history
  • Loading branch information
s7tya committed Oct 12, 2024
1 parent 025f64b commit 53b4035
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions collector/src/bin/collector.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ use std::time::Duration;
use std::{str, time::Instant};

use anyhow::Context;
use chrono::Utc;
use clap::builder::TypedValueParser;
use clap::{Arg, Parser};
use collector::compare::compare_artifacts;
Expand Down Expand Up @@ -731,7 +732,12 @@ fn main_result() -> anyhow::Result<i32> {

let mut rt = build_async_runtime();
let mut conn = rt.block_on(pool.connection());
let artifact_id = ArtifactId::Tag(toolchain.id.clone());
let artifact_id = ArtifactId::Commit(Commit {
sha: toolchain.id.clone(),
date: Utc::now().into(),
r#type: CommitType::Master,
});

rt.block_on(purge_old_data(conn.as_mut(), &artifact_id, purge.purge));

let runtime_suite = rt.block_on(load_runtime_benchmarks(
Expand Down Expand Up @@ -880,7 +886,12 @@ fn main_result() -> anyhow::Result<i32> {
)?;
benchmarks.retain(|b| local.category.0.contains(&b.category()));

let artifact_id = ArtifactId::Tag(toolchain.id.clone());
let artifact_id = ArtifactId::Commit(Commit {
sha: toolchain.id.clone(),
date: Utc::now().into(),
r#type: CommitType::Master,
});

let mut rt = build_async_runtime();
let mut conn = rt.block_on(pool.connection());
rt.block_on(purge_old_data(conn.as_mut(), &artifact_id, purge.purge));
Expand Down

0 comments on commit 53b4035

Please sign in to comment.