@@ -38,15 +38,19 @@ impl PreComputeAppTrait for PreComputeApp {
3838 /// Runs the complete pre-compute pipeline.
3939 ///
4040 /// This method orchestrates the entire pre-compute process:
41- /// 1. Reads configuration arguments
42- /// 2. Validates the output folder exists
43- /// 3. Downloads and decrypts the dataset (if required)
44- /// 4. Downloads all input files
41+ /// 1. Reads the output directory from environment variable `IEXEC_PRE_COMPUTE_OUT`
42+ /// 2. Reads and validates configuration arguments from environment variables
43+ /// 3. Validates the output folder exists
44+ /// 4. Downloads and decrypts all datasets (if required)
45+ /// 5. Downloads all input files
46+ ///
47+ /// The method collects all errors encountered during execution and returns them together,
48+ /// allowing partial completion when possible (e.g., if one dataset fails, others are still processed).
4549 ///
4650 /// # Returns
4751 ///
4852 /// - `Ok(())` if all operations completed successfully
49- /// - `Err(ReplicateStatusCause)` if any step failed
53+ /// - `Err(Vec< ReplicateStatusCause> )` containing all errors encountered during execution
5054 ///
5155 /// # Example
5256 ///
@@ -123,18 +127,19 @@ impl PreComputeAppTrait for PreComputeApp {
123127 /// Downloads the input files listed in `pre_compute_args.input_files` to the specified `output_dir`.
124128 ///
125129 /// Each URL is hashed (SHA-256) to generate a unique local filename.
126- /// If any download fails, the function returns an error .
130+ /// The method continues downloading all files even if some downloads fail .
127131 ///
128- /// # Returns
132+ /// # Behavior
129133 ///
130- /// - `Ok(())` if all files are downloaded successfully.
131- /// - `Err(ReplicateStatusCause::PreComputeInputFileDownloadFailed(url))` if any file fails to download.
134+ /// - Downloads continue even when individual files fail
135+ /// - Successfully downloaded files are saved with SHA-256 hashed filenames
136+ /// - All download failures are collected and returned together
132137 ///
133- /// # Panics
138+ /// # Returns
134139 ///
135- /// This function panics if:
136- /// - `pre_compute_args` is `None`.
137- /// - `chain_task_id` is `None`.
140+ /// - `Ok(())` if all files are downloaded successfully
141+ /// - `Err(Vec<ReplicateStatusCause>)` containing a `PreComputeInputFileDownloadFailed` error
142+ /// for each file that failed to download
138143 fn download_input_files ( & self ) -> Result < ( ) , Vec < ReplicateStatusCause > > {
139144 let mut exit_causes: Vec < ReplicateStatusCause > = Vec :: new ( ) ;
140145 let args = & self . pre_compute_args ;
0 commit comments