Book about the VS Code IDE, catered to Python programmers. It mostly covers basic operations with detailed step-by-step instructions and screenshots. However, I found the depth somewhat lacking. Most of the functions seem like things any seasoned IDE user would know. The book doesn’t go deeply into any particular feature, like launch configurations or the IDE’s remote architecture, which can be confusing. The later chapters also seem a bit off-topic, discussing Github operations that could be done just as easily on a website, and covering aspects of Django, Flask, and Azure that only tangentially relate to VSCode.
Chapter 1. Basic components of the VS Code interface, including the activity bar, sidebar, how to split tabs, trigger commands, install extensions, and configure settings.
Chapter 2. To use VS Code for Python, you need to install the Python extension. By default, it uses the Python version on your path, but you can select a different interpreter, like a virtual or conda environment, within the extension.
Chapter 3. The Quick Fix can handle simple corrections, like imports, and recognizes common abbreviations, like np for numpy. It has auto-complete, and when you hover over items, it shows types and documentation. Auto-formatting is versatile with settings for Autopep8 and Black. Linting checks for more than just formatting, such as type checking, and there are some refactoring tools available, like extracting variables or methods and sorting imports.
Chapter 4. Shows how to navigate through project files, search within files, and configure the Python interpreter for conda or virtual environments. VS Code can also integrate with Git, like making commits using the UI . Additionally, there’s a live share feature, enabling multiple users to collaborate remotely within the IDE.
Chapter 5: To start a debugging session, set a breakpoint; you can also deactivate breakpoints without deleting them. There are commands to step in, through, and out of the code, and to inspect the call stack. Conditional breakpoints can be set to trigger based on the number of hits or if a variable reaches a certain value. Logpoints help avoid cluttering your code with print statements; instead, they print directly. You can also watch a variable to either highlight it or set a breakpoint when its value changes. The debug mode also has a REPL to execute Python during debugging. To edit launch configurations, use launch.json, and you can launch a new one or attach it to an existing process ID.
Chapter 6: Enable settings to recognize tests, and then VSCode can discover them. Additionally, you can run the debugger on a single test.
Chapter 7: This chapter discusses how to run Jupyter notebooks in VS Code. By default, they’re untrusted, so you need to grant permission. You can change cell modes, add cells, and even connect to a notebook running remotely using a remote URL.
Chapter 8: Integrating with GitHub for operations like pushing PRs and handling issues.
Chapters 9-12: These chapters guide you through setting up and deploying both a Django and a Flask app, and then deploying them to Azure App Service directly from VSCode. By configuring launch.json, you can launch the Flask app and set breakpoints within it. The Docker extension allows you to build images and containers, set breakpoints in code running in those containers, and push to the Azure container registry.