Skip to content
This repository was archived by the owner on Jan 27, 2026. It is now read-only.

Commit 527d113

Browse files
authored
do not submit work when work units are 0 (#504)
1 parent e072e41 commit 527d113

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

crates/worker/src/docker/taskbridge/bridge.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -145,10 +145,13 @@ impl TaskBridge {
145145
}
146146
};
147147

148-
let mut work_units = 1.0;
149-
if output_flops > 0.0 {
150-
work_units = output_flops;
148+
if output_flops <= 0.0 {
149+
error!("Invalid work units calculation: output_flops ({}) must be greater than 0.0. Blocking file validation submission.", output_flops);
150+
return Err(anyhow::anyhow!(
151+
"Invalid work units: output_flops must be greater than 0.0"
152+
));
151153
}
154+
let work_units = output_flops;
152155

153156
tokio::spawn(async move {
154157
if let Err(e) = file_handler::handle_file_validation(

0 commit comments

Comments
 (0)