File tree Expand file tree Collapse file tree 4 files changed +119
-99
lines changed Expand file tree Collapse file tree 4 files changed +119
-99
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,10 @@ def dict_to_restructured_text(yaml_data):
3737 rst_output .append ("-----------------------------" )
3838
3939 for key2 , value2 in yaml_data [key ].items ():
40- print (key2 )
40+ if key2 == 'all_products' :
41+ rst_output .append (f'All products of the { value2 } type' )
42+ rst_output .append ('' )
43+ continue
4144 if 'description' not in value2 .keys ():
4245 continue
4346 rst_output .append (f"{ key2 } " )
@@ -66,6 +69,9 @@ def process_file(filepath):
6669 if 'def generate' in line :
6770 function = line .split ('def' )[1 ].split ('(' )[0 ].strip ()
6871 all_products [function ] = {}
72+ if 'All the products of the' in line :
73+ all_products [function ]['all_products' ] = line .split ("'" )[1 ]
74+ print (all_products [function ]['all_products' ])
6975 if 'Accepted product types:' in line :
7076 started = True
7177 reading_params = False
@@ -93,8 +99,6 @@ def process_file(filepath):
9399 all_products [function ][product ]['parameters' ] += " " + \
94100 " " .join (line .replace ('\n ' , ' ' ).split ())
95101 if "prdcfg['type']" in line and '==' in line :
96- print (i )
97- print (filepath )
98102 for product in all_products [function ].keys ():
99103 if product in line :
100104 all_products [function ][product ]['link' ] = (funcpath_to_docpath (filepath ) +
Original file line number Diff line number Diff line change @@ -61,6 +61,4 @@ The core of Pyrad is based on Py-ART. Py-ART was originally developed in the con
6161Disclaimer
6262=============
6363
64- The software is still in a development stage. Please let us know if you would like to test it.
65-
6664MeteoSwiss cannot be held responsible for errors in the code or problems that could arise from its use.
You can’t perform that action at this time.
0 commit comments