1
0

contributing.rst 1.4 KB

123456789101112131415161718192021222324252627282930313233
  1. Contributing
  2. ============
  3. If you're submitting patches to pagure, please observe the following:
  4. - Check that your python code is `PEP8-compliant
  5. <http://www.python.org/dev/peps/pep-0008/>`_. There is a `flake8 tool
  6. <http://pypi.python.org/pypi/flake8>`_ that automatically checks the sources as
  7. part of the tests.
  8. - We run the source code through `black <https://pypi.python.org/pypi/black>`_
  9. as part of the tests, so you may have to do some adjustments or run it
  10. yourself (which is simple: ``black /path/to/pagure``).
  11. - Check that your code doesn't break the test suite. The test suite can be
  12. run using ``tox`` at the top of the sources, you mayuse ``tox -e py38 ./test/``
  13. to run a single version of python. You can also run a single file by calling
  14. pytest directly: ``pytest-3 tests/test_style.py``.
  15. See :doc:`development` for more information about the test suite.
  16. - If you are adding new code, please write tests for them in ``tests/``,
  17. ``tox .`` will run the tests and show you the coverage of the code by the
  18. unit-tests.
  19. - If your change warrants a modification to the docs in ``doc/`` or any
  20. docstrings in ``pagure/`` please make that modification.
  21. .. note:: You have a doubt, you don't know how to do something, you have an
  22. idea but don't know how to implement it, you just have something bugging
  23. you?
  24. Come to see us on Matrix: ``#pagure:fedora.im`` or directly on
  25. `the project <http://pagure.io>`_.