@@ -1026,32 +1026,30 @@ async def _get_libdoc(name: str, args: Tuple[Any, ...], working_dir: str, base_d
1026
1026
LOAD_LIBRARY_TIME_OUT ,
1027
1027
)
1028
1028
1029
- if result .stdout :
1030
- self ._logger .warning (
1031
- lambda : f"stdout captured at loading library { name } { repr (args )} :\n { result .stdout } "
1032
- )
1033
- try :
1034
- if meta is not None :
1035
- meta_file = Path (self .lib_doc_cache_path , meta .filepath_base .with_suffix (".meta.json" ))
1036
- spec_file = Path (self .lib_doc_cache_path , meta .filepath_base .with_suffix (".spec.json" ))
1037
- spec_file .parent .mkdir (parents = True , exist_ok = True )
1029
+ if result .stdout :
1030
+ self ._logger .warning (lambda : f"stdout captured at loading library { name } { repr (args )} :\n { result .stdout } " )
1031
+ try :
1032
+ if meta is not None :
1033
+ meta_file = Path (self .lib_doc_cache_path , meta .filepath_base .with_suffix (".meta.json" ))
1034
+ spec_file = Path (self .lib_doc_cache_path , meta .filepath_base .with_suffix (".spec.json" ))
1035
+ spec_file .parent .mkdir (parents = True , exist_ok = True )
1038
1036
1039
- try :
1040
- spec_file .write_text (as_json (result ), "utf-8" )
1041
- except (SystemExit , KeyboardInterrupt ):
1042
- raise
1043
- except BaseException as e :
1044
- raise RuntimeError (f"Cannot write spec file for library '{ name } ' to '{ spec_file } '" ) from e
1037
+ try :
1038
+ spec_file .write_text (as_json (result ), "utf-8" )
1039
+ except (SystemExit , KeyboardInterrupt ):
1040
+ raise
1041
+ except BaseException as e :
1042
+ raise RuntimeError (f"Cannot write spec file for library '{ name } ' to '{ spec_file } '" ) from e
1045
1043
1046
- meta_file .write_text (as_json (meta ), "utf-8" )
1047
- else :
1048
- self ._logger .debug (lambda : f"Skip caching library { name } { repr (args )} " )
1049
- except (SystemExit , KeyboardInterrupt ):
1050
- raise
1051
- except BaseException as e :
1052
- self ._logger .exception (e )
1044
+ meta_file .write_text (as_json (meta ), "utf-8" )
1045
+ else :
1046
+ self ._logger .debug (lambda : f"Skip caching library { name } { repr (args )} " )
1047
+ except (SystemExit , KeyboardInterrupt ):
1048
+ raise
1049
+ except BaseException as e :
1050
+ self ._logger .exception (e )
1053
1051
1054
- return result
1052
+ return result
1055
1053
1056
1054
resolved_args = resolve_args (
1057
1055
args ,
0 commit comments