Sophie

Sophie

distrib > Fedora > 17 > x86_64 > by-pkgid > b6f82ea76d5134c5709ffcc9dc9e29c5 > files > 369

Django-doc-1.4.5-1.fc17.noarch.rpm


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>Committing code &mdash; Django 1.4.5 documentation</title>
    
    <link rel="stylesheet" href="../../_static/default.css" type="text/css" />
    <link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '../../',
        VERSION:     '1.4.5',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="../../_static/jquery.js"></script>
    <script type="text/javascript" src="../../_static/underscore.js"></script>
    <script type="text/javascript" src="../../_static/doctools.js"></script>
    <link rel="top" title="Django 1.4.5 documentation" href="../../index.html" />
    <link rel="up" title="Contributing to Django" href="index.html" />
    <link rel="next" title="Django committers" href="../committers.html" />
    <link rel="prev" title="Localizing Django" href="localizing.html" />
 
<script type="text/javascript" src="../../templatebuiltins.js"></script>
<script type="text/javascript">
(function($) {
    if (!django_template_builtins) {
       // templatebuiltins.js missing, do nothing.
       return;
    }
    $(document).ready(function() {
        // Hyperlink Django template tags and filters
        var base = "../../ref/templates/builtins.html";
        if (base == "#") {
            // Special case for builtins.html itself
            base = "";
        }
        // Tags are keywords, class '.k'
        $("div.highlight\\-html\\+django span.k").each(function(i, elem) {
             var tagname = $(elem).text();
             if ($.inArray(tagname, django_template_builtins.ttags) != -1) {
                 var fragment = tagname.replace(/_/, '-');
                 $(elem).html("<a href='" + base + "#" + fragment + "'>" + tagname + "</a>");
             }
        });
        // Filters are functions, class '.nf'
        $("div.highlight\\-html\\+django span.nf").each(function(i, elem) {
             var filtername = $(elem).text();
             if ($.inArray(filtername, django_template_builtins.tfilters) != -1) {
                 var fragment = filtername.replace(/_/, '-');
                 $(elem).html("<a href='" + base + "#" + fragment + "'>" + filtername + "</a>");
             }
        });
    });
})(jQuery);
</script>

  </head>
  <body>

    <div class="document">
  <div id="custom-doc" class="yui-t6">
    <div id="hd">
      <h1><a href="../../index.html">Django 1.4.5 documentation</a></h1>
      <div id="global-nav">
        <a title="Home page" href="../../index.html">Home</a>  |
        <a title="Table of contents" href="../../contents.html">Table of contents</a>  |
        <a title="Global index" href="../../genindex.html">Index</a>  |
        <a title="Module index" href="../../py-modindex.html">Modules</a>
      </div>
      <div class="nav">
    &laquo; <a href="localizing.html" title="Localizing Django">previous</a> 
     |
    <a href="../index.html" title="Django internals" accesskey="U">up</a>
   |
    <a href="../committers.html" title="Django committers">next</a> &raquo;</div>
    </div>
    
    <div id="bd">
      <div id="yui-main">
        <div class="yui-b">
          <div class="yui-g" id="internals-contributing-committing-code">
            
  <div class="section" id="s-committing-code">
