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

Detecting errors in data unstaging #5345

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open

Detecting errors in data unstaging #5345

wants to merge 6 commits into from

Conversation

jorgee
Copy link
Contributor

@jorgee jorgee commented Sep 30, 2024

close #3711

  • Enables fast failure (set -e) at unstage part and removes "|| true" statement in the unstage.
  • Splits unstage in control and task outputs.
  • Unstage of control outputs after task outputs to see errors in .command.err/out
  • Command to skip task outputs unstaging is 'true' instead of null (Google Life sciences part)

Copy link

netlify bot commented Sep 30, 2024

Deploy Preview for nextflow-docs-staging canceled.

Name Link
🔨 Latest commit 65d2ec9
🔍 Latest deploy log https://app.netlify.com/sites/nextflow-docs-staging/deploys/674c4783e547960008492891

@jorgee jorgee changed the title Test 3711 Detecting errors in data unstaging Sep 30, 2024
@jorgee jorgee marked this pull request as draft October 9, 2024 08:55
…/out

Signed-off-by: jorgee <jorge.ejarque@seqera.io>
Signed-off-by: jorgee <jorge.ejarque@seqera.io>
Signed-off-by: jorgee <jorge.ejarque@seqera.io>
Signed-off-by: jorgee <jorge.ejarque@seqera.io>
Signed-off-by: jorgee <jorge.ejarque@seqera.io>
@jorgee jorgee marked this pull request as ready for review October 9, 2024 11:08
@nextflow-io nextflow-io deleted a comment from bentsherman Nov 20, 2024
local last_err=$?
## capture the task error first or fallback to unstage error
exit_status=${nxf_main_ret:=0}
[[ ${exit_status} -eq 0 && ${nxf_unstage_ret:0} -ne 0 ]] && exit_status=${nxf_unstage_ret}
Copy link
Member

Choose a reason for hiding this comment

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

Why there's ${nxf_unstage_ret:0} in the condition and exit_status=${nxf_unstage_ret} in the assignment? it may be better to use a local intermediate variable as for local last_err=$?

if [[ ${nxf_main_ret:=0} == 0 ]]; then
## Data unstaging redirecting stdout and stderr with append mode
(set -e -o pipefail; ({{unstage_cmd}} | tee -a {{stdout_file}}) 3>&1 1>&2 2>&3 | tee -a {{stderr_file}})
nxf_unstage_ret=$?
Copy link
Member

Choose a reason for hiding this comment

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

Was this tested which S3 uploads that are made in a parallel logic? see here

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.

Validation of task outputs
2 participants