parameters: (self, dir_name, owned_directories, error_messages)
docstring: Checks to make sure a given directory is present either in CODEOWNERS or OWNED_EXTENSIONS
      Args:
        dir_name: the directory being checked.
        owned_directories: directories currently listed in CODEOWNERS.
        error_messages: where to put an error message for new unowned directories.
docstring_summary: Checks to make sure a given directory is present either in CODEOWNERS or OWNED_EXTENSIONS
      Args:
        dir_name: the directory being checked.
        owned_directories: directories currently listed in CODEOWNERS.
        error_messages: where to put an error message for new unowned directories.
docstring_tokens: Checks to make sure a given directory is present either in CODEOWNERS or OWNED_EXTENSIONS Args : dir_name : the directory being checked . owned_directories : directories currently listed in CODEOWNERS . error_messages : where to put an error message for new unowned directories .
function: def checkOwners(self, dir_name, owned_directories, error_messages):
      """Checks to make sure a given directory is present either in CODEOWNERS or OWNED_EXTENSIONS
      Args:
        dir_name: the directory being checked.
        owned_directories: directories currently listed in CODEOWNERS.
        error_messages: where to put an error message for new unowned directories.
      """
      found = False
      for owned in owned_directories:
        if owned.startswith(dir_name) or dir_name.startswith(owned):
          found = True
      if not found and dir_name not in UNOWNED_EXTENSIONS:
        error_messages.append("New directory %s appears to not have owners in CODEOWNERS" % dir_name)
function_tokens: def checkOwners ( self , dir_name , owned_directories , error_messages ) : found = False for owned in owned_directories : if owned . startswith ( dir_name ) or dir_name . startswith ( owned ) : found = True if not found and dir_name not in UNOWNED_EXTENSIONS : error_messages . append ( "New directory %s appears to not have owners in CODEOWNERS" % dir_name )