cogs
cogs copied to clipboard
cogs add -> cogs rm fails
When doing cogs add followed by cogs rm without specifying freeze rows I get:
Traceback (most recent call last):
File "/Users/matentzn/opt/anaconda3/bin/cogs", line 8, in <module>
sys.exit(main())
File "/Users/matentzn/opt/anaconda3/lib/python3.8/site-packages/cogs/cli.py", line 207, in main
args.func(args)
File "/Users/matentzn/opt/anaconda3/lib/python3.8/site-packages/cogs/rm.py", line 110, in run
rm(args)
File "/Users/matentzn/opt/anaconda3/lib/python3.8/site-packages/cogs/rm.py", line 56, in rm
writer.writerow(sheet)
File "/Users/matentzn/opt/anaconda3/lib/python3.8/csv.py", line 154, in writerow
return self.writer.writerow(self._dict_to_list(rowdict))
File "/Users/matentzn/opt/anaconda3/lib/python3.8/csv.py", line 149, in _dict_to_list
raise ValueError("dict contains fields not in fieldnames: "
ValueError: dict contains fields not in fieldnames: 'Frozen Columns', 'Frozen Rows'
full command trail, but not relevant for you probably.
I used the pypi version of cogs.
matentzn@mbp:~/ws/mondo-analysis (master) $ cogs add mondo_translate/mondo-omim-analysis.csv
matentzn@mbp:~/ws/mondo-analysis (master) $ cogs add mondo_translate/mondo-doid-axiom-analysis.csv
matentzn@mbp:~/ws/mondo-analysis (master) $ cogs add mondo_translate/mondo-omim-axiom-analysis.csv
matentzn@mbp:~/ws/mondo-analysis (master) $ cogs rm mondo_translate/mondo-omim-analysis.csv
I think this is resolved by the current version on master. Here's what I ran:
$ cogs add test/test.tsv
$ cogs add test/test2.tsv
$ cogs add test/test3.tsv
$ cogs rm test/test.tsv
If you have a minute, can you confirm this works OK now?