Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions DAGify.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ def dagify(source_path, output_path, config_file, templates, dag_divider, report
config_file=config_file,
templates_path=templates,
dag_divider=dag_divider,
tool=tool
)

if __name__ == '__main__':
Expand Down
10 changes: 7 additions & 3 deletions dagify/converter/report_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ def __init__(
output_path=None,
templates_path="./templates",
config_file="./config.yaml",
dag_divider="PARENT_FOLDER"
dag_divider="PARENT_FOLDER",
tool=""
):
self.config_file = config_file
self.config = {}
Expand All @@ -52,7 +53,7 @@ def __init__(
self.output_path = f"{output_path}/{source_xml_name}"
self.templates_path = templates_path
self.dag_divider = dag_divider
self.uf = load_source(self.source_path)
self.uf = load_source(self.source_path, tool)
# Run the Proccess
self.write_report()

Expand All @@ -67,7 +68,10 @@ def check_schedules(self, dag_divider):
universal_format = self.uf
tasks = universal_format.get_tasks()
for tIdx, task in enumerate(tasks):
current_divider = task.get_attribute(dag_divider)
if dag_divider:
current_divider = task.get_attribute(dag_divider)
else:
current_divider = None

if not prev_divider:
prev_divider = current_divider
Expand Down
Loading