pytest-pylint icon indicating copy to clipboard operation
pytest-pylint copied to clipboard

Help to figure out why pylint is not triggered during the pytest run

Open terlar opened this issue 2 years ago • 2 comments

Hello, I started using this a while back, just before the 0.19.0 release (0.18.0)

At that point it was triggering on pytest, although we had those errors. Since this plugin was updated to 0.19.0 it stopped triggering and I cannot figure out why and how to get it working again.

I do see the plugin being loaded in the output, but it never executes. If I do have some pylint errors it doesn't fail. Running pylint individually works.

$ pytest
================================================ test session starts ================================================
platform linux -- Python 3.10.6, pytest-7.1.3, pluggy-1.0.0
rootdir: .../cli, configfile: pyproject.toml, testpaths: cli, tests
plugins: xdist-2.5.0, forked-1.4.0, mypy-0.9.1, pylint-0.19.0, cov-3.0.0

Any ideas what goes wrong and how to debug this. Could it have something to do with xdist, I did see it mentioned in another issue.

terlar avatar Sep 30 '22 12:09 terlar

I realize this has been wayyy too long not to respond. I just released 0.20.0. Can you try that? If you're still having trouble, can you provide me with a reproducible example where you're seeing it not work? Thanks, and sorry for the ultra-long delay!

carsongee avatar Oct 06 '23 03:10 carsongee

I'm also seeing this with pytest-pylint versions above 0.19.0, could it be related to the new RC file logic?
I'm also using a pyproject.toml file for my pylint config if that helps.

pytest returns exit code 5, no tests found.

I've had to downgrade in the meantime. However on version 0.18.0, if I run it with a --pylint-rcfile==pyproject.toml flag it still fails to find tests. This is why I'm a bit suspicious of the RC file logic changes.

niall-byrne avatar Jan 02 '24 19:01 niall-byrne