mirror of
https://github.com/tig-pool-nk/tig-monorepo.git
synced 2026-02-21 19:27:21 +08:00
Benchmarker should filter for active challenges.
This commit is contained in:
parent
2a4ade4220
commit
044c24d90c
@ -24,7 +24,16 @@ pub async fn execute() -> Result<QueryData> {
|
||||
let (algorithms_by_challenge, download_urls) = results.0?;
|
||||
let player_data = results.1?;
|
||||
let (benchmarks, proofs, frauds) = results.2?;
|
||||
let challenges = results.3?;
|
||||
let challenges = results
|
||||
.3?
|
||||
.into_iter()
|
||||
.filter(|c| {
|
||||
c.state()
|
||||
.round_active
|
||||
.as_ref()
|
||||
.is_some_and(|r| *r <= latest_block.details.round)
|
||||
})
|
||||
.collect();
|
||||
cache.insert(
|
||||
latest_block.id.clone(),
|
||||
QueryData {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user