pub fn ensure_file_exists_or_download_http_with_timeout(
filepath: &Path,
url: &str,
checksums: Option<&Path>,
timeout_secs: u64,
) -> Result<()>Expand description
Ensures that a file exists at the specified path by downloading it if necessary, with a custom timeout.
ยงErrors
Returns an error if:
- The HTTP request cannot be sent or returns a non-success status code after retries.
- Any I/O operation fails during file creation, reading, or writing.
- Checksum verification or JSON parsing fails.