Skip to content

Move dummy_pycompss to utils #4

@marcopasi

Description

@marcopasi

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

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions