def _check_if_pyc(fname):
 from imp import find_module
 from os.path import realpath, dirname, basename, splitext
 filepath = realpath(fname)
 dirpath = dirname(filepath)
 module_name = splitext(basename(filepath))[0]
 try:
  (fileobj, fullpath, (_, _, pytype)) = find_module(module_name, [dirpath])
 except ImportError:
  raise IOError('Cannot find config file. Path maybe incorrect! : {0}'.format(filepath))
 return (pytype, fileobj, fullpath)

def _check_if_pyc ( fname ) : from imp import find_module from os . path import realpath , dirname , basename , splitext filepath = realpath ( fname ) dirpath = dirname ( filepath ) module_name = splitext ( basename ( filepath ) ) [ 0 ] try : ( fileobj , fullpath , ( _ , _ , pytype ) ) = find_module ( module_name , [ dirpath ] ) except ImportError : raise IOError ( 'Cannot find config file. Path maybe incorrect! : {0}' . format ( filepath ) ) return ( pytype , fileobj , fullpath )
return true if the extension is .