#NEWLINE# def read_config( ctx , param , value ) : #NEWLINE# #INDENT# if ( not value ) : #NEWLINE# #INDENT# return { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# #UNINDENT# import json #NEWLINE# def underline_dict( d ) : #NEWLINE# #INDENT# if ( not isinstance ( d , dict ) ) : #NEWLINE# #INDENT# return d #NEWLINE# #UNINDENT# return dict ( ( ( k . replace ( '-' , '_' ) , underline_dict ( v ) ) for ( k , v ) in six . iteritems ( d ) ) ) #NEWLINE# #UNINDENT# config = underline_dict ( json . load ( value ) ) #NEWLINE# ctx . default_map = config #NEWLINE# return config