<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def make_sure_path_exists(self, path):
 """ Creates all directories in a path if it does not exist. :param str path: Path to create. :raises Exception: if the path creation attempt hits an error with a code indicating a cause other than pre-existence. """

        try:
            os.makedirs(path)
        except OSError as exception:
            if exception.errno != errno.EEXIST:
                raise