Skip to content
Snippets Groups Projects
preprocessing.py 648 B
Newer Older
""" This module contains functions for preprocessing. They are supposed to be
called after validating the input but before device creation.
"""

from modules.border_router import create_border_router

def preprocess(definitions, flags):
    """
    This function handles the preprocessing, operations that need to be done
    before the actual device creation.

    :param definitions: device definition structure
    :param flags: a structure with command line flags
    """

    """ Creating Border router """
    try:
        create_border_router(definitions)
    except Exception:
        print("Could not create border router.")
        raise