qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 03/11] python: Re-lock pipenv at *oldest* supported versions


From: Wainer dos Santos Moschetta
Subject: Re: [PATCH 03/11] python: Re-lock pipenv at *oldest* supported versions
Date: Tue, 29 Jun 2021 13:44:26 -0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.10.1


On 6/28/21 5:38 PM, John Snow wrote:


On Mon, Jun 28, 2021 at 4:31 PM Wainer dos Santos Moschetta <wainersm@redhat.com> wrote:

On 6/25/21 12:45 PM, John Snow wrote:
> tox is already testing the most recent versions. Let's use pipenv to
> test the oldest versions we claim to support. This matches the stylistic
> choice to have pipenv always test our oldest supported Python version, 3.6.
Currently tox is testing with 3.6 too. Should we remove that version
from the test matrix?

Tox will test with 3.6, but against the very latest pylint/mypy. This test will also use 3.6, but against the oldest pylint/mypy we claim to support in the package metadata. I think they are both useful.

The pipenv test will make sure we don't accidentally increase our dependency requirements without noticing. This has some value for other QEMU developers that are used to running and managing their own linters, such as we did for a long time. I don't want to break their environments by accident. (It also makes sure that no 3.7+ isms sneak into the code by accident, too. This has historically been, and I anticipate it will continue to be, a prominent problem in the Python library.)

The tox test gives us a heads up if there are incompatible changes arriving in the bleeding edge for pylint/mypy et al that I will need to be aware of before they are rolled out and wind up on random developer's systems and start causing 'make check' to fail.

I think it's worth keeping both for now, provided the run cost isn't too great. At the moment it seems rather minimal.


While I was reviewing the next patches I started to understand the tox and pipenv testing strategies. I also think they are useful.

Thanks for the details explanation above.

- Wainer 

 
>
> The effect of this is that the python-check-pipenv CI job on gitlab will
> now test against much older versions of these linters, which will help
> highlight incompatible changes that might otherwise go unnoticed.
>
> Update instructions for adding and bumping versions in setup.cfg. The
> reason for deleting the line that gets added to Pipfile is largely just
> to avoid having the version minimums specified in multiple places in
> config checked into the tree.
>
> (This patch was written by deleting Pipfile and Pipfile.lock, then
> explicitly installing each dependency manually at a specific
> version. Then, I restored the prior Pipfile and re-ran `pipenv lock
> --dev --keep-outdated` to re-add the qemu dependency back to the pipenv
> environment while keeping the "old" packages. It's annoying, yes, but I
> think the improvement to test coverage is worthwhile.)
>
> Signed-off-by: John Snow <jsnow@redhat.com>
> ---
>   python/Pipfile.lock | 113 +++++++++++++++++++++-----------------------
>   python/setup.cfg    |   4 +-
>   2 files changed, 56 insertions(+), 61 deletions(-)

Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com>

Thanks!

reply via email to

[Prev in Thread] Current Thread [Next in Thread]