File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -123,17 +123,18 @@ async def get_uniprot_summary_helper(
123123
124124 for item in final_result :
125125 # Remove erroneous responses
126- try :
127- Overview (** item ["structures" ][0 ])
128- final_structures .extend (item ["structures" ])
129- except pydantic .ValidationError :
130- provider = item ["structures" ][0 ].get ("provider" )
131- if provider :
132- logger .warning (
133- f"{ provider } returned an erroneous response for { qualifier } "
134- )
135- except Exception :
136- pass
126+ for structure in item ["structures" ]:
127+ try :
128+ Overview (** structure )
129+ final_structures .append (structure )
130+ except pydantic .ValidationError :
131+ provider = structure .get ("provider" )
132+ if provider :
133+ logger .warning (
134+ f"{ provider } returned an erroneous response for { qualifier } "
135+ )
136+ except Exception :
137+ pass
137138
138139 if not final_structures :
139140 return None
You can’t perform that action at this time.
0 commit comments