Laurens Van Houtven | 5a42298 | 2014-03-15 21:42:31 +0100 | [diff] [blame] | 1 | Contributing |
| 2 | ============ |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 3 | |
Laurens Van Houtven | 36a2665 | 2014-03-15 21:52:25 +0100 | [diff] [blame] | 4 | First of all, thank you for your interest in contributing to pyOpenSSL! |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 5 | |
Laurens Van Houtven | 5a42298 | 2014-03-15 21:42:31 +0100 | [diff] [blame] | 6 | Filing bug reports |
| 7 | ------------------ |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 8 | |
Laurens Van Houtven | 36a2665 | 2014-03-15 21:52:25 +0100 | [diff] [blame] | 9 | Bug reports are very welcome. |
| 10 | Please file them on the Github issue tracker. |
| 11 | Good bug reports come with extensive descriptions of the error and how to reproduce it. |
Jean-Paul Calderone | 0679a69 | 2014-03-16 10:17:09 -0400 | [diff] [blame] | 12 | Reporters are strongly encouraged to include an `short, self contained, correct example <http://www.sscce.org/>`_. |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 13 | |
Laurens Van Houtven | 5a42298 | 2014-03-15 21:42:31 +0100 | [diff] [blame] | 14 | Patches |
| 15 | ------- |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 16 | |
Laurens Van Houtven | 36a2665 | 2014-03-15 21:52:25 +0100 | [diff] [blame] | 17 | All patches to pyOpenSSL should be submitted in the form of pull requests to the main pyOpenSSL repository, ``pyca/pyopenssl``. |
| 18 | These pull requests should satisfy the following properties: |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 19 | |
Jean-Paul Calderone | 433d4bd | 2014-03-16 10:46:16 -0400 | [diff] [blame] | 20 | - The branch referenced should be a `feature branch`_ focusing on one particular improvement to pyOpenSSL. |
Jean-Paul Calderone | 0679a69 | 2014-03-16 10:17:09 -0400 | [diff] [blame] | 21 | Create different branches and different pull requests for unrelated features or bugfixes. |
| 22 | - The branch referenced should have a distinctive name (in particular, please do not open pull requests for your ``master`` branch). |
Laurens Van Houtven | 36a2665 | 2014-03-15 21:52:25 +0100 | [diff] [blame] | 23 | - Code should follow `PEP 8`_, especially in the "do what code around you does" sense. |
Jean-Paul Calderone | 0679a69 | 2014-03-16 10:17:09 -0400 | [diff] [blame] | 24 | One notable way pyOpenSSL code differs, for example, is that there should be three empty lines between module-level elements,and two empty lines between class-level elements. |
Laurens Van Houtven | 36a2665 | 2014-03-15 21:52:25 +0100 | [diff] [blame] | 25 | Methods and functions are named in ``snake_case``. |
| 26 | Follow OpenSSL naming for callables whenever possible is preferred. |
Jean-Paul Calderone | 0679a69 | 2014-03-16 10:17:09 -0400 | [diff] [blame] | 27 | - Pull requests that introduce code must test all new behavior they introduce as well as for previously untested or poorly tested behavior that they touch. |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 28 | - Pull requests are not allowed to break existing tests. |
Laurens Van Houtven | 36a2665 | 2014-03-15 21:52:25 +0100 | [diff] [blame] | 29 | - Pull requests that introduce features or fix bugs should note those changes in the ``ChangeLog`` text file in the root of the repository. |
| 30 | They should also document the changes, both in docstrings and in the documentation in the ``doc/`` directory. |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 31 | |
Laurens Van Houtven | 36a2665 | 2014-03-15 21:52:25 +0100 | [diff] [blame] | 32 | Finally, pull requests must be reviewed before merging. |
| 33 | This process mirrors the `cryptography code review process`_. |
| 34 | Everyone can perform reviews; this is a very valuable way to contribute, and is highly encouraged. |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 35 | |
Laurens Van Houtven | 83b3e09 | 2014-03-16 15:06:24 +0100 | [diff] [blame] | 36 | Pull requests are merged by members of the `pyopenssl-committers team <https://github.com/orgs/pyca/teams/pyopenssl-committers>`_. |
| 37 | They should, of course, keep all the requirements detailed in this document as well as the pyca/cryptography merge requirements in mind. |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 38 | |
Laurens Van Houtven | 36a2665 | 2014-03-15 21:52:25 +0100 | [diff] [blame] | 39 | The final responsibility for the reviewing of merged code lies with the person merging it; since pyOpenSSL is obviously a sensitive project from a security perspective, so reviewers are strongly encouraged to take this review and merge process very seriously. |
Laurens Van Houtven | 290aba1 | 2014-03-14 15:20:18 +0100 | [diff] [blame] | 40 | |
Laurens Van Houtven | 757807e | 2014-03-15 21:49:03 +0100 | [diff] [blame] | 41 | .. _PEP 8: http://legacy.python.org/dev/peps/pep-0008/ |
Laurens Van Houtven | 5a42298 | 2014-03-15 21:42:31 +0100 | [diff] [blame] | 42 | .. _cryptography code review process: https://cryptography.io/en/latest/development/reviewing-patches/ |
Jean-Paul Calderone | 433d4bd | 2014-03-16 10:46:16 -0400 | [diff] [blame] | 43 | .. _feature branch: http://nvie.com/posts/a-successful-git-branching-model/ |