Closed pbravakos closed 4 years ago
Hi, there's probably something wrong with your gff file. The parser is meant for parsing metagenomic annotations to Anvi'o, so I can't promise that it works with single genomes. You could just comment the source and version part out if you don't need them in the output. Or give some dummy names to them, e.g.:
source = "TEST"
version = "0.0"
Best regards Antti
Hi, Thanks for the response. I tried commenting the source and version part or trying something like source = "Prodigal" and version = "2.6" but it gives an error later on the product feature attributes, lines 64 and 66. The strange part (for me) is that it loops one time correctly and then gives the error message. I have tried this on different gff files either from Prokka i.e. different strains or from different programs and the results are similar. Probably there are differences between metagenomic and genomic gff3 files . Regards Panos
Hello, Finally the program works just fine! It was my mistake because i had the option --addgenes in Prokka which added an extra line and caused the confusion. Thanks Panos
If anyone else ends up here as they have run prokka with "--compliant" or "--addgenes" then you can just remove the "gene" line from the GFF and this script should then work properly...
grep -v "prokka gene" PROKKA.gff > PROKKA_no_gene_line.gff
I am trying to parse Prokka gff files (from single genomes not metagenomes) and i get the following error: Traceback (most recent call last): File "gff_parser.py", line 43, in
source, version = feature.source.split(':')
ValueError: not enough values to unpack (expected 2, got 1)
I get exactly the same error when i parse gff files from other programs.