-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
False-positive E1137 (unsupported-assignment-operation) with np.empty_like #2767
Comments
Hi @bersbersbers thanks for reporting the issue. |
Same problem as reported by @bersbersbers in #2767 occurs when using Also, use of Neither of these errors were generated by earlier versions of pylint. cc @PCManticore |
@martinholmer @bersbersbers thank for the report. In early times of To correct this, i wrote python ghosts of those I'am currently working on an improvment of Sorry for that long message but i wanted to explain why you and other |
not sure if this helps:
that could be solved by calling |
@jordyjwilliams said in issue #2767:
Thanks for the useful tip! |
@martinholmer , @jordyjwilliams |
I am also experiencing this problem. The example code: """X"""
import numpy as np
X = np.empty_like([1])
X[:] = 2 works as expected, but the almost identical code: """X"""
from numpy import empty_like
X = empty_like([1])
X[:] = 2 raises the error:
pylint --version output
|
@EmilyBourne you should open a new issue, this is going to get lost otherwise |
Steps to reproduce
pylint this file:
Current behavior
Expected behavior
No error, code runs fine in
python bug.py
pylint --version output
The text was updated successfully, but these errors were encountered: