1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
// Copyright 2025 Agentic-Insights
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//! Blocking wrappers around the async download APIs.
//!
//! Behind the `blocking` cargo feature. Each function spins up a
//! single-threaded current-thread Tokio runtime internally and blocks on
//! the corresponding async function — useful for non-async callers
//! (CLI binaries, build scripts, sync simulators) that don't want to
//! manage a runtime themselves.
//!
//! # Example
//!
//! ```no_run
//! use ycbust::blocking::download_objects_blocking;
//! use ycbust::DownloadOptions;
//! use std::path::Path;
//!
//! fn main() -> anyhow::Result<()> {
//! download_objects_blocking(
//! &["006_mustard_bottle"],
//! Path::new("/tmp/ycb"),
//! DownloadOptions::default(),
//! )?;
//! Ok(())
//! }
//! ```
use Path;
use crate::;
/// Synchronous wrapper around [`download_ycb`].
/// Synchronous wrapper around [`download_objects`].