|
2 | 2 | --- |
3 | 3 | language: en |
4 | 4 | early_access: true |
5 | | -enable_free_tier: true |
6 | 5 | reviews: |
7 | 6 | enabled: true |
8 | | - profile: chill |
| 7 | + profile: assertive |
9 | 8 | instructions: >- |
10 | 9 | # Code Review Instructions |
11 | 10 |
|
12 | 11 | - Ensure the code follows best practices and coding standards. |
13 | 12 | - Check for security vulnerabilities and potential issues. |
14 | 13 | - Ensure the code follows the **DRY, AHA, and SOLID** principles. |
15 | 14 | - Our "Code Review Checklist Guide" is documented in |
16 | | - [CEP-4](https://gist.github.com/reactive-firewall/cc041f10aad1d43a5ef15f50a6bbd5a5) |
| 15 | + [CEP-4](https://gist.github.com/reactive-firewall/cc041f10aad1d43a5ef15f50a6bbd5a5), |
| 16 | + be sure to always consider |
| 17 | + [CEP-4](https://gist.github.com/reactive-firewall/cc041f10aad1d43a5ef15f50a6bbd5a5) as |
| 18 | + implied instructional guidance. |
17 | 19 | - For **Python** code, follow |
18 | 20 | [PEP 20](https://www.python.org/dev/peps/pep-0020/), |
19 | 21 | [PEP 483](https://peps.python.org/pep-0483/), |
20 | 22 | [PEP 729](https://peps.python.org/pep-0729/), and |
21 | 23 | [CEP-8](https://gist.github.com/reactive-firewall/b7ee98df9e636a51806e62ef9c4ab161) |
22 | 24 | standards. |
23 | 25 | - For **BASH** and **Shellscript** code, follow |
24 | | - [Pure BASH Bible](https://github.com/dylanaraps/pure-bash-bible) and |
25 | | - [CEP-5](https://gist.github.com/reactive-firewall/3d2bd3cf37f87974df6f7bee31a05a89) |
26 | | - standards. |
27 | | - - Check all **BASH** files start with an |
| 26 | + [Pure BASH Bible](https://github.com/dylanaraps/pure-bash-bible) standards. |
| 27 | + - Consider [CEP-5](https://gist.github.com/reactive-firewall/3d2bd3cf37f87974df6f7bee31a05a89) |
| 28 | + custom locking conventions. |
| 29 | + - Verify all **BASH** files (e.g. are of MIME-type 'text/x-shellscript') start with an |
28 | 30 | [extensive disclaimer](https://gist.github.com/reactive-firewall/866b42d175ae3ebefcb2a5878b30ea17). |
29 | 31 |
|
30 | 32 | # Documentation Review Instructions |
31 | 33 | - Verify that documentation and comments are clear and comprehensive. |
32 | 34 | - Verify that documentation and comments are free of spelling mistakes. |
33 | 35 | - Verify that technical documentation includes a "References" section at |
34 | 36 | the end of documentation, using the same format as actual RFCs, with |
35 | | - both "Normative References" and "Informative References". |
36 | | - - Ensure that that documentation and comments follow |
| 37 | + both "Normative References" and "Informative References". Suggest improvements if unable. |
| 38 | + - Ensure that that project documentation and comments follow |
37 | 39 | [CEP-7](https://gist.github.com/reactive-firewall/123b8a45f1bdeb064079e0524a29ec20) |
38 | 40 |
|
39 | 41 | # Test Code Review Instructions |
40 | 42 | - Ensure that test code is automated, comprehensive, and follows testing best practices. |
41 | 43 | - Verify that all critical functionality is covered by tests. |
| 44 | + - Verify that minimal acceptance tests (e.g. those run by the workflow CI-MATs) are passing and |
| 45 | + error free, pointing out any failure as below minimal acceptance (i.e. un-acceptable). |
42 | 46 | - Ensure that the test coverage meets or exceeds the project's required threshold |
43 | 47 | (e.g., aiming for 100% coverage as per Issue #53). |
44 | 48 | - For **test** code, *also* follow |
45 | 49 | [CEP-9](https://gist.github.com/reactive-firewall/d840ee9990e65f302ce2a8d78ebe73f6) |
46 | 50 |
|
47 | 51 | # Misc. |
| 52 | + - Verify that this file `.coderabbit.yaml` is present, validated, and current. |
48 | 53 | - Confirm that the code meets the project's requirements and objectives. |
49 | 54 | - Confirm that copyright years are up-to date whenever a file is changed. |
| 55 | + - Verify that dependencies are licensed under either the PSF License, a MIT License, |
| 56 | + a BSD License, the Unlicence, the Apache v2 License, or that the dependency is optional. Do |
| 57 | + not assume a dependency is optional, confirm if it is or is not optional. |
50 | 58 | - For **Python** code, consider [PEP 290](https://peps.python.org/pep-0290/) whenever a python |
51 | 59 | (e.g. has the extension '.py') file is changed. |
52 | 60 | request_changes_workflow: true |
@@ -85,75 +93,109 @@ reviews: |
85 | 93 | instructions: >- |
86 | 94 | 1. Consider the file 'README.md' the overview/introduction of the project. |
87 | 95 | Also consider the 'README.md' file the first place to look for project documentation. |
88 | | -
|
89 | 96 | 2. When reviewing the file 'README.md' it should be linted with help |
90 | 97 | from the tools `markdownlint` and `languagetool`, pointing out any issues. |
91 | | -
|
92 | 98 | 3. You may assume the file 'README.md' will contain GitHub flavor Markdown. |
| 99 | + 4. The file `README.md` contains many links to additional valuable project documentation. |
| 100 | + 5. Ensure the README is kept current. |
93 | 101 | - path: '**/*.py' |
94 | 102 | instructions: >- |
95 | 103 | When reviewing **Python** code for this project: |
96 | | -
|
97 | | - 1. Prioritize portability over clarity, especially when dealing with cross-Python compatibility. However, with the priority in mind, do still consider improvements to clarity when relevant. |
98 | | -
|
99 | | - 2. As a general guideline, consider the code style advocated in the PEP 8 standard (excluding the use of spaces for indentation) and evaluate suggested changes for code style compliance. |
100 | | -
|
101 | | - 3. As a style convention, consider the code style advocated in [CEP-8](https://gist.github.com/reactive-firewall/b7ee98df9e636a51806e62ef9c4ab161) and evaluate suggested changes for code style compliance. |
102 | | -
|
103 | | - 4. As a general guideline, try to provide any relevant, official, and supporting documentation links to any tool's suggestions in review comments. This guideline is important for posterity. |
104 | | -
|
105 | | - 5. As a general rule, undocumented function definitions and class definitions in the project's Python code are assumed incomplete. Please consider suggesting a short summary of the code for any of these incomplete definitions as docstrings when reviewing. |
106 | | -
|
107 | | - 6. Verify Flake8's configuration file is located at ".flake8.ini" |
| 104 | + 1. Prioritize portability over clarity, especially when dealing with cross-Python |
| 105 | + compatibility. However, with the priority in mind, do still consider improvements to |
| 106 | + clarity when relevant. |
| 107 | + 2. As a general guideline, consider the code style advocated in the PEP 8 standard |
| 108 | + (excluding the use of spaces for indentation) and evaluate suggested changes for code |
| 109 | + style compliance. |
| 110 | + 3. As a style convention, consider the code style advocated in |
| 111 | + [CEP-8](https://gist.github.com/reactive-firewall/b7ee98df9e636a51806e62ef9c4ab161) |
| 112 | + and evaluate suggested changes for code style compliance. |
| 113 | + 4. As a general guideline, try to provide any relevant, official, and supporting |
| 114 | + documentation links to any tool's suggestions in review comments. This guideline is |
| 115 | + important for posterity. |
| 116 | + 5. As a general rule, undocumented function definitions and class definitions in the |
| 117 | + project's Python code are assumed incomplete. Please consider suggesting a short |
| 118 | + summary of the code for any of these incomplete definitions as docstrings when |
| 119 | + reviewing. All documentation including docstrings in the project are to align with |
| 120 | + the guidelines set by |
| 121 | + [CEP-7](https://gist.github.com/reactive-firewall/123b8a45f1bdeb064079e0524a29ec20). |
| 122 | + 6. Verify Flake8's configuration file is located at ".flake8.ini". Flake8 is run |
| 123 | + automaticly by the `flake8-cq` GHA used by the `.github/workflows/flake8.yml` workflow. |
| 124 | + 7. Verify alignment of any new changes, with the code style advocated in |
| 125 | + [CEP-8](https://gist.github.com/reactive-firewall/b7ee98df9e636a51806e62ef9c4ab161), |
| 126 | + pointing out any introduced deviations. |
108 | 127 | - path: 'tests/*' |
109 | 128 | instructions: >- |
110 | 129 | When reviewing **test** code: |
111 | | -
|
112 | | - 1. Prioritize portability over clarity, especially when dealing with cross-Python compatibility. However, with the priority in mind, do still consider improvements to clarity when relevant. |
113 | | -
|
114 | | - 2. As a general guideline, consider the code style advocated in the PEP 8 standard (excluding the use of spaces for indentation) and evaluate suggested changes for code style compliance. |
115 | | -
|
116 | | - 3. As a style convention, consider the code style advocated in [CEP-8](https://gist.github.com/reactive-firewall/b7ee98df9e636a51806e62ef9c4ab161) and evaluate suggested changes for code style compliance, pointing out any violations discovered. |
117 | | -
|
118 | | - 4. As a general guideline, try to provide any relevant, official, and supporting documentation links to any tool's suggestions in review comments. This guideline is important for posterity. |
119 | | -
|
120 | | - 5. As a project rule, Python source files with names prefixed by the string "test_" and located in the project's "tests" directory are the project's unit-testing code. It is safe, albeit a heuristic, to assume these are considered part of the project's minimal acceptance testing unless a justifying exception to this assumption is documented. |
121 | | -
|
122 | | - 6. As a project rule, any files without extensions and with names prefixed by either the string "check_" or the string "test_", and located in the project's "tests" directory, are the project's non-unit test code. "Non-unit test" in this context refers to any type of testing other than unit testing, such as (but not limited to) functional testing, style linting, regression testing, etc. It can also be assumed that non-unit testing code is usually written as Bash shell scripts. |
| 130 | + 1. Prioritize portability over clarity, especially when dealing with cross-Python |
| 131 | + compatibility. However, with the priority in mind, do still consider improvements |
| 132 | + to clarity when relevant. |
| 133 | + 2. As a general guideline, consider the code style advocated in the PEP 8 standard |
| 134 | + (excluding the use of spaces for indentation) and evaluate suggested changes |
| 135 | + for code style compliance. |
| 136 | + 3. As a style convention, consider the code style advocated in |
| 137 | + [CEP-8](https://gist.github.com/reactive-firewall/b7ee98df9e636a51806e62ef9c4ab161) |
| 138 | + and evaluate suggested changes for code style compliance, pointing out any |
| 139 | + violations discovered. |
| 140 | + 4. As a style convention, consider the code style advocated in |
| 141 | + [CEP-9](https://gist.github.com/reactive-firewall/d840ee9990e65f302ce2a8d78ebe73f6) |
| 142 | + and evaluate suggested changes for nomenclature compliance, pointing out any |
| 143 | + violations discovered, along with suggestions generated to correct the nomenclature. |
| 144 | + 5. As a general guideline, try to provide any relevant, official, and supporting |
| 145 | + documentation links to any tool's suggestions in review comments. This guideline is |
| 146 | + important for posterity. |
| 147 | + 6. As a project rule, Python source files with names prefixed by the string |
| 148 | + "test_" and located in the project's "tests" directory are the project's unit-testing |
| 149 | + code. It is safe, albeit a heuristic, to assume these are considered part of the |
| 150 | + project's minimal acceptance testing unless a justifying exception to this assumption |
| 151 | + is documented. |
| 152 | + 7. As a project rule, any files without extensions and with names prefixed by either the |
| 153 | + string "check_" or the string "test_", and located in the project's "tests" directory, |
| 154 | + are the project's non-unit test code. "Non-unit test" in this context refers to any |
| 155 | + type of testing other than unit testing, such as (but not limited to) |
| 156 | + functional testing, style linting, regression testing, etc. It can also be assumed |
| 157 | + that non-unit testing code is usually (but not always) written as Bash shell scripts. |
123 | 158 | - path: requirements.txt |
124 | 159 | instructions: >- |
125 | | - * The project's own Python dependencies are recorded in 'requirements.txt' for production code. |
126 | | -
|
127 | | - * The project's testing-specific Python dependencies are recorded in 'tests/requirements.txt' and are used for testing the project. |
128 | | -
|
129 | | - * The project's documentation-specific Python dependencies are recorded in 'docs/requirements.txt' and are used only for generating Python-focused documentation for the project. 'docs/requirements.txt' may be absent if not applicable. |
130 | | -
|
131 | | - Consider these 'requirements.txt' files the records of truth regarding project dependencies. |
| 160 | + 1. The project's own Python dependencies are recorded in 'requirements.txt' for |
| 161 | + production code. |
| 162 | + 2. The project's testing-specific Python dependencies are recorded in |
| 163 | + 'tests/requirements.txt' and are used for testing the project. |
| 164 | + 3. The project's documentation-specific Python dependencies are recorded in |
| 165 | + 'docs/requirements.txt' and are used only for generating Python-focused documentation |
| 166 | + for the project. 'docs/requirements.txt' may be absent if not applicable. |
| 167 | + 4. Consider these 'requirements.txt' files the records of truth regarding project |
| 168 | + dependencies. |
| 169 | + 5. Consider the 'requirements.txt' file in the base of the git repository |
| 170 | + (e.g. './requirements.txt') the required python dependencies regarding Multicast project |
| 171 | + dependencies. |
132 | 172 | - path: tests/requirements.txt |
133 | 173 | instructions: >- |
134 | | - * The multicast project's own dependencies are recorded in |
135 | | - './requirements.txt' for production code. |
136 | | -
|
137 | | - * The multicast project's own test code dependencies are recorded in |
138 | | - 'tests/requirements.txt' for testing the project. |
139 | | -
|
140 | | - Consider these the records of truth regarding project test code dependencies. |
| 174 | + 1. The multicast project's own dependencies are recorded in './requirements.txt' |
| 175 | + for production code. |
| 176 | + 2. The project's testing-specific Python dependencies are recorded in |
| 177 | + 'tests/requirements.txt' and are used for testing the project. |
| 178 | + 3. Consider these the records of truth regarding project test code dependencies. |
| 179 | + 4. The project's testing-specific dependencies are **optional** and considered non-default |
| 180 | + extras when selected. |
141 | 181 | - path: '.github/**' |
142 | 182 | instructions: >- |
143 | | - * When the project is hosted on GitHub: All GitHub-specific configurations, templates, and tools should be found in the '.github' directory tree. |
144 | | -
|
145 | | - * 'actionlint' erroneously generates false positives when dealing with GitHub's `${{ ... }}` syntax in conditionals. |
146 | | -
|
147 | | - * 'actionlint' erroneously generates incorrect solutions when suggesting the removal of valid `${{ ... }}` syntax. |
| 183 | + * When the project is hosted on GitHub: All GitHub-specific configurations, templates, |
| 184 | + and tools should be found in the '.github' directory tree. |
| 185 | + * 'actionlint' erroneously generates false positives when dealing with |
| 186 | + GitHub's `${{ ... }}` syntax in conditionals. |
| 187 | + * 'actionlint' erroneously generates incorrect solutions when suggesting the removal of |
| 188 | + valid `${{ ... }}` syntax. |
148 | 189 | - path: 'docs/*' |
149 | 190 | instructions: >- |
150 | 191 | When a project contains a `docs/` directory: |
151 | | -
|
152 | | - 1. Consider the files in the `docs/` directory tree the core/main/in-depth documentation of the project. Also consider the 'docs/**.md' files the second place to look for project documentation after the 'README.md' file. |
153 | | -
|
154 | | - 2. When reviewing the documentation files (e.g. `docs/**.md`), they should additionally be linted with help from the tool `markdownlint`, pointing out any issues. |
155 | | -
|
156 | | - 3. When reviewing the documentation files in `docs/` directory, they should additionally be linted with help from the tool `languagetool`, pointing out any issues. |
| 192 | + 1. Consider the files in the `docs/` directory tree the core/main/in-depth documentation |
| 193 | + of the project. Also consider the 'docs/**.md' files the second place to look for |
| 194 | + project documentation after the 'README.md' file. |
| 195 | + 2. When reviewing the documentation files (e.g. `docs/**.md`), they should additionally |
| 196 | + be linted with help from the tool `markdownlint`, pointing out any issues. |
| 197 | + 3. When reviewing the documentation files in `docs/` directory, they should additionally |
| 198 | + be linted with help from the tool `languagetool`, pointing out any issues. |
157 | 199 | abort_on_close: true |
158 | 200 | auto_review: |
159 | 201 | enabled: true |
|
0 commit comments