PoonLab / covizu

Rapid analysis and visualization of coronavirus genome variation
https://filogeneti.ca/CoVizu/
MIT License
45 stars 20 forks source link

epicov: unable to convert clusters.json to epicov format #464

Closed GopiGugan closed 1 year ago

GopiGugan commented 1 year ago

convert_json in gisaid_utils.py is throwing an error:

Traceback (most recent call last):
  File "covizu/test_convert_json.py", line 8, in <module>
    epicov_data = gisaid_utils.convert_json(epifile, provision)
  File "covizu/utils/gisaid_utils.py", line 292, in convert_json
    for coldate, accn, location, name in samples:
ValueError: too many values to unpack (expected 4)

Seems to be an edge case. Traced the issue to a sample collected on 23-01-10. Need to figure out why there are 5 items in this list for the sample instead of 4

ArtPoon commented 1 year ago

@GopiGugan reports that one of the sequence names contained a pipe character. Adding a filter to catch for this edge case.