File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ def extract(htmlstring,
6161 return {}
6262 if errors == 'log' :
6363 logger .exception (
64- f 'Failed to parse html, raises { e } ' )
64+ 'Failed to parse html, raises {}' . format ( e ) )
6565 return {}
6666 if errors == 'strict' :
6767 raise e
@@ -101,7 +101,9 @@ def extract(htmlstring,
101101 output [syntax ] = list (extract (document , base_url = base_url ))
102102 except Exception as e :
103103 if errors == 'log' :
104- logger .exception (f'Failed to extract { syntax } , raises { e } ' )
104+ logger .exception ('Failed to extract {}, raises {}'
105+ .format (syntax , e )
106+ )
105107 if errors == 'ignore' :
106108 pass
107109 if errors == 'strict' :
@@ -141,7 +143,9 @@ def extract(htmlstring,
141143 if errors == 'log' :
142144 output [syntax ] = []
143145 logger .exception (
144- f'Failed to uniform extracted for { syntax } , raises { e } ' )
146+ 'Failed to uniform extracted for {}, raises {}'
147+ .format (syntax , e )
148+ )
145149 if errors == 'strict' :
146150 raise
147151
You can’t perform that action at this time.
0 commit comments