#NEWLINE# def get_config( path ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# with open ( path ) as f : #NEWLINE# #INDENT# data = f . read ( ) #NEWLINE# #UNINDENT# #UNINDENT# except IOError as e : #NEWLINE# #INDENT# if ( f . errno == errno . ENOENT ) : #NEWLINE# #INDENT# data = None #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# raise e #NEWLINE# #UNINDENT# #UNINDENT# if ( data is None ) : #NEWLINE# #INDENT# return { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# return yaml . safe_load ( data )