Sophie

Sophie

distrib > Mageia > 6 > armv7hl > media > core-updates > by-pkgid > 65530c6176058f9b54858c3b4f6385e6 > files > 653

python-django-doc-1.8.19-1.mga6.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" lang="">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>How is Django Formed? &#8212; Django 1.8.19 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.8.19',
        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="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="top" title="Django 1.8.19 documentation" href="../contents.html" />
    <link rel="up" title="Django internals" href="index.html" />
    <link rel="prev" title="The Django source code repository" href="git.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 role="document">

    <div class="document">
  <div id="custom-doc" class="yui-t6">
    <div id="hd">
      <h1><a href="../index.html">Django 1.8.19 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="git.html" title="The Django source code repository">previous</a>
     |
    <a href="index.html" title="Django internals" accesskey="U">up</a></div>
    </div>

    <div id="bd">
      <div id="yui-main">
        <div class="yui-b">
          <div class="yui-g" id="internals-howto-release-django">
            
  <div class="section" id="s-how-is-django-formed">
<span id="how-is-django-formed"></span><h1>How is Django Formed?<a class="headerlink" href="#how-is-django-formed" title="Permalink to this headline">¶</a></h1>
<p>This document explains how to release Django.</p>
<p><strong>Please, keep these instructions up-to-date if you make changes!</strong> The point
here is to be descriptive, not prescriptive, so feel free to streamline or
otherwise make changes, but <strong>update this document accordingly!</strong></p>
<div class="section" id="s-overview">
<span id="overview"></span><h2>Overview<a class="headerlink" href="#overview" title="Permalink to this headline">¶</a></h2>
<p>There are three types of releases that you might need to make:</p>
<ul class="simple">
<li>Security releases: disclosing and fixing a vulnerability. This&#8217;ll
generally involve two or three simultaneous releases &#8211; e.g.
1.5.x, 1.6.x, and, depending on timing, perhaps a 1.7 alpha/beta/rc.</li>
<li>Regular version releases: either a final release (e.g. 1.5) or a
bugfix update (e.g. 1.5.1).</li>
<li>Pre-releases: e.g. 1.6 alpha, beta, or rc.</li>
</ul>
<p>The short version of the steps involved is:</p>
<ol class="arabic simple">
<li>If this is a security release, pre-notify the security distribution list
one week before the actual release.</li>
<li>Proofread the release notes, looking for organization and writing errors.
Draft a blog post and email announcement.</li>
<li>Update version numbers and create the release package(s).</li>
<li>Upload the package(s) to the <code class="docutils literal"><span class="pre">djangoproject.com</span></code> server.</li>
<li>Unless this is a pre-release, add the new version(s) to PyPI.</li>
<li>Declare the new version in the admin on <code class="docutils literal"><span class="pre">djangoproject.com</span></code>.</li>
<li>Post the blog entry and send out the email announcements.</li>
<li>Update version numbers post-release.</li>
</ol>
<p>There are a lot of details, so please read on.</p>
</div>
<div class="section" id="s-prerequisites">
<span id="prerequisites"></span><h2>Prerequisites<a class="headerlink" href="#prerequisites" title="Permalink to this headline">¶</a></h2>
<p>You&#8217;ll need a few things before getting started:</p>
<ul>
<li><p class="first">A GPG key. If the key you want to use is not your default signing key, you&#8217;ll
need to add <code class="docutils literal"><span class="pre">-u</span> <span class="pre">you&#64;example.com</span></code> to every GPG signing command below, where
<code class="docutils literal"><span class="pre">you&#64;example.com</span></code> is the email address associated with the key you want to
use.</p>
</li>
<li><p class="first">An install of some required Python packages:</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ pip install wheel twine
</pre></div>
</div>
</li>
<li><p class="first">Access to Django&#8217;s record on PyPI. Create a file with your credentials:</p>
<div class="highlight-default"><div class="snippet-filename">~/.pypirc</div>
<div class="highlight"><pre><span></span><span class="p">[</span><span class="n">pypi</span><span class="p">]</span>
<span class="n">username</span><span class="p">:</span><span class="n">YourUsername</span>
<span class="n">password</span><span class="p">:</span><span class="n">YourPassword</span>
</pre></div>
</div>
</li>
<li><p class="first">Access to the <code class="docutils literal"><span class="pre">djangoproject.com</span></code> server to upload files.</p>
</li>
<li><p class="first">Access to the admin on <code class="docutils literal"><span class="pre">djangoproject.com</span></code> as a &#8220;Site maintainer&#8221;.</p>
</li>
<li><p class="first">Access to post to <code class="docutils literal"><span class="pre">django-announce</span></code>.</p>
</li>
<li><p class="first">If this is a security release, access to the pre-notification distribution
list.</p>
</li>
</ul>
<p>If this is your first release, you&#8217;ll need to coordinate with James and/or
Jacob to get all these things lined up.</p>
</div>
<div class="section" id="s-pre-release-tasks">
<span id="pre-release-tasks"></span><h2>Pre-release tasks<a class="headerlink" href="#pre-release-tasks" title="Permalink to this headline">¶</a></h2>
<p>A few items need to be taken care of before even beginning the release process.
This stuff starts about a week before the release; most of it can be done
any time leading up to the actual release:</p>
<ol class="arabic simple">
<li>If this is a security release, send out pre-notification <strong>one week</strong> before
the release. We maintain a list of who gets these pre-notification emails in
the private <code class="docutils literal"><span class="pre">django-core</span></code> repository. Send the mail to
<code class="docutils literal"><span class="pre">security&#64;djangoproject.com</span></code> and BCC the pre-notification recipients.
This email should be signed by the key you&#8217;ll use for the release, and
should include patches for each issue being fixed.</li>
<li>As the release approaches, watch Trac to make sure no release blockers
are left for the upcoming release.</li>
<li>Check with the other committers to make sure they don&#8217;t have any
uncommitted changes for the release.</li>
<li>Proofread the release notes, including looking at the online
version to catch any broken links or reST errors, and make sure the
release notes contain the correct date.</li>
<li>Double-check that the release notes mention deprecation timelines
for any APIs noted as deprecated, and that they mention any changes
in Python version support.</li>
<li>Double-check that the release notes index has a link to the notes
for the new release; this will be in <code class="docutils literal"><span class="pre">docs/releases/index.txt</span></code>.</li>
</ol>
</div>
<div class="section" id="s-preparing-for-release">
<span id="preparing-for-release"></span><h2>Preparing for release<a class="headerlink" href="#preparing-for-release" title="Permalink to this headline">¶</a></h2>
<p>Write the announcement blog post for the release. You can enter it into the
admin at any time and mark it as inactive. Here are a few examples: <a class="reference external" href="https://www.djangoproject.com/weblog/2013/feb/19/security/">example
security release announcement</a>, <a class="reference external" href="https://www.djangoproject.com/weblog/2012/mar/23/14/">example regular release announcement</a>,
<a class="reference external" href="https://www.djangoproject.com/weblog/2012/nov/27/15-beta-1/">example pre-release announcement</a>.</p>
</div>
<div class="section" id="s-actually-rolling-the-release">
<span id="actually-rolling-the-release"></span><h2>Actually rolling the release<a class="headerlink" href="#actually-rolling-the-release" title="Permalink to this headline">¶</a></h2>
<p>OK, this is the fun part, where we actually push out a release!</p>
<ol class="arabic">
<li><p class="first">Check <a class="reference external" href="http://djangoci.com">Jenkins</a> is green for the version(s) you&#8217;re putting out. You
probably shouldn&#8217;t issue a release until it&#8217;s green.</p>
</li>
<li><p class="first">A release always begins from a release branch, so you should make sure
you&#8217;re on a stable branch and up-to-date. For example:</p>
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">git</span> <span class="n">checkout</span> <span class="n">stable</span><span class="o">/</span><span class="mf">1.5</span><span class="o">.</span><span class="n">x</span>
<span class="n">git</span> <span class="n">pull</span>
</pre></div>
</div>
</li>
<li><p class="first">If this is a security release, merge the appropriate patches from
<code class="docutils literal"><span class="pre">django-private</span></code>. Rebase these patches as necessary to make each one a
simple commit on the release branch rather than a merge commit. To ensure
this, merge them with the <code class="docutils literal"><span class="pre">--ff-only</span></code> flag; for example:</p>
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">git</span> <span class="n">checkout</span> <span class="n">stable</span><span class="o">/</span><span class="mf">1.5</span><span class="o">.</span><span class="n">x</span>
<span class="n">git</span> <span class="n">merge</span> <span class="o">--</span><span class="n">ff</span><span class="o">-</span><span class="n">only</span> <span class="n">security</span><span class="o">/</span><span class="mf">1.5</span><span class="o">.</span><span class="n">x</span>
</pre></div>
</div>
<p>(This assumes <code class="docutils literal"><span class="pre">security/1.5.x</span></code> is a branch in the <code class="docutils literal"><span class="pre">django-private</span></code> repo
containing the necessary security patches for the next release in the 1.5
series.)</p>
<p>If git refuses to merge with <code class="docutils literal"><span class="pre">--ff-only</span></code>, switch to the security-patch
branch and rebase it on the branch you are about to merge it into (<code class="docutils literal"><span class="pre">git</span>
<span class="pre">checkout</span> <span class="pre">security/1.5.x;</span> <span class="pre">git</span> <span class="pre">rebase</span> <span class="pre">stable/1.5.x</span></code>) and then switch back and
do the merge. Make sure the commit message for each security fix explains
that the commit is a security fix and that an announcement will follow
(<a class="reference external" href="https://github.com/django/django/commit/3ef4bbf495cc6c061789132e3d50a8231a89406b">example security commit</a>).</p>
</li>
<li><p class="first">For a major version release, remove the <code class="docutils literal"><span class="pre">UNDER</span> <span class="pre">DEVELOPMENT</span></code> header at the
top of the release notes and add the release date on the next line. For a
minor release, replace <code class="docutils literal"><span class="pre">*Under</span> <span class="pre">Development*</span></code> with the release date. Make
this change on all branches where the release notes for a particular version
are located.</p>
</li>
<li><p class="first">Update the version number in <code class="docutils literal"><span class="pre">django/__init__.py</span></code> for the release.
Please see <a class="reference internal" href="#notes-on-setting-the-version-tuple">notes on setting the VERSION tuple</a> below for details
on <code class="docutils literal"><span class="pre">VERSION</span></code>.</p>
<p>In 1.4, the version number in <code class="docutils literal"><span class="pre">docs/conf.py</span></code> and <code class="docutils literal"><span class="pre">setup.py</span></code> should also
be updated. Here&#8217;s <a class="reference external" href="https://github.com/django/django/commit/592187e11b934f83153133cd5b3a246a881359e7">an example commit updating version numbers</a> for that.</p>
</li>
<li><p class="first">If this is a pre-release package, update the &#8220;Development Status&#8221; trove
classifier in <code class="docutils literal"><span class="pre">setup.py</span></code> to reflect this. Otherwise, make sure the
classifier is set to <code class="docutils literal"><span class="pre">Development</span> <span class="pre">Status</span> <span class="pre">::</span> <span class="pre">5</span> <span class="pre">-</span> <span class="pre">Production/Stable</span></code>.</p>
</li>
<li><p class="first">Tag the release using <code class="docutils literal"><span class="pre">git</span> <span class="pre">tag</span></code>. For example:</p>
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">git</span> <span class="n">tag</span> <span class="o">--</span><span class="n">sign</span> <span class="o">--</span><span class="n">message</span><span class="o">=</span><span class="s2">&quot;Tag 1.5.1&quot;</span> <span class="mf">1.5</span><span class="o">.</span><span class="mi">1</span>
</pre></div>
</div>
<p>You can check your work by running <code class="docutils literal"><span class="pre">git</span> <span class="pre">tag</span> <span class="pre">--verify</span> <span class="pre">&lt;tag&gt;</span></code>.</p>
</li>
<li><p class="first">Push your work, including the tag: <code class="docutils literal"><span class="pre">git</span> <span class="pre">push</span> <span class="pre">--tags</span></code>.</p>
</li>
<li><p class="first">Make sure you have an absolutely clean tree by running <code class="docutils literal"><span class="pre">git</span> <span class="pre">clean</span> <span class="pre">-dfx</span></code>.</p>
</li>
<li><p class="first">Run <code class="docutils literal"><span class="pre">make</span> <span class="pre">-f</span> <span class="pre">extras/Makefile</span></code> to generate the release packages. This will
create the release packages in a <code class="docutils literal"><span class="pre">dist/</span></code> directory. Note that we don&#8217;t
publish wheel files for 1.4.</p>
</li>
<li><p class="first">Generate the hashes of the release packages:</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ <span class="nb">cd</span> dist
$ md5sum *
$ sha1sum *
$ sha256sum *
</pre></div>
</div>
</li>
<li><p class="first">Create a &#8220;checksums&#8221; file, <code class="docutils literal"><span class="pre">Django-&lt;&lt;VERSION&gt;&gt;.checksum.txt</span></code> containing
the hashes and release information. Start with this template and insert the
correct version, date, GPG key ID (from
<code class="docutils literal"><span class="pre">gpg</span> <span class="pre">--list-keys</span> <span class="pre">--keyid-format</span> <span class="pre">LONG</span></code>), release URL, and checksums:</p>
<div class="highlight-default"><div class="highlight"><pre><span></span>This file contains MD5, SHA1, and SHA256 checksums for the source-code
tarball of Django &lt;&lt;VERSION&gt;&gt;, released &lt;&lt;DATE&gt;&gt;.

