Skip to content
This repository has been archived by the owner on Aug 7, 2023. It is now read-only.

Linter produces yellow marks in editor, but error/warning popup will not show #82

Closed
DanielJoyce opened this issue Oct 9, 2015 · 16 comments
Labels

Comments

@DanielJoyce
Copy link

Sometimes I get a yellow marker in the gutter showing a warning is available, but no amount of hovering or clicking will cause the popup or tooltip to appear. There is also dashed line to show where the error is at.

@SpainTrain
Copy link
Member

Can you share your config.cson?

@brevilo
Copy link

brevilo commented Jan 13, 2016

Same here with vanilla setup (v1.2.0)...
The relevant part of config.cson just has "linter-pylint": {}

The yellow-dotted lines that also show a yellow-dashed underline do show the tooltip when clicked on, though.

@Arcanemagus
Copy link
Member

Have you disabled tooltips in Linter's configuration?

Also Linter only decorates with dashed lines, so I'm not sure what the "yellow-dotted lines" would be from. A screenshot would be helpful there.

Where is your cursor directed when you click on the "at line __ col ___" part of the message?

@brevilo
Copy link

brevilo commented Jan 22, 2016

I do get tooltips for dashed lines (see above) and all linter packages have their upstream/stock settings.

Here's a screenshot:

2016-01-22 01 37 34 pm
(this would be an unused variable warning for errno)

FYI, clicking in the line/col link takes me to the correct line.

@Arcanemagus
Copy link
Member

Is the column 0 by any chance? 😛

@brevilo
Copy link

brevilo commented Jan 22, 2016

No, it's not, but I think I found the problem:

When I place the cursor manually at the exact column that's given in the error panel the tooltip pops up. If I place the cursor anywhere else on the affected line it doesn't. However, sometimes the marked column isn't even "accessible" due to indentation so the tooltip will never show up. Anyhow, the tooltip should appear as soon as the cursor is placed anywhere on a marked line, or, better yet, by hovering with mouse over the line (anywhere) or over the gutter marker.

@DanielJoyce
Copy link
Author

This is exactly what I see. Hints that I can't get tooltips or mouseovers
for. In general at very least atom needs to support tooltips for the little
dots even if the squiggles don't show. So this may be partly an atom bug as
well.

On Fri, Jan 22, 2016 at 10:10 AM Oliver Bock [email protected]
wrote:

No, it's not, but I think I found the problem:

When I place the cursor manually at the exact column that's given in the
error panel the tooltip pops up. If I place the cursor anywhere else on the
affected line it doesn't. However, sometimes the marked column isn't even
"accessible" due to indentation so the tooltip will never show up. Anyhow,
the tooltip should appear as soon as the cursor is placed anywhere on a
marked line, or, better yet, by hovering with mouse over the line
(anywhere) or over the gutter marker.


Reply to this email directly or view it on GitHub
#82 (comment)
.

Daniel Joyce

The meek shall inherit the Earth, for the brave will be among the stars.

@Arcanemagus
Copy link
Member

So here is the odd thing: This should be generating highlight ranges that cover the line starting with the column that pylint specifies, which is a decent compromise between "all errors highlighting the entire line" and "only a single character where the linter says".

Do you have an example file you can share that shows the "dot with no line" behavior so we can look into it a bit further in detail?

In the meantime you can enable the "Line" mode in the settings for Linter, then the bottom panel will show you all messages for the currently selected line.

@brevilo
Copy link

brevilo commented Jan 26, 2016

Do you have an example file you can share that shows the "dot with no line" behavior

Sure, just cause an "Unused variable" warning (only works within functions for some reason):

def test():
    x = 1

This should also demonstrate the off-by-one problem which might even be the root cause: x is at column 5 but the error panel reports column 4 (5 is correct due to 4-space indentation). Thus you can't put the cursor manually on the spot when auto-indent is enabled.

@sneakypete81
Copy link

@Arcanemagus: any progress? I see the same issue with the simple test provided by @brevilo above.

This problem crops up quite often.

@Arcanemagus
Copy link
Member

@sneakypete81 tl;dr CoffeeScript is terrible and this mess wasn't doing whatever the original author thought it was doing.

On the good news, I've re-written this in ES6 and it seems to work fine so far 😛. I'll be putting that up in a PR shortly.

@sneakypete81
Copy link

Great to hear, thanks!

Arcanemagus added a commit that referenced this issue Jun 7, 2016
* Move the configuration to "configSchema" in package.json for newer Atom versions
* Fix #82 by fixing logic in the conditional for running rangeFromLineNumber
@Arcanemagus Arcanemagus mentioned this issue Jun 7, 2016
Arcanemagus added a commit that referenced this issue Jun 7, 2016
* Move the configuration to "configSchema" in package.json for newer Atom versions
* Fix #82 by fixing logic in the conditional for running rangeFromLineNumber
@sneakypete81
Copy link

@Arcanemagus: Really pleased that you've fixed this. It would be great to have a release pushed out with this fix.

The last release was >6 months ago. Now that your rewrite is done, I'm sure shorter release cycles would be much appreciated by your many users.

@Arcanemagus
Copy link
Member

Hmmm, not sure why I didn't push out a release before, will look into that now. Thanks for the ping on getting that out 😉.

@Arcanemagus
Copy link
Member

Arcanemagus commented Jul 5, 2016

v1.2.1 published, please file an issue if you see any problems!

@sneakypete81
Copy link

@Arcanemagus: thanks heaps, that release works beautifully.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

5 participants