Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE REQUEST] Support pylint 3.0.0 or more #670

Closed
Pierre-Sassoulas opened this issue Oct 4, 2024 · 19 comments
Closed

[FEATURE REQUEST] Support pylint 3.0.0 or more #670

Pierre-Sassoulas opened this issue Oct 4, 2024 · 19 comments
Milestone

Comments

@Pierre-Sassoulas
Copy link
Collaborator

Pierre-Sassoulas commented Oct 4, 2024

Folow-up to #642 and #643 , we can upgrade to pylint 3.0+ once requirements-detector is compatible with astroid 3.0+, see #641 (comment)

@carlio
Copy link
Member

carlio commented Oct 4, 2024

Not sure why it automatically closed this as "completed"...

@carlio
Copy link
Member

carlio commented Oct 4, 2024

Ok, 1.3.1 requirements-detector is released with the updated astroid version constraints

@Pierre-Sassoulas
Copy link
Collaborator Author

Amazing, thank you @carlio

@Pierre-Sassoulas
Copy link
Collaborator Author

Not sure why it automatically closed this as "completed"...

You can close issue from other projects inside an organization, automatically using the keyword fix/close in the commit message which is what happened with fix https://github.com/landscapeio/prospector/issues/670 in the commit message merged in requirements-detector :)

@ryancausey
Copy link

It looks like there are asteroid crashes while running pylint on Python 3.12 due to needing fixes in Pylint >= 3 and Asteroid >= 3. Thus, I believe this change is needed before full Python 3.12 support can be achieved.

@valeriupredoi
Copy link
Collaborator

I've just pushed requirements-detector==1.3.1 to conda-forge via conda-forge/requirements-detector-feedstock#23 and now (well, once the new 1.3.1 package is available in the registry) we can rebuild prospector==1.11 with the new requirements-detector in conda-forge/prospector-feedstock#49 👍 🍺 Excellent work @Pierre-Sassoulas and @carlio 🍻

@valeriupredoi
Copy link
Collaborator

agh nevermind 1.11 - I just saw you guys released a v1.12 an hour ago, I'll crack on with 1.11 at the feedstock, then I'll check and update the bot's PR for 1.12 too, so that gets released timely too 👍

@Pierre-Sassoulas
Copy link
Collaborator Author

Pierre-Sassoulas commented Oct 7, 2024

There's no way to make pylint work for python 3.12 without the work on compat for pylint 3.0 done for prospector 1.12. (pylint won't work for python 3.12 before pylint 3.0 and prospector won't work with pylint 3.0+ before prospector 1.12).

@valeriupredoi
Copy link
Collaborator

@Pierre-Sassoulas I just saw that via the failed CI at feedstock - shall I just skip 1.11 release and do 1.12 instead?

@valeriupredoi
Copy link
Collaborator

OK folks, got us a working v1.12.0 package via conda-forge/prospector-feedstock#49 - only hitch is from my comment conda-forge/prospector-feedstock#49 (comment) ie:

OK table of troubles: only pylint-django>=2.5.5 (latest, 2.5.5) accepts pylint>=3 but said pylint-django needs pylint-plugin-utils >=0.8 so I plugged them in, the problem is the PyPI package prospector==1.12 got built with pylint-plugin-utils <0.8 so pip check throws a wobbly. pip check is a bit old fashioned IMHO, if the conda package gets built with conda-forge dependencies, so no biggie here

If there is no issue with this @Pierre-Sassoulas @carlio then that PR is ready to be merged and that means Python 3.12.7, pylint 3.3.1 support, and other dependencies as per the build log 🥳

@carlio
Copy link
Member

carlio commented Oct 7, 2024

The guilty line is https://github.com/prospector-dev/prospector/blob/master/pyproject.toml#L45 - it'd be easy to increase that version.

However, I cannot remember if pylint-plugin-utils is used directly by prospector. I'll have a look later, I'm about to get on a plane so I'll be away, but I suspect that removing that dependency might make more sense than pinning it - check if it's used first. I'll have a look myself if nobody else gets to it in time.

@valeriupredoi
Copy link
Collaborator

valeriupredoi commented Oct 7, 2024

good call @carlio - I'll have a look now 👍 Safe flight, mate!

@valeriupredoi
Copy link
Collaborator

nope didn't find any use of it, am removing it from the conda recipe and reinstating pip check just to be sure

@valeriupredoi
Copy link
Collaborator

OK folks prospector=1.12 has been released into the wild (conda-forge 😁 )

@Pierre-Sassoulas
Copy link
Collaborator Author

Are you the person in charge of the conda release @valeriupredoi ? We should probably publish the same thing than what we release on pypi on conda (using the same pipeline). https://github.com/prospector-dev/prospector/blob/master/.github/workflows/release.yml

@valeriupredoi
Copy link
Collaborator

@Pierre-Sassoulas indeed I am - myself and a couple other conda-forge folks that sort of assumed I'd be more active since I am actually actively using Prospector (we in ESMValTool, did use it, and still use it for the moment, before an impending switch to Ruff). The problem with an automated PyPI-like approach is that conda-forge has different ways of building the package than PyPI - we could indeed set up a Github Action that opens a PR at the feedstock for a new build/release, but even then, some or quite a bit of checking of the dependencies should still be done, like I did yesterday for 1.12.

Since I am on the topic of dependencies (and my apologies for hijacking the thread, but it is relevant to v1.12.0), I am seeing a bunch of conflicts in a large and bulky environment - most them stemming from Prospector's pin of flake8 <7 - is that something we can relax? Also is flake8 >=6 imperative - since, and that would be my fault since I unpinned the lower bound yesterday for the conda package, or we can have, say, flake8==5? Cheers muchly 🍺

@valeriupredoi
Copy link
Collaborator

I'll actually open a new issue, I remembered there is that pylint-plugin-utils issue too, apols for yapping on in here 🍺

@Pierre-Sassoulas
Copy link
Collaborator Author

most them stemming from Prospector's pin of flake8 <7 - is that something we can relax?

Yes since we dropped python 3.7 I think

@valeriupredoi
Copy link
Collaborator

most them stemming from Prospector's pin of flake8 <7 - is that something we can relax?

Yes since we dropped python 3.7 I think

excellent! From a purely dependency table pov that should be fine (I'll test when I build the build=1 fro 1.12 but I don't see any issues as of now), was concerned that flake8>=7 may rub against some of Prospector's functionality 👍

@Pierre-Sassoulas Pierre-Sassoulas added this to the 1.12.1 milestone Oct 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants