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

Stay on pylint 2.x.x for tests #2912

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

klevvit
Copy link

@klevvit klevvit commented Oct 24, 2023

ISSUE TYPE

  • Bug fix

RUNTIME ENVIRONMENT

  • Operating system and version: macOS Ventura 13.6 (22G120)
  • Terminal emulator and version: xterm-kitty, kitty 0.30.1
  • Python version: 3.8.17 [Clang 15.0.0 (clang-1500.0.40.1)], freshly installed
  • Ranger version/commit: ranger-master
  • Locale: en_US.UTF-8

CHECKLIST

  • The CONTRIBUTING document has been read [REQUIRED]
  • All changes follow the code style [REQUIRED]
  • All new and existing tests pass [REQUIRED]
  • Changes require config files to be updated
    • Config files have been updated
  • Changes require documentation to be updated
    • Documentation has been updated
  • Changes require tests to be updated
    • Tests have been updated

DESCRIPTION

Set pylint version for automatic tests as 2.17.7, the last 2.x.x version.

MOTIVATION AND CONTEXT

pylint 3.x.x brings significant changes, so tests for new PRs may fail or even crash on current code. One of the cases is what happened in #2911 with pylint 3.0.1:

File "ranger/tests/pylint/python3.py", line 184, in Python3Checker
    __implements__ = interfaces.IAstroidChecker
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'pylint.interfaces' has no attribute 'IAstroidChecker'
make: *** [test_pylint] Error 1

TESTING

My actions to check if the changes work fine:

  1. install & build python 3.8.17
  2. create file ~/tmp/reqs.txt with updated requirements.txt content
  3. run pip install -r ~/tmp/reqs.txt
  4. run make test

All tests have passed successfully.

IMAGES / VIDEOS

pylint 3.x.x brings significant changes, so current PRs may fail or even break on tests.
One of the cases that happened in ranger#2911 with pylint 3.0.1:
```
File "ranger/tests/pylint/python3.py", line 184, in Python3Checker
    __implements__ = interfaces.IAstroidChecker
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'pylint.interfaces' has no attribute 'IAstroidChecker'
make: *** [test_pylint] Error 1
```
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.

None yet

1 participant