8000 Add initialiser for SoftwareRequirement · illusional/python-cwlgen@ae15ec1 · GitHub
[go: up one dir, main page]

Skip to content

Commit ae15ec1

Browse files
authored
Add initialiser for SoftwareRequirement
1 parent ad89d65 commit ae15ec1

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

cwlgen/requirements.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -210,15 +210,16 @@ def parse_dict(cls, d):
210210
# }
211211

212212

213-
class SoftwareRequirement(Requirement):
213+
class
214+
ment(Requirement):
214215
"""
215216
A list of software packages that should be configured in the environment of the defined process.
216217
217218
Documentation: https://www.commonwl.org/v1.0/Workflow.html#SoftwareRequirement
218219
"""
219-
def __init__(self):
220+
def __init__(self, packages=None):
220221
Requirement.__init__(self, "SoftwareRequirement")
221-
self.packages = [] # list[SoftwarePackage]
222+
self.packages = packages or [] # list[SoftwarePackage]
222223

223224
class SoftwarePackage(Serializable):
224225
"""

0 commit comments

Comments
 (0)
0