srusskih / SublimeJEDI

awesome Python autocompletion with SublimeText
MIT License
938 stars 109 forks source link

Do not autosuggest packages with dashes in names #310

Open playpauseandstop opened 4 years ago

playpauseandstop commented 4 years ago

First of all, this is awesome plugin! Thanks a lot for making it!

I'm using it everyday and in total highly happy with it results. However recently I found out one small issue and would like to consult, whether it should be fixed or not.

The issue is about package names with dashes and suggesting them for imports usage which makes no sense. Let's take a look on screenshot below,

Screen Shot 2020-02-20 at 14 48 53

It suggests to import from aiohttp-middlewares, but it will result in syntax error.

The source for suggestion is valid (from my pov), as aiohttp-middlewares named exactly as aiohttp-middlewares, but I believe SublimeJEDI should exclude that suggestions as they don't make much sense.

If this makes sense for you as well, I'll be glad to provide fix for given issue!

playpauseandstop commented 4 years ago

BTW,

IPython, which also used JEDI for autosuggestion, do not suggest aiohttp-middlewares as seen at screenshot below,

Screen Shot 2020-02-20 at 21 30 09
srusskih commented 4 years ago

@playpauseandstop thanks for report.

umairansar commented 3 years ago

Could you please provide code reference which gathers entries for the autosuggestions list?