IMAP-Science-Operations-Center / imap_processing

IMAP
MIT License
6 stars 14 forks source link

CoDICE: Add catdescs and fieldnames to housekeeping CDF attributes #776

Closed bourque closed 1 month ago

bourque commented 2 months ago

Currently the housekeeping data uses "TBD" for many of the catdesc and fieldname fields in the CDF attributes. These should be updated to actually store useful information. This could possibly be done programmatically by grabbing the short_description and long_description fields in the XTCE definition files. Perhaps something like:

for key, value in (packet.header | packet.data).items():
    fieldname = value.short_description
    catdesc = value.long_description
greglucas commented 2 months ago

Just an FYI that I agree we could do something like you mentioned here, but Tim brought up a good point during the PR review about trying to settle around the YAML definitions rather than programatically adding attributes so I removed it. https://github.com/IMAP-Science-Operations-Center/imap_processing/pull/687#discussion_r1672497506

I suppose we could add a keyword argument to the function to allow that since it sounds like others have also wanted a similar thing. But in general, I think for now if it is just housekeeping data we ignore this and add the istp=False check to cdflib for l1 housekeeping files since it isn't required.