@@ -287,8 +287,8 @@ def _build_musica(clone_dest: str) -> str:
287
287
subprocess .run (command , stdout = subprocess .PIPE , stderr = subprocess .PIPE ,
288
288
text = True , check = False )
289
289
except subprocess .CalledProcessError as e :
290
- raise subprocess .CalledProcessError ("The subprocess for cmake \
291
- to configure the MUSICA CMake project failed." ) from e
290
+ raise subprocess .CalledProcessError (e . returncode , e . cmd , "The subprocess \
291
+ for cmake to configure the MUSICA CMake project failed." ) from e
292
292
except FileNotFoundError as e :
293
293
raise FileNotFoundError ("The 'cmake' command was not found." ) from e
294
294
except OSError as e :
@@ -299,8 +299,8 @@ def _build_musica(clone_dest: str) -> str:
299
299
subprocess .run (command , stdout = subprocess .PIPE , stderr = subprocess .PIPE ,
300
300
text = True , check = False )
301
301
except subprocess .CalledProcessError as e :
302
- raise subprocess .CalledProcessError ("The subprocess for cmake \
303
- to build the MUSICA library failed." ) from e
302
+ raise subprocess .CalledProcessError (e . returncode , e . cmd , "The subprocess \
303
+ for cmake to build the MUSICA library failed." ) from e
304
304
except FileNotFoundError as e :
305
305
raise FileNotFoundError ("The 'cmake' command was not found." ) from e
306
306
except OSError as e :
@@ -379,8 +379,8 @@ def _set_musica_lib_path(musica_install_path: str, caseroot: str) -> None:
379
379
subprocess .run (command , stdout = subprocess .PIPE , stderr = subprocess .PIPE ,
380
380
text = True , check = False )
381
381
except subprocess .CalledProcessError as e :
382
- raise subprocess .CalledProcessError ("The subprocess for xmlchange \
383
- to set the MUSICA library path failed." ) from e
382
+ raise subprocess .CalledProcessError (e . returncode , e . cmd , "The subprocess \
383
+ for xmlchange to set the MUSICA library path failed." ) from e
384
384
except FileNotFoundError as e :
385
385
raise FileNotFoundError ("The 'xmlchange' command was not found." ) from e
386
386
except OSError as e :
@@ -413,8 +413,8 @@ def _clone_and_checkout(repo_url: str, tag_name: str, clone_dest: str) -> None:
413
413
subprocess .run (["git" , "clone" , repo_url , repo_path ],
414
414
stdout = subprocess .PIPE , stderr = subprocess .PIPE , text = True , check = False )
415
415
except subprocess .CalledProcessError as e :
416
- raise subprocess .CalledProcessError (f"The subprocess for git \
417
- to clone the repository { repo_url } failed." ) from e
416
+ raise subprocess .CalledProcessError (e . returncode , e . cmd , f"The subprocess \
417
+ for git to clone the repository { repo_url } failed." ) from e
418
418
except FileNotFoundError as e :
419
419
raise FileNotFoundError ("The 'git' command was not found." ) from e
420
420
except OSError as e :
@@ -424,8 +424,8 @@ def _clone_and_checkout(repo_url: str, tag_name: str, clone_dest: str) -> None:
424
424
subprocess .run (["git" , "-C" , repo_path , "checkout" , tag_name ],
425
425
stdout = subprocess .PIPE , stderr = subprocess .PIPE , text = True , check = False )
426
426
except subprocess .CalledProcessError as e :
427
- raise subprocess .CalledProcessError (f"The subprocess for git \
428
- to checkout the branch { tag_name } failed." ) from e
427
+ raise subprocess .CalledProcessError (e . returncode , e . cmd , f"The subprocess \
428
+ for git to checkout the branch { tag_name } failed." ) from e
429
429
except FileNotFoundError as e :
430
430
raise FileNotFoundError ("The 'git' command was not found." ) from e
431
431
except OSError as e :
0 commit comments