Skip to content

How to contribute

We are really glad you're reading this, because we need volunteer developers to help this project SpectraFit.

Here are some important resources:

  • Issues for open BUG reports or feature requests
  • Pull requests for contributing code
  • Millestones, which are listed below.

Setup the development environment

SpectraFit is using poetry as python package management system and pre-commit for managing git hooks. For fixing bugs or developing new featuers, we recommend to use both tools. The python version should be 3.7.1 or higher and can be optional managed via pyenv.

Bash
pyenv local 3.8.11
poetry install
pre-commit install --install-hooks

Even if we have not git hook for code style markdown, json, and yaml files, we prefer the prettier style and its extension for toml files.

Milestones

Milestones now also available for the spectrafit application. Furthermore, project status can be seen in the GitHub Project Panel.

Testing

We are using only GitHub-Actions for pre-commit testing, the CI/CD pipeline and the release.

Submitting changes

Please send a GitHub Pull Request to SpectraFit with a clear list of what you've done (read more about pull requests). We can always use more test coverage. Please follow our coding conventions (below) and make sure all of your commits are atomic (one feature per commit).

Always write a clear log message for your commits. One-line messages are fine for small changes, but bigger changes should look like this:

Bash
git commit -m "A brief summary of the commit"

A paragraph describing what changed and its impact.

In terms of connecting issues with the corresponding PR, we prefer to use the the GitHub convention of using the issue number in the commit message. This also allows us to easily linking PRs with issues in our Project Board.

Coding conventions

Start reading our code and you'll get the hang of it. We optimize for readability:

  • We use as formaters for Python:
  • Code style: black
  • Imports: isort
  • Code style: flake8
  • Google convention for docstrings
  • We use as formater for Markdown, JSON and YAML files:
  • code style: prettier

Note

This template is adapted from opengovernment.