I am trying to understand a program that uses luigi to build pipelines. I have understood the basics but then there is this
class Task5(luigi.Task):
task_namespace = "examples"
# something else
When I comment the line with task_namespace
the program runs ok but with that line it fails with:
luigi.task_register.TaskClassNotFoundException: No task Task5. Did you mean:
Task
worker
I cannot find a simple example of what task_namespace
is used. Can someone explain to me how to use this?
Also, What is the "namespace" of a Task?
I found the answer after much research.
task_namespace changes the name of the task. So now if you want to refer to Task5
, you should refer it as examples.Task5
because otherwise it would not get recognized. That is why Task5
was not recognized or found