+v36.1.0
+-------
+
+* #1083: Avoid race condition on directory creation in
+ ``pkg_resources.ensure_directory``.
+
+* Removed deprecation of and restored support for
+ ``upload_docs`` command for sites other than PyPI.
+ Only warehouse is dropping support, but services like
+ `devpi <http://doc.devpi.net/latest/>`_ continue to
+ support docs built by setuptools' plugins. See
+ `this comment <https://bitbucket.org/hpk42/devpi/issues/388/support-rtd-model-for-building-uploading#comment-34292423>`_
+ for more context on the motivation for this change.
+
v36.0.1
-------
import sys
import textwrap
import subprocess
+import io
minimal_egg_info = textwrap.dedent("""
"""
os.mkdir('setuptools.egg-info')
- with open('setuptools.egg-info/entry_points.txt', 'w') as ep:
+ with io.open('setuptools.egg-info/entry_points.txt', 'w') as ep:
ep.write(minimal_egg_info)
successful build of a tagged release per
`PyPI deployment <https://docs.travis-ci.com/user/deployment/pypi>`_.
-To cut a release, install and run ``bumpversion {part}`` where ``part``
+Prior to cutting a release, please check that the CHANGES.rst reflects
+the summary of changes since the last release.
+Ideally, these changelog entries would have been added
+along with the changes, but it's always good to check.
+Think about it from the
+perspective of a user not involved with the development--what would
+that person want to know about what has changed--or from the
+perspective of your future self wanting to know when a particular
+change landed.
+
+To cut a release, install and run ``bump2version {part}`` where ``part``
is major, minor, or patch based on the scope of the changes in the
release. Then, push the commits to the master branch. If tests pass,
-the release will be uploaded to PyPI (from the Python 3.5 tests).
-
-Bootstrap Branch
-----------------
-
-Setuptools has a bootstrap script (ez_setup.py), which is hosted in the
-repository in the ``bootstrap`` branch.
-
-Therefore, the latest bootstrap script can be retrieved by checking out
-that branch.
-
-The officially-published location of the bootstrap script is hosted on Python
-infrastructure (#python-infra on freenode) at https://bootstrap.pypa.io and
-is updated every fifteen minutes from the bootstrap branch. Sometimes,
-especially when the bootstrap script is rolled back, this
-process doesn't work as expected and requires manual intervention.
+the release will be uploaded to PyPI (from the Python 3.6 tests).
Release Frequency
-----------------
except ImportError:
importlib_machinery = None
+from . import py31compat
from pkg_resources.extern import appdirs
from pkg_resources.extern import packaging
__import__('pkg_resources.extern.packaging.version')
__import__('pkg_resources.extern.packaging.requirements')
__import__('pkg_resources.extern.packaging.markers')
+
if (3, 0) < sys.version_info < (3, 3):
raise RuntimeError("Python 3.3 or later is required")
def ensure_directory(path):
"""Ensure that the parent directory of `path` exists"""
dirname = os.path.dirname(path)
- if not os.path.isdir(dirname):
- os.makedirs(dirname)
+ py31compat.makedirs(dirname, exist_ok=True)
def _bypass_ensure_directory(path):
--- /dev/null
+import os
+import errno
+import sys
+
+
+PY32 = sys.version_info >= (3, 2)
+
+
+def _makedirs_31(path, exist_ok=False):
+ try:
+ os.makedirs(path)
+ except OSError as exc:
+ if exc.errno != errno.EEXIST:
+ raise
+
+
+makedirs = os.makedirs if PY32 else _makedirs_31
[bumpversion]
-current_version = 36.0.1
+current_version = 36.1.0
commit = True
tag = True
setup_params = dict(
name="setuptools",
- version="36.0.1",
+ version="36.1.0",
description="Easily download, build, install, upgrade, and uninstall "
"Python packages",
author="Python Packaging Authority",
self.target_dir = None
def finalize_options(self):
- log.warn("Upload_docs command is deprecated. Use RTD instead.")
upload.finalize_options(self)
if self.upload_dir is None:
if self.has_sphinx():
else:
self.ensure_dirname('upload_dir')
self.target_dir = self.upload_dir
+ if 'pypi.python.org' in self.repository:
+ log.warn("Upload_docs command is deprecated. Use RTD instead.")
self.announce('Using upload directory %s' % self.target_dir)
def create_zipfile(self, filename):