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

Not detecting variable from previous notebook cells #348

Closed
sh-shahrokhi opened this issue Nov 27, 2023 · 1 comment
Closed

Not detecting variable from previous notebook cells #348

sh-shahrokhi opened this issue Nov 27, 2023 · 1 comment

Comments

@sh-shahrokhi
Copy link

Hi, I'm using ruf-vscode 2023.50.0, ruff 0.1.6, vscode 1.84.2 on Windows 11.
In juoyter notebooks, ruff can't see variables from previous cells.

image

Ruff extension is set as default python formatter/linter.

Simple code for replication:

colors = ['red', 'orange', 'green', 'blue', 'purple']

in another cell:

colors2 = colors + ['black']

Thanks

@dhruvmanila
Copy link
Member

Hey, thanks for opening this issue. This is happening because colors is possibly a magic command. For more context, refer astral-sh/ruff#8526. I'll close this one in favor of the linked issue.

@dhruvmanila dhruvmanila closed this as not planned Won't fix, can't repro, duplicate, stale Nov 27, 2023
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

No branches or pull requests

2 participants