Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modifying existing entries in an existing header doesn't work #318

Open
DavidT3 opened this issue Jan 21, 2021 · 1 comment
Open

Modifying existing entries in an existing header doesn't work #318

DavidT3 opened this issue Jan 21, 2021 · 1 comment

Comments

@DavidT3
Copy link

DavidT3 commented Jan 21, 2021

In my specific case I wish to update some headers in a binary table HDU, within a file with multiple HDUs.

The keywords that I wish to modify already exist, and then when my code attempts to modify them using write_key or write_keys what seems to happen is that rather than the existing entry in the header list being replaced, another dictionary is added with the same name and a different value entry.

I don't know then know how cfitsio writes that out to the file, but the tools I commonly use for analysis (topcat and XSPEC for instance) only see the original entry.

Perhaps I'm simply using fitsio wrong, but I can't figure out any way to force it to replace the existing entry, or delete the original so I can add a new entry without conflicts

@esheldon
Copy link
Owner

Thanks for the report. Can you please post an example that reproduces?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants