DEV Community

Cover image for The Best VS Code Extensions For Python Developers In 2022.
Mahmoud Harmouch
Mahmoud Harmouch

Posted on • Updated on

The Best VS Code Extensions For Python Developers In 2022.

This is part 1 of the series where I share helpful VS code extensions, settings, shortcuts, tips, and tricks to enhance the productivity level of python developers.

Python is a powerful language used in many different applications, and it can be used for web development, data science, computer vision, DevOps, and much more. As such, it is crucial to have the right tools to make coding easier.

In this part of the series, we will explore some of the best VS Code extensions that I've compiled. I use some of them daily, the others I have recently come across. I am going to categorize these extensions into nine sections, as shown in the table of contents below.

๐Ÿ‘‰ Table Of Contents (TOC).

Programming Languages

This section includes extensions used for auto-completion, syntax checking, and more.

Python by Microsoft

๐Ÿ” Go To TOC.

Python by Microsoft

This extension allows developers to write and debug code in Python from VS Code. It also provides an interactive console for running Python code and debugging it with breakpoints, call stacks, and an integrated terminal.

For more information, you can refer to:

Marketplace

Github

Pylance

๐Ÿ” Go To TOC.

Pylance

This extension provides rich type information, helping you write better code faster.

For more information, you can refer to:

Marketplace

Github

Jupyter

๐Ÿ” Go To TOC.

Jupyter

This extension provides programmers basic notebook support for language kernels that are supported in Jupyter Notebooks.

For more information, you can refer to:

Marketplace

Github

Docker

๐Ÿ” Go To TOC.

Docker

This extension allows programmers to build, manage, and deploy containerized applications with ease.

For more information, you can refer to:

Marketplace

Github

Code Runner

๐Ÿ” Go To TOC.

Code Runner

This extension is similar to Python by Microsoft, enabling users to quickly and easily run code snippets in their code editor. It can be used for running, testing, and debugging code.

For more information, you can refer to:

Marketplace

Github

Code Snippets

This section includes extensions that provide shortcuts for code generating.

Djaneiro

๐Ÿ” Go To TOC.

Djaneiro makes it easier to develop Django projects by generating Django templates, forms, models, and functions right in your editor with the help of abbreviations.

For more information, you can refer to:

Marketplace

Github

Django

๐Ÿ” Go To TOC.

Django

This extension provides syntax highlighting and snippet code of code for django projects.

For more information, you can refer to:

Marketplace

Github

Flask Snippets

๐Ÿ” Go To TOC.

The flask-snippets extension adds code snippets support for your editor.

For more information, you can refer to:

Marketplace

Github

Kubernetes

๐Ÿ” Go To TOC.

Kubernetes

This extension helps devops engineer to build applications that run in Kubernetes clusters and troubleshooting Kubernetes applications.

For more information, you can refer to:

Marketplace

Github

Cloud Code

๐Ÿ” Go To TOC.

Cloud Code

This extension makes it dead easy to develop kubernetes clusters, debug pods, and many more.

For more information, you can refer to:

Marketplace

Github

AI Assistants

This section includes extensions that are used for code generation, auto-completion, and more.

TabNine

๐Ÿ” Go To TOC.

TabNine

TabNine is an open-source AI assistant that provides code completion suggestions based on the current context and the history of your previous commands. It also supports different languages like Python, Java, C#, Go, etc.

For more information, you can refer to:

Marketplace

Github

Github Copilot

๐Ÿ” Go To TOC.

Github Copilot

Github Copilot is an AI assistant that helps programmers to write code faster.

For more information, you can refer to:

Marketplace

Github

Kite

๐Ÿ” Go To TOC.

Kite

Like the previous extensions, Kite is an AI assistant that helps programmers to write code faster.

For more information, you can refer to:

Marketplace

Github

Version Control

This section includes extensions that make it easier to use git.

GitLens

๐Ÿ” Go To TOC.

GitLens

It is a extension that provides git insights into your code. It helps you understand what code changes are staged and what code changes are unstaged. You can also see which files have been changed but not yet staged, which files are in the index, and which files have been deleted from the index.

For more information, you can refer to:

Marketplace

Github

Linters, Formatters, Highlighters

This section includes extensions that provide additional code analysis.

Pylint

๐Ÿ” Go To TOC.

Pylint

It is an extension that helps developers to find errors in their Python files. It analyzes the source code and looks for programming errors such as syntax errors, etc. It also checks for style issues like lines too long or too short.

For more information, you can refer to:

Marketplace

Github

Python Indent

๐Ÿ” Go To TOC.

Python Indent

This extension allows python programmers to indent their code easily.

For more information, you can refer to:

Marketplace

Github

Indent rainbow

๐Ÿ” Go To TOC.

Indent rainbow

This extension is designed to make code prettier by highlighting indentation.

For more information, you can refer to:

Marketplace

Github

Trailing Spaces

๐Ÿ” Go To TOC.

Trailing Spaces

It is a lightweight extension that helps developers identify trailing spaces in their code and offers a quick-fix to remove them.

For more information, you can refer to:

Marketplace

Github

Bracket Pair Colorizer 2

๐Ÿ” Go To TOC.

Bracket Pair Colorizer 2

This extension is designed to highlight brackets that can be handy for nested containers like tuples, dictionaries, etc.

