Set Up Your Local IDE

Aim

This guide will take you through the steps to start working with a development project in your local environment. By the end you will have:

  • Cloned a project from the Quix platform to your local environment

  • Set up your environment to push and pull changes between the Quix platform and a local repo

  • Set up your IDE for code completion, debugging, and related features

Prerequisites

Make sure you’re using Python version 3.7>=, <3.9

Overview

This walkthrough covers the following steps:

  1. Create a new development project

  2. Get the project’s Git config

  3. Clone the repository

  4. Set up your IDE

Create a new development project

  1. Click the Library icon library icon in the left-hand menu. You’ll see the first Python sample displayed by default.

  2. Click the SAVE AS PROJECT button.

  3. Give it a Name — cardata — and click CREATE. You should see the project in the Quix IDE.

Get the project’s Git config

  1. From the project’s view in the Quix IDE, click the CLONE button.

  2. The Project Checkout dialog displays your project repository’s URL and Username. Press GENERATE PASSWORD to get a password for the repository.

Make sure you keep a copy of this password because you won’t be able to retrieve it later. You’ll be able to regenerate it, but you’ll then need to update any instances of it in use.
project checkout dialog

Clone the repository

Using the command line

  1. Navigate to the directory you wish to contain your repo.

  2. Enter git clone {url}.

  3. You’ll be prompted for your username for https://git.quix.ai; copy and paste it from the Quix Project Checkout dialog.

  4. You’ll be prompted for your password; copy and paste it from the same dialog.

Using an IDE

This process will vary depending on your IDE or Git client. IDEs that support Git integration should provide an option to clone a repository. For example, Visual Studio Code presents this option on the Welcome page:

vscode welcome

  1. Click clone repository…​

  2. Enter the URL displayed in the Quix Project Checkout dialog

  3. You’ll be prompted to select a Repository Location. Choose a local directory in which to create the project directory.

  4. You’ll then be prompted for your Username and Password which you can copy from the Quix Project Checkout dialog from the Get the project’s Git config step.

Credentials

Quix does not currently support SSH access to your repository. To avoid repeatedly entering your credentials, you can use a credential helper to cache or store them permanently.

Set up your IDE

If you’re using an IDE, you should ensure it is set up for your language of choice. Support will vary, but can include features such as linting, debugging, and code completion. Here’s how to set up a Python sample project in Visual Studio Code and PyCharm.

Visual Studio Code

Visual Studio should prompt you to install the Python extension when you open a sample project. If not, you can install it manually with the following steps:

  1. Click on the Extensions icon in the left-hand menu.

  2. Search for Python.

  3. Install the Microsoft Python extension:

vscode python extension
Use a Python virtual environment to ensure you’re always using the correct version of Python for Quix. See the SDK pages for how to do it here.

You should ensure Visual Studio Code is configured to use the appropriate python interpreter, particularly if you installed into a virtual environment. The active interpreter is displayed in the bottom-left corner of the window:

vscode python version

Click this to bring up the list of available interpreters and ensure the correct one is selected:

vscode python list

Once installed, you can verify the extension is working by trying IntelliSense (code completion):

vscode code completion

PyCharm

A dedicated Python IDE such as PyCharm should work with our sample projects out of the box. However, you should ensure it is configured to use the same interpreter that you used to set up the Python SDK. You can configure your interpreter via PyCharm’s Preferences. In particular, make sure that the quixstreaming package is displayed in the list of recognised packages:

pycharm quixstreaming package

You can then verify that features such as code completion are working with the SDK as expected:

pycharm code completion