question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Job never stop with javascript input

See original GitHub issue

Hello there, we are facing an issue with a workflow that is using this type of CWL file:

the problem appear only when i’m using “InlineJavascriptRequirement” with this kind of javascript expressions :

my_step:
    run: ./my_sub_cwl.cwl
    in:
      # Javascript sub selection
      array_input:
        source: array_input
        valueFrom: |
          ${
            for (var i = 0 ; i < self.length; i++) {
              if ( self[i].basename.includes("<here I'm putting any string in order to filter>")) {
                return self[i]
              }
            }
            return self[0]
          }
     
    out: [ out1, out2]

I also tried another notation, but the exact same issue appears:

valueFrom: $(inputs.array_input.filter(f => f.basename.includes("<here I'm putting any string in order to filter>"))[0])

The actual task is finishing correctly (with a return_code = 0 ), the input File generated by the Javascript expression is properly set and the file is retrieved.

BUT

The job never “finished” properly and loop over this message infinitely : [2021-12-16T14:48:28+0000] [Thread-2 ] [W] [toil.batchSystems.singleMachine] Sent redundant job completion kill to surviving process group 615 known to batch system 140180515079744

Important note :

  1. We were not facing this issue with toil v5.3.0 but only after updating to v5.5.0 (we didn’t tried with 5.4.0)
  2. I’m not facing the issue if I use the following expression : valueFrom: $(self[0])

I did not found any similar issue for now, and don’t know what to try in order to fix it.

Any help would be really helpful.

Thanks a lot in advance 😃 , Etienne

┆Issue is synchronized with this Jira Task ┆friendlyId: TOIL-1110

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:16 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
w-gaocommented, Dec 23, 2021

I did some testing and I don’t think the signal handler in Toil.__enter__ would override the handlers in the _toil_worker process. (I also started https://github.com/DataBiosphere/toil/compare/issues/3965-user-provided-exit-handler but I don’t think it’ll help much here)

However, the problem is that a sigterm signal on the leader process might not propagate to its workers, so I don’t know the best way to handle interrupts like this on the worker. I can look more into this after winter break.

1reaction
mr-ccommented, Dec 21, 2021
Read more comments on GitHub >

github_iconTop Results From Across the Web

Prevent typing in Text Field Input, Even Though Field is NOT ...
I have this requirement. Maybe I can block all inputs via JS or jQuery? javascript · jquery · html · disabled-input.
Read more >
Event.preventDefault() - Web APIs | MDN
The preventDefault() method of the Event interface tells the user agent that if the event does not get explicitly handled, its default ...
Read more >
Troubleshoot AWS Glue job running for a long time
Some common reasons why your AWS Glue jobs take a long time to complete are the following: Large datasets; Non-uniform distribution of data...
Read more >
Workflow syntax for GitHub Actions
When a pattern matches the branches-ignore pattern, the workflow will not run. ... <job_id>.if conditional to prevent a job from running unless a...
Read more >
Python While Loop Tutorial – While True Syntax Examples ...
If you want to learn how to work with while loops in Python, ... which is a loop that never stops (in theory)...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found