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
Add new feature of filtering rows by status. Minor changes like displ… #1152
Conversation
…ay SPECPROD in the heading, not including tonight for daily processing if using --nights
Thanks Kai. The code itself looked good, but when I went to test it on cascades I got an error: Output:
In digging further the code fails whenever I give it a range in which a night doesn't have an exposure table (e.g. the nights of Dec 24-31 2020, Jan 4 2021 etc.) |
py/desispec/desi_proc_dashboard.py
Outdated
@@ -85,7 +85,7 @@ def parse(options): | |||
# File I/O | |||
parser.add_argument('--redux-dir', type=str, help="Product directory, point to $DESI_SPECTRO_REDUX by default ") | |||
parser.add_argument('--output-dir', type=str, help="output portal directory for the html pages, which defaults to your home directory ") | |||
parser.add_argument('--output-name', type=str, default='dashboard.html', help="name of the html page (to be placed in --output-dir).") | |||
parser.add_argument('--output-name', type=str, default='dashboard', help="name of the html page (to be placed in --output-dir).") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Anthony identified the more important issue (crashing), but another minor point: let's keep this as the original method of specifying the output-name including the extension so that we don't arbitrarily break existing cronjobs, notes, etc. that expect to specify --output-name dashboard.html
py/desispec/desi_proc_dashboard.py
Outdated
@@ -240,19 +267,15 @@ def main(args): | |||
#strTable += js_import_str(os.getenv('DESI_DASHBOARD')) | |||
strTable += js_str() | |||
strTable += _closing_str() | |||
with open(os.path.join(os.getenv('DESI_DASHBOARD'),args.output_name),'w') as hs: | |||
with open(os.path.join(os.getenv('DESI_DASHBOARD'),args.output_name+'.html'),'w') as hs: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's change this back to not auto-adding the extension, to keep it the same as it was before.
…name does not add html appendix.
Thanks for pointing out the errors, @akremin @sbailey |
That sounds logical to me too. Thank you. I'll check again and give a review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was able to run on the full cascades and it works well. The three options all seem to work and I can toggle between them.
Add new feature of filtering rows by status. Minor changes like display SPECPROD in the heading, not including tonight for daily processing if using --nights