[Tutor] What editor tools (plugins/extensions) would you consider essential for efficient Python development?

DL Neil PyTutor at danceswithmice.info
Mon Nov 11 21:16:39 EST 2019


Sorry @boB, I guess it comes down to 'spare time'. Also, it's a 
conversation that often leads to time-sinking 'religious wars'.


On 12/11/19 1:53 PM, boB Stepp wrote:
> I thought I would follow up on my questions in case anyone is waiting
> with bated breath ~(:>))  The intent of my original post was primarily
> query about programming tools that it would be good for me to
> implement regardless of my specific editor and then to narrow it down
> to the best specific plugins for my actual editor.  Judging from the
> lack of responses... <shrug>  Anyway here is what my best efforts came
> up with...

Whilst I appreciate the point that vi[m] 'comes standard', it was 
presented as anything but standard - some systems opened in cmd mode, 
others with Insert on, ...

It has been pointed-out to me (when I last trotted-out exactly that 
line) that most of the more popular Linux distributions (at least - and 
thus all of their 'derivatives') come with nano. (I'll say no more - see 
also 'religious wars')

For reference:
1 I'd never choose to use MS-VScode, simply because of the first two 
letters,
2 I was persuaded to try VScodium, which was somewhat fun, but fairly 
soon afterwards a pip and/or pytest upgrade turned the effort into a 
(circular) farce; so
3 for the last years I've been using SublimeText (also with useful 
plug-ins), mainly to suit others in a particular dev.team, but also 
because folk in another team didn't like me doing web.dev from PyCharm. 
Go figure!


> On Fri, Nov 8, 2019 at 9:54 PM boB Stepp <robertvstepp at gmail.com> wrote:
>> What Neovim plugins would any of you recommend as especially useful?
>> Searching online I have found a variety of opinions, but as to
>> functionality I have seen suggested:
>>      1)  Git integration plugins.
>>      2)  Code completion plugins.
>>      3)  Linters.
>>      4)  File explorer plugins.
>>      5)  Bracket and quote completion plugins.
>>      6)  Comments plugins.
>>      7)  Code autoformatting plugins.
>>      8)  PEP 8 compatibility plugins.
>>      9)  Multiple cursor plugins.
>>    10)  Code folding plugins.
>>    11)  "Fuzzy" searching plugins.
>>    12)  And on and on and ...
> 
> After research I feel that the following plugin functionalities would
> improve my code quality and coding efficiency:  1)  syntax highlighting;
+1

2) Code completion;
+1

  3) Code linting, especially checking for PEP 8 and 257 compatibility;
+1 (although "here be dragons", so being able to selectively turn-off 
specific checks is on the path of harmony and peaceful co-existence)

  4) Code autoformatting;
? doesn't the (Python) editor do this

5) Implementing type annotation and its checking
+1 although I see mypy as operating at the same time as/effectively a 
single unit with pytest (which I saw a 'missing' from your previous 
list; despite my using just such a plug-in 'all the time')


Referring to your original list:
 >>      1)  Git integration plugins.
- this is handy, but it wouldn't worry me if it was a separate application
- likely depends upon the operation's definition of CI

 >>      4)  File explorer plugins.
? to do what

 >>      5)  Bracket and quote completion plugins.
+1 but surely part of the editor

 >>      6)  Comments plugins.
? which do what

 >>      9)  Multiple cursor plugins.
+1 I find this very handy, from time-to-time (it's built-in to ST's editor)

 >>    10)  Code folding plugins.
+1 again: editor/built-in

 >>    11)  "Fuzzy" searching plugins.
? which do what


Something which I'd like is a view/map of my entire (Python) 
application's entities showing how the pieces of the 'jig-saw' fit 
together, as well as a 'click on the link' facility to 'jump there'. 
Perhaps it already exists but outside of my vocabulary...

I don't have one right now, but have seen editors/IDEs with a similar 
structure of elements within a single/the current file. Not so 
interesting, but then perhaps that's because I don't like to have too 
much* in a single file - and perhaps end-up with too many* file-imports.

* make of that what you will!


> As to specific plugins for my chosen editor, Neovim:
...

> will become too busy looking.

Thus, the use for a 'distraction free' or 'edit only' mode - you can 
sing-along to this song: "built into the editor"!


> Hopefully all of this will be helpful and not harmful.  However, I
> notice that one of my source files that I copied and ran Black on made
> one of the linters unhappy for about four lines where it did not like
> the level of indentation chosen for a dictionary definition with some
> long entries.  Also, is it considered bad style to define constants
> (using all caps) locally in a function definition?  Did not like that
> one either.

...and what was I saying about the futility of acting (only) to make 
others happy? See also, selectively 'turning off' features.


I have failed to re-locate an article which talked about Python and 
"IDEs" (as opposed to more humble, "editors"). The claim was that Python 
didn't need half of the "cruft" that other languages demand of their 
editors because (a) it is interpreted/evidence not available until 
run-time, and (b) it's a better language(?) - which I think is true - 
but won't be driving me back to Notepad as a dev.tool, any time soon!

Your other comment is worthy of consideration: all these things take 
time to learn and then commit to muscle-memory/to become habits. 
Meantime, your Python dev work is slowed/brain-power is being absorbed 
off-task.

I have colleagues who trade editors, sorry, maybe that should be IDEs, 
about as often as they change their under-wear. That comment about it 
taking time to come-up-to-speed seems to convince them that I am mad 
(quite possible - you don't have to be to work here - but it helps!). At 
least I can type faster than they, suffer less from FoMo, and am 
waaaaaay better-looking)

Selecting good tools - and the right tool for the job, is a necessary 
component of efficiency. So, I'm convinced of the importance of a good 
editor - and that may vary by language or other choices. However, what's 
right for you, might not be for me - and vice-versa. It's "horses for 
courses" - not that I'm comparing your looks to a horse (front-end or 
back...)
-- 
Regards =dn


More information about the Tutor mailing list