<span id="committing-code"></span><h1>Committing code<a class="headerlink" href="#committing-code" title="Permalink to this headline">¶</a></h1>
<p>This section is addressed to the <a class="reference internal" href="../committers.html"><em>Django committers</em></a> and to anyone
interested in knowing how code gets committed into Django core.</p>
<div class="section" id="s-commit-access">
<span id="commit-access"></span><h2>Commit access<a class="headerlink" href="#commit-access" title="Permalink to this headline">¶</a></h2>
<p>Django has two types of committers:</p>
<dl class="docutils">
<dt>Core committers</dt>
<dd>These are people who have a long history of contributions to Django&#8217;s
codebase, a solid track record of being polite and helpful on the
mailing lists, and a proven desire to dedicate serious time to Django&#8217;s
development. The bar is high for full commit access.</dd>
<dt>Partial committers</dt>
<dd><p class="first">These are people who are &#8220;domain experts.&#8221; They have direct check-in
access to the subsystems that fall under their jurisdiction, and they&#8217;re
given a formal vote in questions that involve their subsystems. This type
of access is likely to be given to someone who contributes a large
subframework to Django and wants to continue to maintain it.</p>
<p class="last">Partial commit access is granted by the same process as full
committers. However, the bar is set lower; proven expertise in the area
in question is likely to be sufficient.</p>
</dd>
</dl>
<p>Decisions on new committers will follow the process explained in
<a class="reference internal" href="bugs-and-features.html#how-we-make-decisions"><em>How we make decisions</em></a>. To request commit access, please contact an
existing committer privately. Public requests for commit access are potential
flame-war starters, and will be ignored.</p>
</div>
<div class="section" id="s-committing-guidelines">
<span id="committing-guidelines"></span><h2>Committing guidelines<a class="headerlink" href="#committing-guidelines" title="Permalink to this headline">¶</a></h2>
<p>Please follow these guidelines when committing code to Django&#8217;s Subversion
repository:</p>
<ul>
<li><p class="first">For any medium-to-big changes, where &#8220;medium-to-big&#8221; is according to
your judgment, please bring things up on the <a class="reference external" href="http://groups.google.com/group/django-developers">django-developers</a>
mailing list before making the change.</p>
<p>If you bring something up on <a class="reference external" href="http://groups.google.com/group/django-developers">django-developers</a> and nobody responds,
please don&#8217;t take that to mean your idea is great and should be
implemented immediately because nobody contested it. Django&#8217;s lead
developers don&#8217;t have a lot of time to read mailing-list discussions
immediately, so you may have to wait a couple of days before getting a
response.</p>
</li>
<li><p class="first">Write detailed commit messages in the past tense, not present tense.</p>
<ul class="simple">
<li>Good: &#8220;Fixed Unicode bug in RSS API.&#8221;</li>
<li>Bad: &#8220;Fixes Unicode bug in RSS API.&#8221;</li>
<li>Bad: &#8220;Fixing Unicode bug in RSS API.&#8221;</li>
</ul>
</li>
<li><p class="first">For commits to a branch, prefix the commit message with the branch name.
For example: &#8220;magic-removal: Added support for mind reading.&#8221;</p>
</li>
<li><p class="first">Limit commits to the most granular change that makes sense. This means,
use frequent small commits rather than infrequent large commits. For
example, if implementing feature X requires a small change to library Y,
first commit the change to library Y, then commit feature X in a
separate commit. This goes a <em>long way</em> in helping all core Django
developers follow your changes.</p>
</li>
<li><p class="first">Separate bug fixes from feature changes.</p>
<p>Bug fixes need to be added to the current bugfix branch as well as the
current trunk.</p>
</li>
<li><p class="first">If your commit closes a ticket in the Django <a class="reference external" href="https://code.djangoproject.com/newticket">ticket tracker</a>, begin
your commit message with the text &#8220;Fixed #abc&#8221;, where &#8220;abc&#8221; is the
number of the ticket your commit fixes. Example: &#8220;Fixed #123 &#8211; Added
support for foo&#8221;. We&#8217;ve rigged Subversion and Trac so that any commit
message in that format will automatically close the referenced ticket
and post a comment to it with the full commit message.</p>
<p>If your commit closes a ticket and is in a branch, use the branch name
first, then the &#8220;Fixed #abc.&#8221; For example:
&#8220;magic-removal: Fixed #123 &#8211; Added whizbang feature.&#8221;</p>
<p>For the curious: we&#8217;re using a <a class="reference external" href="http://trac.edgewall.org/browser/trunk/contrib/trac-svn-post-commit-hook.cmd">Trac post-commit hook</a> for this.</p>
</li>
<li><p class="first">If your commit references a ticket in the Django <a class="reference external" href="https://code.djangoproject.com/newticket">ticket tracker</a> but
does <em>not</em> close the ticket, include the phrase &#8220;Refs #abc&#8221;, where &#8220;abc&#8221;
is the number of the ticket your commit references. We&#8217;ve rigged
Subversion and Trac so that any commit message in that format will
automatically post a comment to the appropriate ticket.</p>
</li>
<li><p class="first">Write commit messages for backports using this pattern:</p>
<div class="highlight-python"><pre>[&lt;Django version&gt;] Fixed &lt;ticket&gt; -- &lt;description&gt;

