pub async fn main(state: State, opts: JobOpts) -> Result<()>