To use this file, you will need a working install of PGP or other
compatible public-key encryption software. You will also need to have
the Django release manager&#39;s public key in your keyring; this key has
the ID ``XXXXXXXXXXXXXXXX`` and can be imported from the MIT
keyserver. For example, if using the open-source GNU Privacy Guard
implementation of PGP:

    gpg --keyserver pgp.mit.edu --recv-key XXXXXXXXXXXXXXXX

Once the key is imported, verify this file::

    gpg --verify &lt;&lt;THIS FILENAME&gt;&gt;

Once you have verified this file, you can use normal MD5, SHA1, or SHA256
checksumming applications to generate the checksums of the Django
package and compare them to the checksums listed below.

Release packages:
=================

Django &lt;&lt;VERSION&gt;&gt; (tar.tgz): https://www.djangoproject.com/m/releases/&lt;&lt;RELEASE TAR.GZ FILENAME&gt;&gt;
Django &lt;&lt;VERSION&gt;&gt; (.whl): https://www.djangoproject.com/m/releases/&lt;&lt;RELEASE WHL FILENAME&gt;&gt;

MD5 checksums:
==============

&lt;&lt;MD5SUM&gt;&gt;  &lt;&lt;RELEASE TAR.GZ FILENAME&gt;&gt;
&lt;&lt;MD5SUM&gt;&gt;  &lt;&lt;RELEASE WHL FILENAME&gt;&gt;

