'Extracts and normalizes additional paths for code execution.
For now, there\'s a default path of data/course/code; this may be removed
at some point.
script : ?? (TODO)'

def _extract_system_path(self, script):

    DEFAULT_PATH = ['code']
    raw_path = (script.get('system_path', '').split(':') + DEFAULT_PATH)
    path = []
    for dir in raw_path:
        if (not dir):
            continue
        dir = os.path.join(self.capa_system.filestore.root_path, dir)
        reldir = os.path.relpath(dir, self.capa_system.filestore.root_path)
        if ('..' in reldir):
            log.warning('Ignoring    Python    directory    outside    of    course:    %r', dir)
            continue
        abs_dir = os.path.normpath(dir)
        path.append(abs_dir)
    return path
