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

Bug in reflagger.py when searching for missing -pta flags #55

Open
NihanPol opened this issue Dec 14, 2023 · 1 comment
Open

Bug in reflagger.py when searching for missing -pta flags #55

NihanPol opened this issue Dec 14, 2023 · 1 comment
Assignees

Comments

@NihanPol
Copy link
Contributor

There is a small bug in the reflag_add_value in reflagger, where it only looks at the first entry in the tim file to determine if flags exist. This is not robust to -pta flags missing deeper in the tim file. This exact scenario happens for J0711 in the t2 tim file, for reference.

The fix is fairly straightforward, and involves replacing line 14 with the following, which checks if a NoneType exists anywhere in the list, not just the first entry/line:
if None in toa.get_flag_value(flag_name)[0]:

I will try to make a formal PR later, but if someone gets to this before I can, please feel free to fold it in.

@gooddc gooddc self-assigned this May 30, 2024
@JPGlaser
Copy link
Collaborator

@gooddc Did this ever get added in back in May?

~ Joe G.

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

3 participants