SHA1 checksums:
===============

&lt;&lt;SHA1SUM&gt;&gt;  &lt;&lt;RELEASE TAR.GZ FILENAME&gt;&gt;
&lt;&lt;SHA1SUM&gt;&gt;  &lt;&lt;RELEASE WHL FILENAME&gt;&gt;

SHA256 checksums:
=================

&lt;&lt;SHA256SUM&gt;&gt;  &lt;&lt;RELEASE TAR.GZ FILENAME&gt;&gt;
&lt;&lt;SHA256SUM&gt;&gt;  &lt;&lt;RELEASE WHL FILENAME&gt;&gt;
</pre></div>
</div>
</li>
<li><p class="first">Sign the checksum file (<code class="docutils literal"><span class="pre">gpg</span> <span class="pre">--clearsign</span> <span class="pre">--digest-algo</span> <span class="pre">SHA256</span>
<span class="pre">Django-&lt;version&gt;.checksum.txt</span></code>). This generates a signed document,
<code class="docutils literal"><span class="pre">Django-&lt;version&gt;.checksum.txt.asc</span></code> which you can then verify using <code class="docutils literal"><span class="pre">gpg</span>
<span class="pre">--verify</span> <span class="pre">Django-&lt;version&gt;.checksum.txt.asc</span></code>.</p>
</li>
</ol>
<p>If you&#8217;re issuing multiple releases, repeat these steps for each release.</p>
</div>
<div class="section" id="s-making-the-release-s-available-to-the-public">
<span id="making-the-release-s-available-to-the-public"></span><h2>Making the release(s) available to the public<a class="headerlink" href="#making-the-release-s-available-to-the-public" title="Permalink to this headline">¶</a></h2>
<p>Now you&#8217;re ready to actually put the release out there. To do this:</p>
<ol class="arabic">
<li><p class="first">Upload the release package(s) to the djangoproject server, replacing
A.B. with the appropriate version number, e.g. 1.5 for a 1.5.x release:</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ scp Django-* djangoproject.com:/home/www/www/media/releases/A.B
</pre></div>
</div>
</li>
<li><p class="first">Upload the checksum file(s):</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ scp Django-A.B.C.checksum.txt.asc djangoproject.com:/home/www/www/media/pgp/Django-A.B.C.checksum.txt
</pre></div>
</div>
</li>
<li><p class="first">Test that the release packages install correctly using <code class="docutils literal"><span class="pre">easy_install</span></code>
and <code class="docutils literal"><span class="pre">pip</span></code>. Here&#8217;s one method (which requires <a class="reference external" href="https://pypi.python.org/pypi/virtualenvwrapper">virtualenvwrapper</a>):</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ <span class="nv">RELEASE_VERSION</span><span class="o">=</span><span class="s1">&#39;1.7.2&#39;</span>
$ <span class="nv">MAJOR_VERSION</span><span class="o">=</span><span class="sb">`</span><span class="nb">echo</span> <span class="nv">$RELEASE_VERSION</span><span class="p">|</span> cut -c 1-3<span class="sb">`</span>

