AttributeError: 'NoneType' object has no attribute 'getchildren' #151
Open
Description
What is the reason for causing this error?
Traceback (most recent call last):
File "/home/user/myproject/1-parse-xml-image-caption-inline.py", line 137, in <module>
caption_dict = pp.parse_pubmed_caption(xml_file_path) # dict_keys(['pmid', 'pmc', 'fig_caption', 'fig_id', 'fig_label', 'graphic_ref'])
File "/home/user/anaconda3/envs/medline/lib/python3.10/site-packages/pubmed_parser/pubmed_oa_parser.py", line 428, in parse_pubmed_caption
fig_captions = fig.find("caption").getchildren()
AttributeError: 'NoneType' object has no attribute 'getchildren'