Backport of &lt;revision&gt; from &lt;branch&gt;.</pre>
</div>
<p>For example:</p>
<div class="highlight-python"><pre>[1.3.X] Fixed #17028 - Changed diveintopython.org -&gt; diveintopython.net.

Backport of r17115 from trunk.</pre>
</div>
</li>
</ul>
</div>
<div class="section" id="s-reverting-commits">
<span id="reverting-commits"></span><h2>Reverting commits<a class="headerlink" href="#reverting-commits" title="Permalink to this headline">¶</a></h2>
<p>Nobody&#8217;s perfect; mistakes will be committed. When a mistaken commit is
discovered, please follow these guidelines:</p>
<ul class="simple">
<li>Try very hard to ensure that mistakes don&#8217;t happen. Just because we
have a reversion policy doesn&#8217;t relax your responsibility to aim for
the highest quality possible. Really: double-check your work before
you commit it in the first place!</li>
<li>If possible, have the original author revert his/her own commit.</li>
<li>Don&#8217;t revert another author&#8217;s changes without permission from the
original author.</li>
<li>If the original author can&#8217;t be reached (within a reasonable amount
of time &#8211; a day or so) and the problem is severe &#8211; crashing bug,
major test failures, etc &#8211; then ask for objections on the
<a class="reference external" href="http://groups.google.com/group/django-developers">django-developers</a> mailing list then revert if there are none.</li>
<li>If the problem is small (a feature commit after feature freeze,
say), wait it out.</li>
<li>If there&#8217;s a disagreement between the committer and the
reverter-to-be then try to work it out on the <a class="reference external" href="http://groups.google.com/group/django-developers">django-developers</a>
mailing list. If an agreement can&#8217;t be reached then it should
be put to a vote.</li>
<li>If the commit introduced a confirmed, disclosed security
vulnerability then the commit may be reverted immediately without
permission from anyone.</li>
<li>The release branch maintainer may back out commits to the release
branch without permission if the commit breaks the release branch.</li>
</ul>
</div>
</div>


          </div>         
        </div>
      </div>
      
        
          <div class="yui-b" id="sidebar">
            
      <div class="sphinxsidebar">
        <div class="sphinxsidebarwrapper">
  <h3><a href="../../contents.html">Table Of Contents</a></h3>
  <ul>
<li><a class="reference internal" href="#">Committing code</a><ul>
<li><a class="reference internal" href="#commit-access">Commit access</a></li>
<li><a class="reference internal" href="#committing-guidelines">Committing guidelines</a></li>
<li><a class="reference internal" href="#reverting-commits">Reverting commits</a></li>
</ul>
</li>
</ul>

  <h3>Browse</h3>
  <ul>
    
      <li>Prev: <a href="localizing.html">Localizing Django</a></li>
    
    
      <li>Next: <a href="../committers.html">Django committers</a></li>
    
  </ul>
  <h3>You are here:</h3>
  <ul>
      <li>
        <a href="../../index.html">Django 1.4.5 documentation</a>
        
          <ul><li><a href="../index.html">Django internals</a>
        
          <ul><li><a href="index.html">Contributing to Django</a>
        
        <ul><li>Committing code</li></ul>
        </li></ul></li></ul>
      </li>
  </ul>  

  <h3>This Page</h3>
  <ul class="this-page-menu">
    <li><a href="../../_sources/internals/contributing/committing-code.txt"
           rel="nofollow">Show Source</a></li>
  </ul>
<div id="searchbox" style="display: none">
  <h3>Quick search</h3>
    <form class="search" action="../../search.html" method="get">
      <input type="text" name="q" />
      <input type="submit" value="Go" />
      <input type="hidden" name="check_keywords" value="yes" />
      <input type="hidden" name="area" value="default" />
    </form>
    <p class="searchtip" style="font-size: 90%">
    Enter search terms or a module, class or function name.
    </p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>
              <h3>Last update:</h3>
              <p class="topless">Feb 21, 2013</p>
          </div> 
        
      
    </div>
    
    <div id="ft">
      <div class="nav">
    &laquo; <a href="localizing.html" title="Localizing Django">previous</a> 
     |
    <a href="../index.html" title="Django internals" accesskey="U">up</a>
   |
    <a href="../committers.html" title="Django committers">next</a> &raquo;</div>
    </div>
  </div>

      <div class="clearer"></div>
    </div>
  </body>
</html>