Ask Your Question
0

Let wing automatically disable the auto-completion suggestions for the already imported names on the same line.

asked 2020-04-15 03:57:32 -0500

hongyi-zhao gravatar image

updated 2020-04-15 10:06:43 -0500

Hi,

Say for the following code line:

from aiida.orm import Code

If I continue to do the importing on the same line as following:

from aiida.orm import Code, C<tab>

Then the wing will still show the Code as one of the candidates for completion. But it's obviously that there is no need to let wing give the auto-completion suggestions for the already imported ones on that line.

Regards

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-04-15 10:06:51 -0500

I've added this as a feature request.

edit flag offensive delete link more

Comments

Generally speaking, this should be implemented in the whole range of the script we are working on.

hongyi-zhao gravatar imagehongyi-zhao ( 2020-04-15 10:19:37 -0500 )edit

I'm not seeing a general case here. In most cases if you defined something already you may want to overwrite it, or call it, or access an attribute on it.

Wingware Support gravatar imageWingware Support ( 2020-04-15 10:23:40 -0500 )edit

I mean importing on the exactly same stuff is no need to do more then once for one script, am I wrong?

Regards

hongyi-zhao gravatar imagehongyi-zhao ( 2020-04-15 10:42:45 -0500 )edit

Right, it's almost certainly not useful in imports although note that something like "from pkg import Test, Test as test" _is_ valid Python. I just don't think it's likely anyone will want to type that.

Wingware Support gravatar imageWingware Support ( 2020-04-15 10:57:30 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2020-04-15 03:57:32 -0500

Seen: 21 times

Last updated: Apr 15