Subject: Re: [PATCHv2] Re: pypi importer outputs strange character series in optional dependency case.

From: Maxim Cournoyer <[email-masked]>
Date: Mon, 10 Jun 2019 11:10:58 +0900

Hello Ricardo!

Ricardo Wurmus <[email-masked]> writes:

> Hi Maxim,
>
>> Subject: [PATCH 1/9] import: pypi: Do not consider requirements.txt files.
>>
>> * guix/import/pypi.scm (guess-requirements): Update comment.
>> [guess-requirements-from-source]: Do not attempt to parse the file
>> requirements.txt.  Streamline logic.
>
> Why remove the handling of the requirements.txt?  Is it no longer
> popular enough to expect its availability in the source archives?
>
> Please also mention in the commit message that and how you adjusted the
> tests.

The commit message now explains the above:

    import: pypi: Do not consider requirements.txt files.

    PyPI packages are mandated to have a setup.py file, which contains a listing
    of the required dependencies.  The setuptools/distutils machinery embed
    metadata in the archives they produce, which contains this information. There
    is no need nor gain to collect the requirements from a "requirements.txt"
    file, as it is not the true record of dependencies for PyPI packages and may
    contain extraneous requirements or not exist at all.

    * guix/import/pypi.scm (guess-requirements): Update comment.
    [guess-requirements-from-source]: Do not attempt to parse the file
    requirements.txt.  Streamline logic.
    * tests/pypi.scm (test-requires.txt): Rename from test-requirements, to hint
    at the file being tested.
    ("pypi->guix-package"): Adapt so that the fake package contains a requires.txt
    file rather than a requirements.txt file.
    ("pypi->guix-package, wheels"): Likewise.

> You removed the comments from the example requires.txt — are
> comments no longer permitted in these files?  If they are, please don’t
> include those changes.

The comments are now preserved. Thank you!

Maxim