code: def validate_source_dir(script, directory):
      
      if directory:
          if not os.path.isfile(os.path.join(directory, script)):
              raise ValueError('No file named "{}" was found in directory "{}".'.format(script, directory))
  
      return True
docs: Validate that the source directory exists and it contains the user script
  
      Args:
          script (str):  Script filename.
          directory (str): Directory containing the source file.
  
      Raises:
          ValueError: If ``directory`` does not exist, is not a directory, or does not contain ``script``.