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

Modified seaexplorer.py so it will run without .gli files present #107

Merged
merged 2 commits into from
Jul 20, 2022

Conversation

hvdosser
Copy link
Collaborator

No description provided.

@@ -99,7 +100,6 @@ def raw_to_rawnc(indir, outdir, deploymentyaml, incremental=True,
continue

badfiles = []
goodfiles = []
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does badfiles not get the same treatment?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had been thinking we wanted each type of bad file logged separately, but if that's not the case then certainly it can get the same treatment.

_log.warning(f'No valid unprocessed seaexplorer files found in'
f'{indir}')
return False
if not goodfiles:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess this is fine. I'd still prefer some explanation of what this fixes and why this is the correct fix. Because this seems like it should be fine.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing the location of the if not goodfiles: statement prevents the function from returning a value of False before running the pld1 for-loop. The return False was previously within the for rawsub in ['raw', 'sub']: for-loop, meaning that a value of False could be returned before any pld1 files were processed. Moving the if not goodfiles: statement out of that for-loop ensures that we will process both gld and pld1 files before the function returns anything.

@jklymak jklymak merged commit 3db2198 into c-proof:main Jul 20, 2022
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

Successfully merging this pull request may close these issues.

2 participants