Jump to: navigation, search

Solum/Contributing

< Solum
Revision as of 14:38, 2 November 2013 by Adrian Otto (talk | contribs) (Review Guidelines)

Before You Begin

The configuration of the Solum StackForge Repo requires that you have an OpenStack CLA. For information about how prepare for contribution, please consult the How To Contribute wiki page.

Learn About Gerrit

Be sure to read the Gerrit Workflow wiki page for information about how to submit your commit for review so it can be merged into the Solum code base.

Setting up your git review settings

 git config --global user.name "Firstname Lastname"
 git config --global user.email "your_email@youremail.com"
 git config --global gitreview.username "your_launchpad_username"

To check your git configuration:

 git config --list

Installing git-review

On Ubuntu, MacOSx, or most other Unix-like systems, it is as simple as:

 pip install git-review

There are other installation options detailed in the Installation Instructions. You can now check out the Solum code and begin working on it:


Your first commit

Set up your local branch

 git clone git://git.openstack.org/stackforge/solum
 cd solum
 git checkout -b [branch name]
 git review -s

Modify CONTRIBUTORS file

Open the file for edit, add your name and email address to the list and save the file.

 vi CONTRIBUTORS.rst

Create a draft review

 git add CONTRIBUTORS.rst
 git commit -a
 git review -v --draft

At this point if all has been successful it should provide you with a review.openstack.org URL to track your change. Follow that URL and "Sign In" and you should see your change.

Write some awesome code

At this point can write your code and push it up to your review. You will want to amend your changes to the original commit ( reduce noise )

 git add <list of files you added/changed>
 git commit --amend 
 git review -v

Once you are happy with your code and want it to be reviewed you want to convert it from a Draft. "Sign In" at https://review.openstack.org/ and after verifying the review yourself hit the "Publish" button on the page.

Upon approval of the review your code will be automatically merged.

Reviews

The OpenStack CI system uses the concept of core reviewers. These are individuals who have consistently reviewed code for the project, and helped over a considerable period of time to improve the quality and consistency of what we merge into the code base. Project contributors will feel that this reviewer is a positive influence on the team and that they maintain the values and traditions of the OpenStack development community.

Policies

Existing core reviewers may nominate new ones in an ML thread. Consent among the current reviewers shall result in the declaration of the new core reviewer by the PTL. Lack of unanimous consent shall be carefully considered, and a final decision informed by input from from active team members shall be made by the PTL. Core reviewers who are judged by their peers in the core review group to fall short of the expectations for contribution of a core reviewer may be nominated for return to regular reviewer status.

The current Gerrit policy is:

label-Code-Review = -2..+2 group solum-core
label-Approved = +0..+1 group solum-core

Patches require a core reviewer to mark a review as "Approved" before they are merged.

Review Guidelines

  • For Approval, two core reviewers should supply a +2.
  • If a patch submitted by one contributor is picked up and completed by another contributor, special handling of the resolution should be used.