Local Dev IDE Setup
You may find it easier to work with the SDK in a modern IDE with code completion, highlighting, and other useful features. Our preferred editor at Q2 is VSCode. It does everything you would expect from a powerful IDE alongside sophisticated remote debugging support. For a best-in-class editor that allows a quick start with minimal custom setup, VSCode is the right choice.
Prefer Eclipse, Vim, etc.? No problem, but we won’t be able to provide as much assistance. We’ve provided guides for VSCode and PyCharm setup below.
Visual Studio Code
Download VSCode - https://code.visualstudio.com/download
Once VSCode is downloaded and opened, we need a few extensions for type hinting
Open the VSCode Extension marketplace (Preferences -> extensions or CTRL+SHIFT+X)
Search for the
Q2 SDK Extension Pack
and Install itSearch for
WSL
(Windows Only) and Install it
After these are installed, you can open vscode from the proper location:
from the command line using
code .
If you do not have access to this command see documentation here https://code.visualstudio.com/docs/editor/command-line.open your code directory (built using
caliper_admin
) in the IDE with File->Open.
In the root of the repo, if it has not been created yet, create a
.vscode
directory. Inside that directory:settings.json:
{ "python.defaultInterpreterPath": ".env/bin/python", "ruff.lint.args": ["--extend-select=B006"] }
launch.json:
{ "version": "0.2.0", "configurations": [ { "name": "q2 run", "type": "debugpy", "request": "launch", "program": "${workspaceRoot}/.env/bin/q2", "console": "integratedTerminal", "args": [ "run" ], } ] }
Your Visual Studio code is now setup to do development and debugging!
The video below shows the IDE setup using VSCode:
PyCharm
Simply refer to PyCharm’s own excellent documentation: