Spyder: Code analysis underlines all matches of "unused local variable"

Created on 6 Jul 2015  路  4Comments  路  Source: spyder-ide/spyder

In the code below the editor correctly underlines result since it's assigned to, but never used. It incorrectly underlines part of get_result().

wrong_underlining

Editor Ui Bug

Most helpful comment

This is not an issue anymore in our master branch. So the fix will be present in Spyder 4, to be released later in 2019.

All 4 comments

Hi @Garrett-R, thanks for reporting this, indeed a small visual bug, we need to improve(or implement?) the regex.

Cheers

I think pyflakes (the library we use to provide this functionality) is not able to tell what's the unassigned variable in lines like the one you provided.

We'll have to see if that has changed in later versions, or use a replacement for it :-)

This is still present in 3.3.4

This is not an issue anymore in our master branch. So the fix will be present in Spyder 4, to be released later in 2019.

Was this page helpful?
0 / 5 - 0 ratings