Skip to content

Conversation

@chrisnovakovic
Copy link
Contributor

pytest 5.4.3 isn't compatible with Python 3.10 and newer. Python 3.10 support was officially added in pytest 6.2.5, while Python 3.11 isn't officially supported yet but appears to work correctly as of pytest 7.2.0. Upgrade to version 7.2.0 and pack its new dependencies into the pytest bootstrap pex.

This also requires upgrading coverage from 5.5 to 6.5.0, which drops support for Python 3.5 and 3.6. (Both versions are now end-of-life.)

Fixes thought-machine/please#2570.

…please-build#82)

The version of pip provided by `python3-pip` in Debian 12 will drop the
custom `--system` option - passing it results in pip exiting with an
error. Rather than always passing `--system` if the host OS is
Debian-like, test whether the configured pip tool implements a
`--system` option, and if so, pass it to the real pip invocation.

Fixes please-build#81.
pytest 5.4.3 isn't compatible with Python 3.10 and newer. Python 3.10
support was officially added in pytest 6.2.5, while Python 3.11 isn't
officially supported yet but appears to work correctly as of pytest
7.2.0. Upgrade to version 7.2.0 and pack its new dependencies into the
pytest bootstrap pex.

This also requires upgrading coverage from 5.5 to 6.5.0, which drops
support for Python 3.5 and 3.6. (Both versions are now end-of-life.)

Fixes thought-machine/please#2570.
@chrisnovakovic
Copy link
Contributor Author

This also causes //test:python2_coverage_test to fail, since coverage 5.0.0 drops support for Python 2. @samwestmoreland is this a problem?

@peterebden
Copy link
Contributor

We did have some users on Python 2 fairly recently, but they weren't using the plugin AFAIK.

I think we have to drop it at this point - it's more important we support 3.10 and 3.11 than the EOL versions. Although probably that should constitute a major version of the plugin?

@samwestmoreland
Copy link
Contributor

Nice one, thanks, Chris! Yeah, I think more users will be happy that we're supporting pythons 3.10 and 3.11 than will be disappointed that we're dropping older versions. But regardless, I agree with Pebers - more important to support 3.10 and 3.11 and to stay up-to-date in general, especially in this instance given the performance gains.

The only question is over the release... We've been developing on the v1 branch and tagging the v1 releases from there. I think the thing to do is to merge the v1 branch back into master, and tag v2 on the master branch. Does anyone have any thoughts/objections?

@chrisnovakovic
Copy link
Contributor Author

Completely missed the activity on the v1 branch, sorry. I can rebase this on that branch if you like.

@samwestmoreland
Copy link
Contributor

No, no worries! It's a bit of a weird setup. master had a bunch of big changes but they weren't quite working so we decided to create a v1 branch which is a straight copy of the python stuff that was in the please repo, so is actually kind of older than 'v0'.

Anyway just looking at v1 and it looks like we're actually already using pytest 7.1.3 there so in fact it seems like we don't need to make any breaking changes/tag a new major version! At least I assume it wouldn't break anything. Maybe the python2 tests are already broken...? So yeah maybe, if you wouldn't mind, could you update the v1 branch to 7.2.0 and we can just proceed that way?

@samwestmoreland
Copy link
Contributor

I'll copy your other fix over to v1 here: #85

@chrisnovakovic
Copy link
Contributor Author

This is already on the v1 branch, which has been merged back into master now.

@chrisnovakovic chrisnovakovic deleted the pytest-7.2.0 branch August 8, 2023 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

pytest not working with python 3.10

3 participants