For more information, you can refer to:

Marketplace

Github

Update: This extension is deprecated in favour of the native built-in feature in VSCode.

Docstring

This section includes extensions that provide docstrings generation.

Auto Docstring

๐Ÿ” Go To TOC.

Auto Docstring

This extension helps users to generate the docstrings of your Python scripts automatically.

For more information, you can refer to:

Marketplace

Github

Markdown

This section includes extensions that can help you write and preview markdown files.

Markdown All in One

๐Ÿ” Go To TOC.

Markdown All in One

As the name implies, this extension is all you need for writing markdown files: keyboard shortcuts, table of contents, auto preview, and more.

For more information, you can refer to:

Marketplace

Github

MarkdownLint

๐Ÿ” Go To TOC.

MarkdownLint

This extension can be used for Markdown linting and style checking.

For more information, you can refer to:

Marketplace

Github

Markdown Preview Enhanced

๐Ÿ” Go To TOC.

Markdown Preview Enhanced

This extension provides automatic scroll sync, math typesetting, mermaid, PlantUML, pandoc, PDF export, code chunk, presentation writer, etc.

For more information, you can refer to:

Marketplace

Github

Markdown PDF

๐Ÿ” Go To TOC.

Markdown PDF

This extension allows you to convert Markdown files to pdf, html, png or jpeg files.

For more information, you can refer to:

Marketplace

Github

Databases

This section includes extensions that can be used as database management tools.

Sqlite

๐Ÿ” Go To TOC.

Sqlite

It is an extension used to explore and query SQLite databases.

For more information, you can refer to:

Marketplace

Github

MySQL

๐Ÿ” Go To TOC.

MySQL

A MySQL management tool.

For more information, you can refer to:

Marketplace

Github

SQLTools

๐Ÿ” Go To TOC.

SQLTools

This tool can be used as a database explorer, query runner, intellisense, and more.

For more information, you can refer to:

Marketplace

Github

Testing

This section includes extensions that can be used to write and run tests.

Python Test Explorer

๐Ÿ” Go To TOC.

Python Test Explorer

This extension allows you to run your Python Unittest, Pytest or Testplan tests with the Test Explorer UI.

For more information, you can refer to:

Marketplace

Github

Code Coverage

๐Ÿ” Go To TOC.

Code Coverage

It helps developers measure the code coverage of their code: How much of the code has been tested. It will highlight lines of code that are not covered by tests.

For more information, you can refer to:

Marketplace

Github

Wrapping Up

๐Ÿ” Go To TOC.

This constitutes our VS code extensions list used by python developers(e.g., data scientists, DevOps Engineers, Backend Developers, etc.). These VS Code extensions can be helpful to developers in their day-to-day work with Python projects.

As always, this article is a gift to you, and you can share it with whomever you like or use it in any way that would be beneficial to your personal and professional development. By supporting this blog, you keep me motivated to publish high-quality content related to python. Thank you in advance for your ultimate support!

Future Work

๐Ÿ” Go To TOC.

Now we have a handful list of VS code extensions that can make our life so much easier; I will be sharing my VS code settings, including the theme I use, icons, shortcuts, and many more. So stay tuned for future posts.

Happy coding, folks; see you in the next one.

Top comments (12)

Collapse
 
khuongduybui profile image
Duy K. Bui

Regarding AI Assistants, Microsoft is rolling their own experiment too: marketplace.visualstudio.com/items...
I tried it for a while but so far I'm liking GitHub CoPilot more.

Collapse
 
wiseai profile image
Mahmoud Harmouch

Hmmm... That sounds a bit strange to me! As far as I know, Microsoft bought Github a while ago, implying that Microsoft owns CoPilot; It should be rebranded to something like: Microsoft CoPilot.

Anyway, RIP our privacy, the so-called "metadata".

Collapse
 
khuongduybui profile image
Duy K. Bui

Tech-wise, GitHub has been maintaining their own autonomy. There have been a few GitHub - Microsoft integration / merging such as GitHub Workspaces / vscode.dev, but GitHub CoPilot and MS AI Assistants are completely separate projects.

Collapse
 
leatex profile image
Lea M

Good post!
I think you don't need "Bracket Pair Colorizer 2" because it is a built-in feature in VS Code.
Just go to Settings -> Editor -> Bracket Pair Colorization
Or search for "bracket pair" to see all options.

Collapse
 
wiseai profile image
Mahmoud Harmouch

I have just figured that out. Good to know. Thanks for the heads up!

Collapse
 
uadson profile image
Uadson Feitosa

Really an excellent post. Thank you so much for this.

Collapse
 
wiseai profile image
Mahmoud Harmouch

Glad you dug it! That made my day. Thank you!

Collapse
 
uadson profile image
Uadson Feitosa

You're welcome bro.

Collapse
 
khuongduybui profile image
Duy K. Bui

As for Linting / Formatting, trunk.io/ is my latest treasure and it has a VSCode integration extension too.

Collapse
 
wiseai profile image
Mahmoud Harmouch

That looks awesome! Thanks for suggesting this tool.

Collapse
 
martinlee profile image
ๆ€็ปดไธ‡ๅˆ›

thank you for recommend this.

Collapse
 
wiseai profile image
Mahmoud Harmouch

Iโ€™m happy to help!