ofgulban/bvbabel

error using fmr.write_fmr

Closed this issue · 1 comments

error for me in line 296, in write_fmr:

    data = header["ProtocolFile"]
    KeyError: 'ProtocolFile'

This error came up after using the same (unaltered) header file obtained from fmr.read_fmr for saving.
What seems to be the problem is that the read_fmr - because of its approach - is flexible in writing header info
(e.g: 'elif content[0] == "ProtocolFile" for line parsing). However in the write_fmr function is not, leading to KeyErrors for non existing items.

Thanks @jorievanharen for opening this issue. I have not finished write_fmr implementation yet. I will prioritize this.