Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
biopet.biopet
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Mirrors
biopet.biopet
Commits
bdd9ce38
Commit
bdd9ce38
authored
9 years ago
by
Peter van 't Hof
Browse files
Options
Downloads
Patches
Plain Diff
Catch NullPointer from queue and convert is to null instead of an failure
parent
c6980164
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
public/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/BiopetCommandLineFunction.scala
+20
-0
20 additions, 0 deletions
.../nl/lumc/sasc/biopet/core/BiopetCommandLineFunction.scala
with
20 additions
and
0 deletions
public/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/BiopetCommandLineFunction.scala
+
20
−
0
View file @
bdd9ce38
...
...
@@ -81,6 +81,12 @@ trait BiopetCommandLineFunction extends CommandLineFunction with Configurable {
/** Set default output file, threads and vmem for current job */
private
[
core
]
def
internalBeforeGraph
()
:
Unit
=
{
val
firstOutput
=
try
{
this
.
firstOutput
}
catch
{
case
e
:
NullPointerException
=>
null
}
if
(
jobOutputFile
==
null
&&
firstOutput
!=
null
)
jobOutputFile
=
new
File
(
firstOutput
.
getAbsoluteFile
.
getParent
,
"."
+
firstOutput
.
getName
+
"."
+
configName
+
".out"
)
...
...
@@ -254,6 +260,10 @@ trait BiopetCommandLineFunction extends CommandLineFunction with Configurable {
def
|
(
that
:
BiopetCommandLineFunction
)
:
BiopetCommandLineFunction
=
{
this
.
_outputAsStdout
=
true
that
.
_inputAsStdin
=
true
this
.
beforeGraph
()
this
.
internalBeforeGraph
()
that
.
beforeGraph
()
that
.
internalBeforeGraph
()
this
match
{
case
p
:
BiopetPipe
=>
{
p
.
commands
.
last
.
_outputAsStdout
=
true
...
...
@@ -309,6 +319,11 @@ trait BiopetCommandLineFunction extends CommandLineFunction with Configurable {
}
case
Right
(
cmd
)
=>
{
cmd
.
_outputAsStdout
=
true
cmd
.
beforeGraph
()
cmd
.
internalBeforeGraph
()
this
.
beforeGraph
()
this
.
internalBeforeGraph
()
this
.
threads
+=
cmd
.
threads
try
{
if
(
cmd
.
outputs
!=
null
)
outputFiles
++=
cmd
.
outputs
if
(
cmd
.
inputs
!=
null
)
deps
++=
cmd
.
inputs
...
...
@@ -328,6 +343,11 @@ trait BiopetCommandLineFunction extends CommandLineFunction with Configurable {
}
case
Right
(
cmd
)
=>
{
cmd
.
_inputAsStdin
=
true
cmd
.
beforeGraph
()
cmd
.
internalBeforeGraph
()
this
.
beforeGraph
()
this
.
internalBeforeGraph
()
this
.
threads
+=
cmd
.
threads
try
{
if
(
cmd
.
outputs
!=
null
)
outputFiles
++=
cmd
.
outputs
if
(
cmd
.
inputs
!=
null
)
deps
++=
cmd
.
inputs
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment