Skip to content

Latest commit

 

History

History
69 lines (44 loc) · 2.21 KB

CONTRIBUTING.md

File metadata and controls

69 lines (44 loc) · 2.21 KB

Contributing to FuseMedML

👍🎉 First off, thanks for taking the time to contribute! 🎉👍

How do I report a bug or suggest an enhancement?

  • As a first step, please search in the existing issues to check if your point has already been addressed.
  • If that is not the case, go ahead and create an issue of the respective type, providing the details as instructed in the template.

How do I submit a change?

We welcome contributions via pull requests:

  • Fork (or clone) the repo and create your branch from the default branch
  • If you have added code that should be tested - add tests
  • If any documentation updates are needed - make them
  • Ensure the test suite passes and the code lints
  • Submit the pull request

Once you have submitted your PR:

  • Note that a PR is considered for review only if Jenkins builds successfully
  • Upon approval, PR is to be merged using the "squash and merge" option, so that the commit history remains linear and readable

Styleguides

We use black, flake8 and mypy external tools to analyse and enforce uniform python code style.

Note - if you installed fuse using the recommended way

$ pip install -e .[all]

you should have the libraries already installed, however, if you want to manually install those libs see requirements_dev.txt

Formatter black

When writing code, you should not have to worry about how to format it best. When committing code to a pull request, it should be formatted in one specific way that reduces meaningless diff changes. Here we use black. You can set up your IDE to format your code on save.

to check for changes:

black <path> --check --diff --color

to apply changes:

black <path>

Linter flake8

Checks code style and detects various issues not covered by black.

usage:

flake8 <path>

Static typing with mypy

Enforces the usage of type annotations for functions input arguments and return values only, but not the correctness of them.

usage:

mypy <path>