Added loging definitions and rich log handling. Operation and Recursive now define bypassed status based on completed count.
This commit is contained in:
@@ -1,14 +1,17 @@
|
||||
import logging
|
||||
import pprint
|
||||
from rich.progress import track
|
||||
from rich.console import Console
|
||||
|
||||
from core.runtime.managefailure import manageFailure
|
||||
from core.runtime.stopsignals import checkDependency
|
||||
from core.execution.processregistry import registerProcess
|
||||
|
||||
from core.console import console
|
||||
|
||||
outputs = {}
|
||||
|
||||
#console = Console(stderr=True)
|
||||
|
||||
def buildOperation(definition, outputs):
|
||||
process_log = True
|
||||
|
||||
@@ -22,7 +25,8 @@ def buildOperation(definition, outputs):
|
||||
actions = track(
|
||||
actions,
|
||||
#description=definition.name
|
||||
description=f"[green]{definition.name}[/green]"
|
||||
description=f"[green]{definition.name}[/green]",
|
||||
console=console
|
||||
)
|
||||
|
||||
for action in actions:
|
||||
@@ -57,7 +61,11 @@ def buildOperation(definition, outputs):
|
||||
|
||||
#Print completion status after runtime processes
|
||||
if process_log:
|
||||
logging.info(f"{definition.name} completed")
|
||||
#print(outputs["processes"][definition.name]["completed"])
|
||||
if len(outputs["processes"][definition.name]["completed"]) == 1:
|
||||
logging.info(f"{definition.name} bypassed")
|
||||
else:
|
||||
logging.info(f"{definition.name} completed")
|
||||
|
||||
#For debugging purposes only
|
||||
process_registry_logs = False
|
||||
|
||||
Reference in New Issue
Block a user