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

Problem with flake8 v6.0.0 #19

Closed
riedgar-ms opened this issue Nov 24, 2022 · 0 comments · Fixed by #20
Closed

Problem with flake8 v6.0.0 #19

riedgar-ms opened this issue Nov 24, 2022 · 0 comments · Fixed by #20

Comments

@riedgar-ms
Copy link

It appears that the latest flake8 is causing trouble with the flake8-copyright plugin. When we run flake8 we get a stacktrace along these lines:

(fairlearn-39) PS C:\Users\ME\source\repos\fairlearn> flake8 .
Traceback (most recent call last):
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\runpy.py", line 197, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\Scripts\flake8.exe\__main__.py", line 7, in <module>
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8\main\cli.py", line 23, in main
    app.run(argv)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8\main\application.py", line 198, in run
    self._run(argv)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8\main\application.py", line 186, in _run
    self.initialize(argv)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8\main\application.py", line 165, in initialize
    self.plugins, self.options = parse_args(argv)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8\options\parse_args.py", line 51, in parse_args
    option_manager.register_plugins(plugins)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8\options\manager.py", line 259, in register_plugins
    add_options(self)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8_copyright.py", line 56, in add_options
    register_opt(
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8_copyright.py", line 30, in register_opt
    parser.add_option(*args, **kwargs)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\site-packages\flake8\options\manager.py", line 281, in add_option
    self._current_group.add_argument(*option_args, **option_kwargs)
  File "C:\Users\ME\Miniconda3\envs\fairlearn-39\lib\argparse.py", line 1427, in add_argument
    raise ValueError('%r is not callable' % (type_func,))
ValueError: 'int' is not callable

This issue suggests it's a problem with the plugin:
PyCQA/flake8#1760

Jasha10 added a commit to facebookresearch/hydra that referenced this issue Nov 26, 2022
pinned due to issue savoirfairelinux/flake8-copyright#19
which affects the flake8-copyright flake8 plugin that we are using.
Jasha10 added a commit to Jasha10/hydra that referenced this issue Nov 26, 2022
pinned due to issue savoirfairelinux/flake8-copyright#19
which affects the flake8-copyright flake8 plugin that we are using.
Jasha10 added a commit to Jasha10/hydra that referenced this issue Nov 26, 2022
pinned due to issue savoirfairelinux/flake8-copyright#19
which affects the flake8-copyright flake8 plugin that we are using.
Jasha10 added a commit to Jasha10/hydra that referenced this issue Nov 26, 2022
pinned due to issue savoirfairelinux/flake8-copyright#19
which affects the flake8-copyright flake8 plugin that we are using.
Jasha10 added a commit to Jasha10/hydra that referenced this issue Nov 26, 2022
pinned due to issue savoirfairelinux/flake8-copyright#19
which affects the flake8-copyright flake8 plugin that we are using.
Jasha10 added a commit to facebookresearch/hydra that referenced this issue Nov 27, 2022
pinned due to issue savoirfairelinux/flake8-copyright#19
which affects the flake8-copyright flake8 plugin that we are using.
The-Compiler added a commit to qutebrowser/qutebrowser that referenced this issue Nov 28, 2022
taurus-forever added a commit to canonical/mysql-router-k8s-operator that referenced this issue Dec 5, 2022
rjarry added a commit to CESNET/libyang-python that referenced this issue Dec 5, 2022
Since flake8 6.0, the copyright plugin fails to run:

  ValueError: 'int' is not callable

This plugin is not critical, remove it.

Also use latest versions of black and pylint along the way.

Link: savoirfairelinux/flake8-copyright#19
Signed-off-by: Robin Jarry <robin@jarry.cc>
taurus-forever added a commit to canonical/mysql-operator that referenced this issue Dec 5, 2022
taurus-forever added a commit to canonical/mysql-bundle that referenced this issue Dec 5, 2022
rjarry added a commit to sysrepo/sysrepo-python that referenced this issue Dec 5, 2022
Since flake8 6.0, the copyright plugin fails to run:

  ValueError: 'int' is not callable

This plugin is not critical, remove it.

Also use latest versions of black and pylint along the way.

Link: savoirfairelinux/flake8-copyright#19
Signed-off-by: Robin Jarry <robin@jarry.cc>
taurus-forever added a commit to taurus-forever/template-operator that referenced this issue Dec 6, 2022
taurus-forever added a commit to canonical/mysql-router-k8s-operator that referenced this issue Dec 6, 2022
carlcsaposs-canonical pushed a commit to canonical/mysql-operator that referenced this issue Dec 6, 2022
Lothiraldan added a commit to comet-ml/comet-for-mlflow that referenced this issue Dec 8, 2022
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 a pull request may close this issue.

1 participant