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

pylint raises no-value-for-the-parameter rule with dask.delayed used as decorator with keyword arguments #10761

Open
KsawerySmoczynski opened this issue Jan 9, 2024 · 0 comments
Labels
needs triage Needs a response from a contributor

Comments

@KsawerySmoczynski
Copy link

KsawerySmoczynski commented Jan 9, 2024

Describe the issue:

Hey, I stumbled upon this issue that pylint incorrectly raises for the rule E1120: No value for argument 'obj' in function call (no-value-for-parameter) when using dask.delayed as a decorator with some keyword arguments.

Minimal Complete Verifiable Example:

requirements.txt

astroid==3.0.2
click==8.1.7
cloudpickle==3.0.0
dask==2023.5.0
dill==0.3.7
fsspec==2023.12.2
importlib-metadata==7.0.1
isort==5.13.2
locket==1.0.0
mccabe==0.7.0
packaging==23.2
partd==1.4.1
platformdirs==4.1.0
pylint==3.0.3
PyYAML==6.0.1
tomli==2.0.1
tomlkit==0.12.3
toolz==0.12.0
typing_extensions==4.9.0
zipp==3.17.0

main.py

import dask

@dask.delayed(pure=False)
def some_fn(a: dict):
    a["b"] = "c"
    return a

some_dict = {}
task = some_fn(some_dict)
result = dask.compute(task)

print(result[0])

Pylint on main:

pylint main.py
************* Module main
main.py:1:0: C0114: Missing module docstring (missing-module-docstring)
main.py:4:0: C0116: Missing function or method docstring (missing-function-docstring)
main.py:3:1: E1120: No value for argument 'obj' in function call (no-value-for-parameter)

------------------------------------------------------------------
Your code has been rated at 1.25/10 (previous run: 1.25/10, +0.00)

Environment:

  • Dask version: 2023.5.0
  • Python version: 3.8.18
  • Operating System: ubuntu 22.04
  • Install method (conda, pip, source): pip
@github-actions github-actions bot added the needs triage Needs a response from a contributor label Jan 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs triage Needs a response from a contributor
Projects
None yet
Development

No branches or pull requests

1 participant