You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
************* Module gitlab.mixins
gitlab/mixins.py:121:19: E1102: self._obj_cls is not callable (not-callable)
gitlab/mixins.py:125:15: E1102: self._obj_cls is not callable (not-callable)
gitlab/mixins.py:158:15: E1102: self._obj_cls is not callable (not-callable)
gitlab/mixins.py:248:20: E1102: self._obj_cls is not callable (not-callable)
gitlab/mixins.py:304:15: E1102: self._obj_cls is not callable (not-callable)
gitlab/mixins.py:405:15: E1102: self._obj_cls is not callable (not-callable)
Your code has been rated at 9.94/10 (previous run: 10.00/10, -0.06)
I see a bunch of false-positive issues reported on pylint about this, so it just seems to struggle with this. But also I'm confused why it works on CI 😁
I'll say it's probably because of astroid, bumped from 2.12.11 to 2.12.12, as that does type inference for pylint IIRC. Could you pin that to .11 and try again @lmilbaum?
Fixed. BTW, are those errors reporting a real issue which needs to be addressed or is it a false positive situation? The question is a followup on your comment in the PR. Just to figure out if we want to track this issue.
I think it may be an issue for type checkers, not for runtime. It was already caught by mypy which probably does a better job at type checking, and we've added if TYPE_CHECKING: guards for that reason there already.
Maybe there's another way to fix that. I'd say we can keep this open to track it, but with very low priority from my perspective :)
Activity
nejch commentedon Oct 19, 2022
Hmm, really really odd that this passes in CI.
We have a
TYPE_CHECKINGguard here for mypy with anis not Noneassert, but pylint ignores that for its own type checks.nejch commentedon Oct 19, 2022
I see a bunch of false-positive issues reported on pylint about this, so it just seems to struggle with this. But also I'm confused why it works on CI 😁
lmilbaum commentedon Oct 19, 2022
It is failing in CI
nejch commentedon Oct 19, 2022
Ah, good. I was referring to https://github.com/python-gitlab/python-gitlab/actions/runs/3276883032/jobs/5393461110, from main, which should have failed.
But I suspect there was an update in a transitive dependency that we do not track/freeze, that changed the behavior then.
nejch commentedon Oct 19, 2022
I'll say it's probably because of astroid, bumped from 2.12.11 to 2.12.12, as that does type inference for pylint IIRC. Could you pin that to .11 and try again @lmilbaum?
lmilbaum commentedon Oct 19, 2022
Same result in my DEV environment. Checking in CI.
lmilbaum commentedon Oct 19, 2022
Same result in CI
lmilbaum commentedon Oct 19, 2022
I pinned it to .12 which is the green one in your comment
nejch commentedon Oct 19, 2022
Ah, sorry @lmilbaum. I wasn't very clear on that. The diff was from old to new looking at the logs in the CI runner. Downgrading to .11 should fix it IMO, as the .12 release was a few hours ago. https://github.com/PyCQA/astroid/releases/tag/v2.12.12
lmilbaum commentedon Oct 19, 2022
Fixed. BTW, are those errors reporting a real issue which needs to be addressed or is it a false positive situation? The question is a followup on your comment in the PR. Just to figure out if we want to track this issue.
nejch commentedon Oct 19, 2022
I think it may be an issue for type checkers, not for runtime. It was already caught by mypy which probably does a better job at type checking, and we've added
if TYPE_CHECKING:guards for that reason there already.Maybe there's another way to fix that. I'd say we can keep this open to track it, but with very low priority from my perspective :)
[-]pylint check is broken[/-][+]pylint check is broken with astroid 2.12.12[/+]chore: add `not-callable` to pylint ignore list