## TL;DR
Wait for the children before the parent declares done: sweep results are lost when the parent job finishes and cleans up while child runs are still uploading, so make the parent wait on child completion and give uploads a durable local queue. The child runs did the work; the loss happens in the handoff. A parent that exits on submission rather than completion tears down shared volumes, credentials, or temp space the uploads still need.

```text
hyperparameter sweep results lost when parent job finishes before child runs upload failure
```

## Use this when
- The check or run fails with this symptom: hyperparameter sweep results are lost when the parent job finishes before child runs upload.
- You are working on a sweep orchestration where a parent job launches child training runs that upload results at exit and the failure repeats on the same data or configuration.
- You need the failing run, call, or stage isolated before changing code or thresholds.

## Not for this skill when
- Children that never started, where the loss is a scheduling failure and no upload wait would help.
- The error text names a different tool, stage, or root cause. Match the verbatim error first and use that skill.

## Steps
1. Compare the sweep plan with the runs that reached the tracker. Verify: missing runs correspond to children still running at parent exit
2. Check child logs for uploads interrupted at the parent finish time. Verify: upload errors cluster at that timestamp
3. Change the parent to block until every child reports completion, with a timeout and a per-child status summary. Verify: the parent outlives the last upload
4. Enable offline or queued logging in the child so results survive even a hard parent kill. Verify: queued results sync after the fact
5. Rerun a small sweep. Verify: every child run appears in the tracker

## Variant phrasings
### sweep results lost parent job finishes child upload
The shorter phrasing focused on the named failure.
### hyperparameter sweep child runs missing failure
The symptom phrasing a searcher tries next.
### sweep parent wait child completion fix
The variant naming the failing stage or tool directly.

Compatibility: Sweep orchestration in W&B, Ray Tune, and custom parent child job designs

## Why it happens
Sweep parents are often written as launchers: submit children, print their ids, exit. Platforms then reap the job resources, and child uploads that were buffered, retried, or simply slow are cut off, leaving gaps that look like failed training rather than lost reporting.

## Edge cases / pitfalls
- A parent wait needs its own timeout and partial result reporting, or one hung child blocks the whole sweep record.
- Local queues must live on storage that survives the job; a queue on the reaped volume is lost with it.

## Provenance

Resolved from the public thread: https://vectle.com/posts/pst_JV5nD0FRIR3Coa8eyf9t4A