$ mktmpenv
$ easy_install https://www.djangoproject.com/m/releases/<span class="nv">$MAJOR_VERSION</span>/Django-<span class="nv">$RELEASE_VERSION</span>.tar.gz
$ deactivate
$ mktmpenv
$ pip install https://www.djangoproject.com/m/releases/<span class="nv">$MAJOR_VERSION</span>/Django-<span class="nv">$RELEASE_VERSION</span>.tar.gz
$ deactivate
$ mktmpenv
$ pip install https://www.djangoproject.com/m/releases/<span class="nv">$MAJOR_VERSION</span>/Django-<span class="nv">$RELEASE_VERSION</span>-py2.py3-none-any.whl
$ deactivate
</pre></div>
</div>
<p>This just tests that the tarballs are available (i.e. redirects are up) and
that they install correctly, but it&#8217;ll catch silly mistakes.</p>
</li>
<li><p class="first">Ask a few people on IRC to verify the checksums by visiting the checksums
file (e.g. <a class="reference external" href="https://www.djangoproject.com/m/pgp/Django-1.5b1.checksum.txt">https://www.djangoproject.com/m/pgp/Django-1.5b1.checksum.txt</a>)
and following the instructions in it. For bonus points, they can also unpack
the downloaded release tarball and verify that its contents appear to be
correct (proper version numbers, no stray <code class="docutils literal"><span class="pre">.pyc</span></code> or other undesirable
files).</p>
</li>
<li><p class="first">Upload the release packages to PyPI:</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ twine upload -s dist/*
</pre></div>
</div>
</li>
<li><p class="first">Go to the <a class="reference external" href="https://www.djangoproject.com/admin/releases/release/add/">Add release page in the admin</a>, enter the new release number
exactly as it appears in the name of the tarball (Django-&lt;version&gt;.tar.gz).
So for example enter &#8220;1.5.1&#8221; or &#8220;1.4-rc-2&#8221;, etc. If the release is part of
an LTS branch, mark it so.</p>
</li>
<li><p class="first">Make the blog post announcing the release live.</p>
</li>
<li><p class="first">For a new version release (e.g. 1.5, 1.6), update the default stable version
of the docs by flipping the <code class="docutils literal"><span class="pre">is_default</span></code> flag to <code class="docutils literal"><span class="pre">True</span></code> on the
appropriate <code class="docutils literal"><span class="pre">DocumentRelease</span></code> object in the <code class="docutils literal"><span class="pre">docs.djangoproject.com</span></code>
database (this will automatically flip it to <code class="docutils literal"><span class="pre">False</span></code> for all
others); you can do this using the site&#8217;s admin.</p>
</li>
<li><p class="first">Post the release announcement to the <a class="reference internal" href="mailing-lists.html#django-announce-mailing-list"><span class="std std-ref">django-announce</span></a>,
<a class="reference internal" href="mailing-lists.html#django-developers-mailing-list"><span class="std std-ref">django-developers</span></a>, and <a class="reference internal" href="mailing-lists.html#django-users-mailing-list"><span class="std std-ref">django-users</span></a> mailing lists. This should
include links to the announcement blog post.</p>
</li>
</ol>
</div>
<div class="section" id="s-post-release">
<span id="post-release"></span><h2>Post-release<a class="headerlink" href="#post-release" title="Permalink to this headline">¶</a></h2>
<p>You&#8217;re almost done! All that&#8217;s left to do now is:</p>
<ol class="arabic simple">
<li>Update the <code class="docutils literal"><span class="pre">VERSION</span></code> tuple in <code class="docutils literal"><span class="pre">django/__init__.py</span></code> again,
incrementing to whatever the next expected release will be. For
example, after releasing 1.5.1, update <code class="docutils literal"><span class="pre">VERSION</span></code> to
<code class="docutils literal"><span class="pre">VERSION</span> <span class="pre">=</span> <span class="pre">(1,</span> <span class="pre">5,</span> <span class="pre">2,</span> <span class="pre">'alpha',</span> <span class="pre">0)</span></code>.</li>
<li>Add the release in <a class="reference external" href="https://code.djangoproject.com/admin/ticket/versions">Trac&#8217;s versions list</a> if necessary (and make it the
default if it&#8217;s a final release). Not all versions are declared;
take example on previous releases.</li>
<li>If this was a security release, update <a class="reference internal" href="../releases/security.html"><span class="doc">Archive of security issues</span></a> with
details of the issues addressed.</li>
</ol>
</div>
<div class="section" id="s-new-stable-branch-tasks">
<span id="new-stable-branch-tasks"></span><h2>New stable branch tasks<a class="headerlink" href="#new-stable-branch-tasks" title="Permalink to this headline">¶</a></h2>
<p>There are several items to do in the time following a the creation of a new
stable branch (often following an alpha release). Some of these tasks don&#8217;t
need to be done by the releaser.</p>
<ol class="arabic simple">
<li>Create a new <code class="docutils literal"><span class="pre">DocumentRelease</span></code> object in the <code class="docutils literal"><span class="pre">docs.djangoproject.com</span></code>
database for the new version&#8217;s docs, and update the
<code class="docutils literal"><span class="pre">docs/fixtures/doc_releases.json</span></code> JSON fixture, so people without access
to the production DB can still run an up-to-date copy of the docs site.</li>
<li>Create a stub release note for the new major version. Use the stub from the
previous major version or use the previous major version and delete most of
the contents leaving only section headings.</li>
<li>Increase the default PBKDF2 iterations in
<code class="docutils literal"><span class="pre">django.contrib.auth.hashers.PBKDF2PasswordHasher</span></code> by about 20%
(pick a round number). Run the tests, and update the 3 failing
hasher tests with the new values. Make sure this gets noted in the
release notes (see the 1.8 release notes for an example).</li>
<li>Remove features that have reached the end of their deprecation cycle. Each
removal should be done in a separate commit for clarity. In the commit
message, add a &#8220;refs #XXXX&#8221; to the original ticket where the deprecation
began if possible.</li>
<li>Remove <code class="docutils literal"><span class="pre">..</span> <span class="pre">versionadded::</span></code>, <code class="docutils literal"><span class="pre">..</span> <span class="pre">versionadded::</span></code>, and <code class="docutils literal"><span class="pre">..</span> <span class="pre">deprecated::</span></code>
annotations in the documentation from two releases ago. For example, in
Django 1.9, notes for 1.7 will be removed.</li>
</ol>
</div>
<div class="section" id="s-notes-on-setting-the-version-tuple">
<span id="notes-on-setting-the-version-tuple"></span><h2>Notes on setting the VERSION tuple<a class="headerlink" href="#notes-on-setting-the-version-tuple" title="Permalink to this headline">¶</a></h2>
<p>Django&#8217;s version reporting is controlled by the <code class="docutils literal"><span class="pre">VERSION</span></code> tuple in
<code class="docutils literal"><span class="pre">django/__init__.py</span></code>. This is a five-element tuple, whose elements
are:</p>
<ol class="arabic simple">
<li>Major version.</li>
<li>Minor version.</li>
<li>Micro version.</li>
<li>Status &#8211; can be one of &#8220;alpha&#8221;, &#8220;beta&#8221;, &#8220;rc&#8221; or &#8220;final&#8221;.</li>
<li>Series number, for alpha/beta/RC packages which run in sequence
(allowing, for example, &#8220;beta 1&#8221;, &#8220;beta 2&#8221;, etc.).</li>
</ol>
<p>For a final release, the status is always &#8220;final&#8221; and the series
number is always 0. A series number of 0 with an &#8220;alpha&#8221; status will
be reported as &#8220;pre-alpha&#8221;.</p>
<p>Some examples:</p>
<ul class="simple">
<li><code class="docutils literal"><span class="pre">(1,</span> <span class="pre">2,</span> <span class="pre">1,</span> <span class="pre">'final',</span> <span class="pre">0)</span></code> → &#8220;1.2.1&#8221;</li>
<li><code class="docutils literal"><span class="pre">(1,</span> <span class="pre">3,</span> <span class="pre">0,</span> <span class="pre">'alpha',</span> <span class="pre">0)</span></code> → &#8220;1.3 pre-alpha&#8221;</li>
<li><code class="docutils literal"><span class="pre">(1,</span> <span class="pre">3,</span> <span class="pre">0,</span> <span class="pre">'beta',</span> <span class="pre">2)</span></code> → &#8220;1.3 beta 2&#8221;</li>
</ul>
</div>
</div>


          </div>
        </div>
      </div>
      
        
          <div class="yui-b" id="sidebar">
            
      <div class="sphinxsidebar" role="navigation" aria-label="main navigation">
        <div class="sphinxsidebarwrapper">
  <h3><a href="../contents.html">Table Of Contents</a></h3>
  <ul>
<li><a class="reference internal" href="#">How is Django Formed?</a><ul>
<li><a class="reference internal" href="#overview">Overview</a></li>
<li><a class="reference internal" href="#prerequisites">Prerequisites</a></li>
<li><a class="reference internal" href="#pre-release-tasks">Pre-release tasks</a></li>
<li><a class="reference internal" href="#preparing-for-release">Preparing for release</a></li>
<li><a class="reference internal" href="#actually-rolling-the-release">Actually rolling the release</a></li>
<li><a class="reference internal" href="#making-the-release-s-available-to-the-public">Making the release(s) available to the public</a></li>
<li><a class="reference internal" href="#post-release">Post-release</a></li>
<li><a class="reference internal" href="#new-stable-branch-tasks">New stable branch tasks</a></li>
<li><a class="reference internal" href="#notes-on-setting-the-version-tuple">Notes on setting the VERSION tuple</a></li>
</ul>
</li>
</ul>

  <h3>Browse</h3>
  <ul>
    
      <li>Prev: <a href="git.html">The Django source code repository</a></li>
    
    
  </ul>
  <h3>You are here:</h3>
  <ul>
      <li>
        <a href="../index.html">Django 1.8.19 documentation</a>
        
          <ul><li><a href="index.html">Django internals</a>
        
        <ul><li>How is Django Formed?</li></ul>
        </li></ul>
      </li>
  </ul>

  <div role="note" aria-label="source link">
    <h3>This Page</h3>
    <ul class="this-page-menu">
      <li><a href="../_sources/internals/howto-release-django.txt"
            rel="nofollow">Show Source</a></li>
    </ul>
   </div>
<div id="searchbox" style="display: none" role="search">
  <h3>Quick search</h3>
    <form class="search" action="../search.html" method="get">
      <div><input type="text" name="q" /></div>
      <div><input type="submit" value="Go" /></div>
      <input type="hidden" name="check_keywords" value="yes" />
      <input type="hidden" name="area" value="default" />
    </form>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>
              <h3>Last update:</h3>
              <p class="topless">Mar 10, 2018</p>
          </div>
        
      
    </div>

    <div id="ft">
      <div class="nav">
    &laquo; <a href="git.html" title="The Django source code repository">previous</a>
     |
    <a href="index.html" title="Django internals" accesskey="U">up</a></div>
    </div>
  </div>

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