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

[BUG] prospector failed if --max-line-length option was passed #696

Closed
kostiantyn-lab opened this issue Oct 31, 2024 · 0 comments · Fixed by #697
Closed

[BUG] prospector failed if --max-line-length option was passed #696

kostiantyn-lab opened this issue Oct 31, 2024 · 0 comments · Fixed by #697
Labels
Milestone

Comments

@kostiantyn-lab
Copy link

Describe the bug A clear and concise description of what the bug is.

prospector failed if --max-line-length option was passed

To Reproduce Steps to reproduce the behavior:

  1. Go to project root
  2. Call prospector the following way: prospector --max-line-length 99
  3. See error: AttributeError: 'FormatChecker' object has no attribute 'set_option'

Expected behavior A clear and concise description of what you expected to happen.

No error is reported

Screenshots If applicable, add screenshots to help explain your problem.

Traceback (most recent call last):
  File "/usr/local/bin/prospector", line 8, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.10/site-packages/prospector/run.py", line 198, in main
    prospector.execute()
  File "/usr/local/lib/python3.10/site-packages/prospector/run.py", line 73, in execute
    for tool in self.config.get_tools(found_files):
  File "/usr/local/lib/python3.10/site-packages/prospector/config/__init__.py", line 68, in get_tools
    config_result = tool.configure(self, found_files)
  File "/usr/local/lib/python3.10/site-packages/prospector/tools/pylint/__init__.py", line 114, in configure
    config_messages, configured_by = self._get_pylint_configuration(
  File "/usr/local/lib/python3.10/site-packages/prospector/tools/pylint/__init__.py", line 173, in _get_pylint_configuration
    config_messages = self._prospector_configure(prospector_config, linter)
  File "/usr/local/lib/python3.10/site-packages/prospector/tools/pylint/__init__.py", line 87, in _prospector_configure
    checker.set_option("max-line-length", max_line_length)
AttributeError: 'FormatChecker' object has no attribute 'set_option'

Environment (please complete the following information):

  • OS: Debian 12, Windows
  • Prospector version 1.12.0
  • Python version 3.10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants