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

Make teamcity-message compatibility with pylint >=2.12 #259

Merged
merged 1 commit into from
Dec 14, 2021

Conversation

Tirzono
Copy link
Contributor

@Tirzono Tirzono commented Nov 29, 2021

Currently it's not possible to update to pylint >=2.12 because teamcity-reporter fails with this version:

Traceback (most recent call last):
  File "/.venv/bin/pylint", line 8, in <module>
    sys.exit(run_pylint())
  File "/.venv/lib/python3.6/site-packages/pylint/__init__.py", line 24, in run_pylint
    PylintRun(sys.argv[1:])
  File "/.venv/lib/python3.6/site-packages/pylint/lint/run.py", line 399, in __init__
    score_value = linter.generate_reports()
  File "/.venv/lib/python3.6/site-packages/pylint/lint/pylinter.py", line 1287, in generate_reports
    score_value = self._report_evaluation()
  File "/.venv/lib/python3.6/site-packages/pylint/lint/pylinter.py", line 1329, in _report_evaluation
    self.reporter.display_reports(sect)
  File "/.venv/lib/python3.6/site-packages/teamcity/pylint_reporter.py", line 87, in display_reports
    score = self.linter.stats['global_note']
TypeError: 'LinterStats' object is not subscriptable

This change will fix that issue and makes it work for pylint >=2.12 while making sure it keeps working with older versions too.

Related to pylint-dev/pylint#5426

@Tirzono
Copy link
Contributor Author

Tirzono commented Dec 7, 2021

@mikekidya @throwable-one @madlexa would you be willing to have a look at this one? :)

@mikekidya
Copy link
Member

Thanks @Tirzono for keeping an eye at pylint support!

As I remember, you have already signed CLA, let me know if not.

@mikekidya mikekidya merged commit 3292e01 into JetBrains:master Dec 14, 2021
@Tirzono
Copy link
Contributor Author

Tirzono commented Dec 16, 2021

Hi @mikekidya,

You're correct, I did sign the CLA already during this PR:

#242

Thank you for merging the PR.

Would you mind doing a new release as well?

@mikekidya
Copy link
Member

@Tirzono yes, just released 1.30 to PyPi, please let me know if anything is not working for you

@Tirzono
Copy link
Contributor Author

Tirzono commented Dec 22, 2021

All works fine, thank you very much.

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.

2 participants