Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
J
jetconf-resolver
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 0
    • Merge Requests 0
  • Operations
    • Operations
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
  • jetconf
  • jetconf-resolver
  • Wiki
  • devinstall

Last edited by Ladislav Lhotka May 30, 2018
Page history

devinstall

Installation of the Development Environment

It is highly recommended to set up a virtual environment for the backend development. The following procedure uses the venv module for this purpose (it is included in the standard Python library since version 3.3).

  1. Install the latest stable Python 3 version, if it is not already on your system.

  2. Clone the Yangson project in a directory of your choice:

    $ git clone git@gitlab.labs.nic.cz:jetconf/jetconf-resolver.git
  3. Create the virtual environment:

    $ python3 -m venv jetconf-resolver
  4. Activate the virtual environment:

    $ cd jetconf-resolver
    $ source bin/activate
  5. Install required standard packages inside the virtual environment:

    $ pip install -r requirements.txt

    If you are prompted to upgrade pip, you can do that, too.

When inside the virtual environment, the shell prompt should change to something like

(jetconf-resolver) $

To leave the virtual environment, just do

$ deactivate

The virtual environment can be entered anytime later by executing step 4. The steps preceding it need to be performed just once.

The setup described above has a few consequences that have to be kept in mind:

  • Any project files that need to go to bin (executable Python scripts), include or lib have to be added as exceptions to .gitignore, for example
!bin/foo
  • After adding a new Python module dependency, it is necessary to run
    $ make deps
    and commit the new content of requirements.txt.

As an additional test suite, all doctest snippets that are embedded in documentation can be executed:

$ cd docs
$ make doctest

Documentation can be built locally by running

$ make html

in the docs subdirectory.

Clone repository
  • backend
  • devinstall
  • Home