Skip to content

Contributing

Martin Uhrin edited this page Jul 7, 2020 · 3 revisions

Contributing

Want a new feature? Found a bug? Want to contribute more documentation or a translation perhaps?

KiwiPy is fully open-source and we welcome contributions with open arms.

Here's a short guide on how to contribute.

1. Getting started

  1. Fork the kiwiPy repository
  2. git clone your fork to your local machine
  3. Install kiwiPy with development libraries: pip install -e .[rmq,pre-commit,tests]
  4. Create a new branch for your contribution:
git checkout develop
git checkout -b my-contribution

Where my-contribution can anything meaningful for your contribution.

2. Testing your changes

Any code additions/changes should be tested. We use use Python's unittest and pytest as part of our testing suite. Find a home for your tests(s) in the test/ folder and then verify that it's all OK by running this from your repository root:

pytest test

3. Pre-commit hooks

The pre-commit hooks will check that your code conforms to the style that we use (almost entirely Google's python style) and perform some other basic checks on your code. To set them up, use:

pre-commit install

This will cause the hooks to be executed at every commit on new files. You can also trigger a manual run using:

pre-commit run --all

4. Create a merge request

Once you're happy with your changed, feel free to directly make a PR into the main. See github's guide on how to do this or just create an issue describing what you'd like to merge and we can help you out.

Clone this wiki locally