def valid_path(path):
<EOL>if path.endswith('<STR_LIT:*>'):<EOL><INDENT>Log.debug('<STR_LIT>', path[:-<NUM_LIT:1>])<EOL>if os.path.isdir(path[:-<NUM_LIT:1>]):<EOL><INDENT>return True<EOL><DEDENT>return False<EOL><DEDENT>Log.debug('<STR_LIT>', path)<EOL>if os.path.isdir(path):<EOL><INDENT>return True<EOL><DEDENT>else:<EOL><INDENT>Log.debug('<STR_LIT>', path)<EOL>if os.path.isfile(path):<EOL><INDENT>return True<EOL><DEDENT><DEDENT>return False<EOL>
Check if an entry in the class path exists as either a directory or a file