-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
Description
Make mg-tool-api.utils the official place where Tool developers can find dummy_pycompss, which provides mock decorators and constants that allow Tools that use pycompss to work outside the compss runtime. The compatibility code block would change to:
try:
if hasattr(sys, '_run_from_cmdl') is True:
raise ImportError
from pycompss.api.parameter import FILE_IN, FILE_OUT
from pycompss.api.task import task
except ImportError:
print("[Warning] Cannot import \"pycompss\" API packages.")
print(" Using mock decorators.")
from utils.dummy_pycompss import FILE_IN, FILE_OUT
from utils.dummy_pycompss import task