Write the run timestamp into task_info.yaml - #34
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe your changes
timestampis a required field of the results schema:but nothing was writing it, so
render_results_reporthas been guessing: it parses adate out of a
run_<date>results path, and falls back to the modification time oftask_info.yamlif the path does not have one. Our last run only came out rightbecause
run_full_denbi.shhappens to name the publish dirrun_$(date ...)-- aresults path without a date in it, or a file that got copied around after the run,
gives a wrong timestamp or none at all.
run_benchmarknow writes it, next to thecommitfrom #33:It is the launch time rather than the completion time, because
workflow.completeisonly known once the run is over, and this closure runs before that. That also lines up
with the
run_<date>directory name, which is what the reporting side was inferringfrom anyway.
Checked against Nextflow 26.04 that
workflow.startis anOffsetDateTime, that.toInstant().truncatedTo(SECONDS).toString()gives2026-07-30T13:36:58Z, thatsnakeyaml quotes it so it stays a string rather than a YAML timestamp, and that
yaml::read_yaml()reads it back as a character -- so it passes ajv'sdate-timecheck. Also checked that it resolves inside the
joinStatesclosure, where it is onlyevaluated at execution time.
No change needed on the reporting side this time:
get_task_infoalready prefers thetimestampfromtask_info.yamlover its--timestampargument. I will send the sameto
task_templatetogether with the commit field.Checklist before requesting a review
I have performed a self-review of my code
Check the correct box. Does this PR contain:
Proposed changes are described in the CHANGELOG.md
CI Tests succeed and look good!