You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A task A, that has bool parameters cannot be found with A.get_related_instances() as shown in the following example:
import os
import luisy
import luigi
class MyAbstractClass(luisy.Task):
def run(self):
self.write(str("test"))
class MyBoolTask(MyAbstractClass):
test_boolean = luisy.BoolParameter(False)
class MyIntTask(MyAbstractClass):
test_int = luisy.IntParameter(42)
task1 = MyBoolTask()
task2 = MyIntTask()
luigi.build([task1, task2], local_scheduler=True)
# show that files are created on disk:
for task_file in os.listdir(os.getenv("WORKING_DIR")):
if "Task" in task_file:
print(task_file)
assert MyIntTask.get_related_instances()[0].read() == "test"
assert MyBoolTask.get_related_instances()[0].read() == "test"
# this assert fails, because get_related instances doesn't find any files at all.
The text was updated successfully, but these errors were encountered:
A task
A
, that has bool parameters cannot be found withA.get_related_instances()
as shown in the following example:The text was updated successfully, but these errors were encountered: