Draft stash for refactoring maya submit deadline to use AbstractSubmitDeadline base.

- This does *NOT* work currently!
This commit is contained in:
Roy Nieterau 2022-08-24 00:29:08 +02:00
parent c74a6a87d1
commit 65d785d100
2 changed files with 623 additions and 696 deletions

View file

@ -359,6 +359,27 @@ class DeadlineJobInfo(object):
def OutputDirectory(self, val): # noqa: N802
self._outputDirectory.append(val)
# Asset Dependency
# ----------------------------------------------
_assetDependency = attr.ib(factory=list)
@property
def AssetDependency(self): # noqa: N802
"""Return all OutputDirectory values formatted for Deadline.
Returns:
dict: as `{'OutputDirectory0': 'dir'}`
"""
out = {}
for index, v in enumerate(self._assetDependency):
out["AssetDependency{}".format(index)] = v
return out
@OutputDirectory.setter
def AssetDependency(self, val): # noqa: N802
self._assetDependency.append(val)
# Tile Job
# ----------------------------------------------
TileJob = attr.ib(default=None) # Default: false
@ -396,6 +417,7 @@ class DeadlineJobInfo(object):
serialized.update(self.OutputFilename)
serialized.update(self.OutputFilenameTile)
serialized.update(self.OutputDirectory)
serialized.update(self.AssetDependency)
return serialized