pylint icon indicating copy to clipboard operation
pylint copied to clipboard

Numba's prange causes not-an-iterable

Open louisabraham opened this issue 6 years ago • 3 comments

Steps to reproduce

for i in prange(N):
  pass

Current behavior

Non-iterable value prange(N) is used in an iterating contextpylint(not-an-iterable)

Expected behavior

no error

pylint --version output

pylint 2.3.1
astroid 2.2.5
Python 3.6.7 |Anaconda, Inc.| (default, Oct 23 2018, 14:01:38)
[GCC 4.2.1 Compatible Clang 4.0.1 (tags/RELEASE_401/final)]

louisabraham avatar May 09 '19 20:05 louisabraham

Thanks for the report!

PCManticore avatar May 14 '19 09:05 PCManticore

Has this bug been solved? I am still experiencing it on:

pylint 2.12.2
astroid 2.9.3
Python 3.9.7 (default, Mar  3 2022, 13:49:04) 
[GCC 9.3.0]

pietrodantuono avatar Mar 16 '22 10:03 pietrodantuono

It hasn't been fixed yet. This will need to be fixed by providing a brain tip in astroid. I don't know the numba package, but I would be happy to review a PR that adds one!

DanielNoord avatar Mar 16 '22 11:03 DanielNoord