(path)
Parses requirements from a requirements file.

    Args:
      path (str): path to the requirements file.

    Yields:
      str: package resource requirement.
Parses requirements from a requirements file.
Parses requirements from a requirements file .
def parse_requirements_from_file(path):
    """Parses requirements from a requirements file.

    Args:
      path (str): path to the requirements file.

    Yields:
      str: package resource requirement.
    """
    with open(path, 'r') as file_object:
        file_contents = file_object.read()
    for req in pkg_resources.parse_requirements(file_contents):
        try:
            requirement = str(req.req)
        except AttributeError:
            requirement = str(req)
        yield requirement
def parse_requirements_from_file ( path ) : with open ( path , 'r' ) as file_object : file_contents = file_object . read ( ) for req in pkg_resources . parse_requirements ( file_contents ) : try : requirement = str ( req . req ) except AttributeError : requirement = str ( req ) yield requirement