[bumpversion]
-current_version = 46.3.0
+current_version = 46.3.1
commit = True
tag = True
+v46.3.1
+-------
+
+No significant changes.
+
+
v46.3.0
-------
.. _PyPI link: https://pypi.org/project/setuptools
-.. image:: https://dev.azure.com/jaraco/setuptools/_apis/build/status/jaraco.setuptools?branchName=master
+.. image:: https://dev.azure.com/jaraco/setuptools/_apis/build/status/pypa.setuptools?branchName=master
:target: https://dev.azure.com/jaraco/setuptools/_build/latest?definitionId=1&branchName=master
.. image:: https://img.shields.io/travis/pypa/setuptools/master.svg?label=Linux%20CI&logo=travis&logoColor=white
- '*'
pool:
- vmimage: 'Ubuntu-18.04'
+ vmImage: $(pool_vm_image)
variables:
- group: Azure secrets
+- name: pool_vm_image
+ value: Ubuntu-18.04
stages:
- stage: Test
- job: 'Test'
strategy:
matrix:
- Python36:
+ Bionic Python 3.6:
python.version: '3.6'
- Python38:
+ Bionic Python 3.8:
python.version: '3.8'
+ Windows:
+ python.version: '3.8'
+ pool_vm_image: vs2017-win2016
+ MacOS:
+ python.version: '3.8'
+ pool_vm_image: macos-10.15
+
maxParallel: 4
steps:
[metadata]
name = setuptools
-version = 46.3.0
+version = 46.3.1
description = Easily download, build, install, upgrade, and uninstall Python packages
author = Python Packaging Authority
author_email = distutils-sig@python.org
import sys
import os
import distutils.errors
+import platform
from setuptools.extern import six
from setuptools.extern.six.moves import urllib, http_client
assert rep == 'My message about md5'
+@pytest.fixture
+def temp_home(tmpdir, monkeypatch):
+ key = (
+ 'USERPROFILE'
+ if platform.system() == 'Windows' and sys.version_info > (3, 8) else
+ 'HOME'
+ )
+
+ monkeypatch.setitem(os.environ, key, str(tmpdir))
+ return tmpdir
+
+
class TestPyPIConfig:
- def test_percent_in_password(self, tmpdir, monkeypatch):
- monkeypatch.setitem(os.environ, 'HOME', str(tmpdir))
- pypirc = tmpdir / '.pypirc'
- with pypirc.open('w') as strm:
- strm.write(DALS("""
- [pypi]
- repository=https://pypi.org
- username=jaraco
- password=pity%
- """))
+ def test_percent_in_password(self, temp_home):
+ pypirc = temp_home / '.pypirc'
+ pypirc.write(DALS("""
+ [pypi]
+ repository=https://pypi.org
+ username=jaraco
+ password=pity%
+ """))
cfg = setuptools.package_index.PyPIConfig()
cred = cfg.creds_by_repository['https://pypi.org']
assert cred.username == 'jaraco'
"""
Check setuptools can be installed in a clean environment.
"""
- bare_virtualenv.run(' && '.join((
- 'cd {source}',
- 'python setup.py install',
- )).format(source=SOURCE_DIR))
+ bare_virtualenv.run(['python', 'setup.py', 'install'], cd=SOURCE_DIR)
def _get_pip_versions():
dist_dir = virtualenv.workspace
# Generate source distribution / wheel.
virtualenv.run(' && '.join((
- 'cd {source}',
'python setup.py -q sdist -d {dist}',
'python setup.py -q bdist_wheel -d {dist}',
- )).format(source=SOURCE_DIR, dist=dist_dir))
+ )).format(dist=dist_dir), cd=SOURCE_DIR)
sdist = glob.glob(os.path.join(dist_dir, '*.zip'))[0]
wheel = glob.glob(os.path.join(dist_dir, '*.whl'))[0]
# Then update from wheel.
open('success', 'w').close()
'''))
# Run test command for test package.
- virtualenv.run(' && '.join((
- 'cd {tmpdir}',
- 'python setup.py test -s test',
- )).format(tmpdir=tmpdir))
+ virtualenv.run(
+ ['python', 'setup.py', 'test', '-s', 'test'], cd=str(tmpdir))
assert tmpdir.join('success').check()
Quick and dirty test to ensure all external dependencies are vendored.
"""
for command in ('upload',): # sorted(distutils.command.__all__):
- bare_virtualenv.run(' && '.join((
- 'cd {source}',
- 'python setup.py {command} -h',
- )).format(command=command, source=SOURCE_DIR))
+ bare_virtualenv.run(
+ ['python', 'setup.py', command, '-h'], cd=SOURCE_DIR)
subprocess.check_output(['git', 'config', 'user.email'])
+def check_changes():
+ """
+ Verify that all of the files in changelog.d have the appropriate
+ names.
+ """
+ allowed = 'deprecation', 'breaking', 'change', 'doc', 'misc'
+ assert all(
+ any(key in file.name for key in allowed)
+ for file in pathlib.Path('changelog.d').iterdir()
+ if file.name != '.gitignore'
+ )
+
+
if __name__ == '__main__':
print("Cutting release at", get_version())
ensure_config()
+ check_changes()
update_changelog()
bump_version()