File tree Expand file tree Collapse file tree 2 files changed +11
-2
lines changed
sources/gc-qa-rag-etl/etlapp Expand file tree Collapse file tree 2 files changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -118,8 +118,14 @@ def das_generic_main(
118118 ensure_folder_exists (output_dir )
119119
120120 logger .info (f"MarkItDown instance is getting" )
121- markitdown_inst = get_markitdown_inst ()
122- logger .info (f"MarkItDown instance created" )
121+ markitdown_inst = None
122+ try :
123+ markitdown_inst = get_markitdown_inst ()
124+ logger .info (f"MarkItDown instance created" )
125+ except :
126+ markitdown_inst = None
127+ logger .info (f"MarkItDown instance created failed" )
128+ return
123129
124130 files = collect_files (input_dir )
125131 logger .info (f"Found { len (files )} files in { input_dir } " )
Original file line number Diff line number Diff line change @@ -210,6 +210,9 @@ def start_initialize_forum_qa(context: EtlRagContext) -> None:
210210 content = read_text_from_file (file_path )
211211 forum = extract_object (content )
212212
213+ if not thread_dict [file_index ]["content" ]:
214+ continue
215+
213216 metadata = {
214217 "product" : product ,
215218 "url" : thread_dict [file_index ]["content" ]["url" ],
You can’t perform that action at this time.
0 commit comments