improvements from feedback
This commit is contained in:
parent
3504a546e6
commit
7ad26bdc6e
2 changed files with 44 additions and 35 deletions
4
.github/PULL_REQUEST_TEMPLATE.md
vendored
4
.github/PULL_REQUEST_TEMPLATE.md
vendored
|
@ -15,9 +15,5 @@
|
|||
- [ ] Tested execution of all binary files (usually in `./result/bin/`)
|
||||
- [ ] Fits [CONTRIBUTING.md](https://github.com/NixOS/nixpkgs/blob/master/.github/CONTRIBUTING.md).
|
||||
|
||||
###### Reviewing this pull-request
|
||||
|
||||
See the nixpkgs manual for more details on how to [Review contributions](http://hydra.nixos.org/job/nixpkgs/trunk/manual/latest/download-by-type/doc/manual#chap-reviewing-contributions).
|
||||
|
||||
---
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
<para>The nixpkgs projects receives a fairly high number of contributions via github pull-requests. Reviewing and approving these is an important task and a way to contribute to the project.</para>
|
||||
|
||||
<para>The high activity of nixpkgs change make any pull request that is open for long enough subject to conflicts that will require extra work from the submitter or the merger. Reviewing pull requests in a timely manner and being responsive to the comments is the key to avoid these. Github provides sort filters that can be used to see the <link xlink:href="https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+sort%3Aupdated-desc">most recently</link> and the <link xlink:href="https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+sort%3Aupdated-asc">least recently</link> updated pull-requests.</para>
|
||||
<para>The high change rate of nixpkgs make any pull request that is open for long enough subject to conflicts that will require extra work from the submitter or the merger. Reviewing pull requests in a timely manner and being responsive to the comments is the key to avoid these. Github provides sort filters that can be used to see the <link xlink:href="https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+sort%3Aupdated-desc">most recently</link> and the <link xlink:href="https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+is%3Aopen+sort%3Aupdated-asc">least recently</link> updated pull-requests.</para>
|
||||
|
||||
<para>When reviewing a pull request, please always be nice and polite. Controversial changes can lead to controversial opinions, but it is important to respect every community members and their work.</para>
|
||||
|
||||
|
@ -31,42 +31,55 @@
|
|||
<listitem><para><literal>8.has: package (update)</literal> and any topic label that fit the updated package.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the package versioning is fitting the guidelines.</para></listitem>
|
||||
<listitem><para>Checking that the commit text is fitting the guidelines.</para></listitem>
|
||||
<listitem><para>Checking that the package maintainers are notified.</para>
|
||||
<listitem><para>Ensure that the package versioning is fitting the guidelines.</para></listitem>
|
||||
<listitem><para>Ensure that the commit text is fitting the guidelines.</para></listitem>
|
||||
<listitem><para>Ensure that the package maintainers are notified.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>mention-bot usually notify github users based on the submitted changes, but it can happen that it misses some of the package maintainers.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the meta field contains correct information.</para>
|
||||
<listitem><para>Ensure that the meta field contains correct information.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>License can change with version updates, so it should be checked to be fitting upstream license.</para></listitem>
|
||||
<listitem><para>If the package has no maintainer, a maintainer must be set. This can be the update submitter or a community member that accepts to take maintainership of the package.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the code contains no typos.</para></listitem>
|
||||
<listitem><para>Ensure that the code contains no typos.</para></listitem>
|
||||
<listitem><para>Building the package locally.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>Pull-requests are often targeted to the master or staging branch so building the pull-request locally as it is submitted can trigger a large amount of source builds.</para>
|
||||
<para>It is possible to rebase the changes on nixos-unstable or nixpkgs-unstable for easier review.</para>
|
||||
<para>It is possible to rebase the changes on nixos-unstable or nixpkgs-unstable for easier review by running the following commands from a nixpkgs clone.
|
||||
<screen>
|
||||
TODO: add commands for a local rebase and build
|
||||
$ git remote add channels https://github.com/NixOS/nixpkgs-channels.git <co xml:id='reviewing-rebase-1' />
|
||||
$ git fetch channels nixos-unstable <co xml:id='reviewing-rebase-2' />
|
||||
$ git fetch origin pull/PRNUMBER/head:PRNUMBER <co xml:id='reviewing-rebase-3' />
|
||||
$ git rebase --onto nixos-unstable PRNUMBER <co xml:id='reviewing-rebase-4' />
|
||||
</screen>
|
||||
<calloutlist>
|
||||
<callout arearefs='reviewing-rebase-1'>
|
||||
<para>This should be done only once to be able to fetch channel branches from the nixpkgs-channels repository.</para>
|
||||
</callout>
|
||||
<callout arearefs='reviewing-rebase-2'>
|
||||
<para>Fetching the nixos-unstable branch.</para>
|
||||
</callout>
|
||||
<callout arearefs='reviewing-rebase-3'>
|
||||
<para>Fetching the pull-request changes, <varname>PRNUMBER</varname> is the number at the end of the pull-request title.</para>
|
||||
</callout>
|
||||
<callout arearefs='reviewing-rebase-3'>
|
||||
<para>Rebasing the pull-request changes to the nixos-unstable branch.</para>
|
||||
</callout>
|
||||
</calloutlist>
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>The <link xlink:href="https://github.com/madjar/nox">nox</link> tool can be used to review a pull-request content in a single command. It doesn't rebase on a channel branch so it might trigger many source builds. <varname>PRNUMBER</varname> should be replaced by the number at the end of the pull-request title.</para>
|
||||
<para>The <link xlink:href="https://github.com/madjar/nox">nox</link> tool can be used to review a pull-request content in a single command. It doesn't rebase on a channel branch so it might trigger multiple source builds. <varname>PRNUMBER</varname> should be replaced by the number at the end of the pull-request title.</para>
|
||||
<screen>
|
||||
$ nox-review -k pr PRNUMBER
|
||||
$ nix-shell -p nox --run "nox-review -k pr PRNUMBER"
|
||||
</screen>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Running every binary.</para></listitem>
|
||||
<listitem><para>Checking that the packages using the updated package are building fine in case the updated package is a library or is used as a build input by many other packages.</para>
|
||||
<screen>
|
||||
TODO: add commands
|
||||
</screen>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
|
||||
<example><title>Sample template for a package update review</title>
|
||||
|
@ -98,17 +111,17 @@ TODO: add commands
|
|||
<listitem><para><literal>8.has: package (new)</literal> and any topic label that fit the new package.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the package versioning is fitting the guidelines.</para></listitem>
|
||||
<listitem><para>Checking that the commit name is fitting the guidelines.</para></listitem>
|
||||
<listitem><para>Checking that the meta field contains correct information.</para>
|
||||
<listitem><para>Ensure that the package versioning is fitting the guidelines.</para></listitem>
|
||||
<listitem><para>Ensure that the commit name is fitting the guidelines.</para></listitem>
|
||||
<listitem><para>Ensure that the meta field contains correct information.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>License must be checked to be fitting upstream license.</para></listitem>
|
||||
<listitem><para>Platforms should be set or the package will not get binary substitutes.</para></listitem>
|
||||
<listitem><para>A maintainer must be set, this can be the package submitter or a community member that accepts to take maintainership of the package.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the code contains no typos.</para></listitem>
|
||||
<listitem><para>Checking the package source.</para>
|
||||
<listitem><para>Ensure that the code contains no typos.</para></listitem>
|
||||
<listitem><para>Ensure the package source.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>Mirrors urls should be used when available.</para></listitem>
|
||||
<listitem><para>The most appropriate function should be used (e.g. packages from github should use <literal>fetchFromGithub</literal>).</para></listitem>
|
||||
|
@ -155,26 +168,26 @@ TODO: add commands
|
|||
<listitem><para><literal>8.has: module (update)</literal> and any topic label that fit the module.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the module maintainers are notified.</para>
|
||||
<listitem><para>Ensure that the module maintainers are notified.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>Mention-bot notify github users based on the submitted changes, but it can happen that it miss some of the package maintainers.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the module tests, if any, are succeeding.</para></listitem>
|
||||
<listitem><para>Checking that the introduced options are correct.</para>
|
||||
<listitem><para>Ensure that the module tests, if any, are succeeding.</para></listitem>
|
||||
<listitem><para>Ensure that the introduced options are correct.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>Type should be appropriate (string related types differs in their merging capabilities, <literal>optionSet</literal> and <literal>string</literal> types are deprecated).</para></listitem>
|
||||
<listitem><para>Description, default and example should be provided.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that option changes are backward compatible.</para>
|
||||
<listitem><para>Ensure that option changes are backward compatible.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para><literal>mkRenamedOptionModule</literal> and <literal>mkAliasOptionModule</literal> functions provide way to make option changes backward compatible.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that removed options are declared with <literal>mkRemovedOptionModule</literal></para></listitem>
|
||||
<listitem><para>Checking that changes that are not backward compatible are mentioned in release notes.</para></listitem>
|
||||
<listitem><para>Checking that documentations affected by the change is updated.</para></listitem>
|
||||
<listitem><para>Ensure that removed options are declared with <literal>mkRemovedOptionModule</literal></para></listitem>
|
||||
<listitem><para>Ensure that changes that are not backward compatible are mentioned in release notes.</para></listitem>
|
||||
<listitem><para>Ensure that documentations affected by the change is updated.</para></listitem>
|
||||
</itemizedlist>
|
||||
|
||||
<example><title>Sample template for a module update review</title>
|
||||
|
@ -207,20 +220,20 @@ TODO: add commands
|
|||
<listitem><para><literal>8.has: module (new)</literal> and any topic label that fit the module.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the module tests, if any, are succeeding.</para></listitem>
|
||||
<listitem><para>Checking that the introduced options are correct.</para>
|
||||
<listitem><para>Ensure that the module tests, if any, are succeeding.</para></listitem>
|
||||
<listitem><para>Ensure that the introduced options are correct.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>Type should be appropriate (string related types differs in their merging capabilities, <literal>optionSet</literal> and <literal>string</literal> types are deprecated).</para></listitem>
|
||||
<listitem><para>Description, default and example should be provided.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that module <literal>meta</literal> field is present</para>
|
||||
<listitem><para>Ensure that module <literal>meta</literal> field is present</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>Maintainers should be declared in <literal>meta.maintainers</literal>.</para></listitem>
|
||||
<listitem><para>Module documentation should be declared with <literal>meta.doc</literal>.</para></listitem>
|
||||
</itemizedlist>
|
||||
</listitem>
|
||||
<listitem><para>Checking that the module respect other modules functionality.</para>
|
||||
<listitem><para>Ensure that the module respect other modules functionality.</para>
|
||||
<itemizedlist>
|
||||
<listitem><para>For example, enabling a module should not open firewall ports by default.</para></listitem>
|
||||
</itemizedlist>
|
||||
|
|
Loading…
Reference in a new issue