Skip to content

Latest commit

 

History

History
87 lines (63 loc) · 2.98 KB

File metadata and controls

87 lines (63 loc) · 2.98 KB

Development Guide

This document provides guidelines and instructions for setting up and contributing to the nova-trame project.

Starting from the template

  • Add other Python dependencies you project need with pixi add.
  • Modify Dockerfile as needed. Please make sure it can still run as non-root (we use it in GitHub Actions and in general this is a good practice).
  • install pre-commit (if not already installed) - pixi add --pypi pre-commit
  • activate pre-commit for your project: cd <project folder> && pixi run pre-commit install
  • finally, clear the content of this section and add the description of your project. You can keep/adjust instructions below

Note 1: please don't change linter settings, license, code of conduct without discussing with the team first - we want to keep them the same for all our projects.

Note 2: if you think some changes that you've made might be useful for other projects as well, please fill free to create an issue in this repo

Installation

Start by installing Pixi. Once done, run the following:

pixi install

Widget Gallery

This package includes a widget gallery that shows commonly used Vuetify components for visual testing. Please use this to test your changes in this repository.

You can run it via:

pixi run app [--server]

Formatting

pixi run ruff format

Linting

pixi run ruff check
pixi run mypy .

Testing

You will need a working Firefox install available in order to run all tests. Otherwise, all Selenium-based tests will fail.

pixi run pytest

or, with coverage

pixi run coverage run
pixi run coverage report

Updating project from template

This project was created from a template using copier. If the template has changed, you can try to update the project to incorporate these changes. Just enter the project folder, make sure git status shows it clean, and run:

copier update

See here for more information.

CI/CD in GitHub

Take a look at the .github/workflows folder. Actions to lint and test your code will run automatically on each commit. The action for building and releasing this package needs to be triggered manually.

Versioning

The "source of truth" for the version number is in the pyproject.toml file. It is used for Docker image tags, python package versioning, and automatic creation of git tags.

Publishing docs to readthedocs.io

This repo has a webhook that automatically triggers documentation builds on readthedocs.