Browse Source

Cleanup py27 support

This repo is now testing only with Python 3, so let's make
a few cleanups:
- Remove python 2.7 stanza from setup.py
- Remove obsolete sections from setup.cfg
- Update classifiers
- Switch from python2 only oslosphinx to openstackdocsthemem
- Remove install_command from tox.ini, the default is fine
- Switch to hacking 3.0 to support python 3

Change-Id: I37daff5a29f4732f4e3b2e20497903799d67caa3
changes/89/719189/2
Andreas Jaeger 2 months ago
committed by Andreas Jaeger
parent
commit
7bd04cf8bd
5 changed files with 14 additions and 32 deletions
  1. +6
    -1
      doc/source/conf.py
  2. +2
    -12
      setup.cfg
  3. +0
    -9
      setup.py
  4. +3
    -7
      test-requirements.txt
  5. +3
    -3
      tox.ini

+ 6
- 1
doc/source/conf.py View File

@@ -23,9 +23,10 @@ sys.path.insert(0, os.path.abspath('../..'))
extensions = [
'sphinx.ext.autodoc',
#'sphinx.ext.intersphinx',
'oslosphinx'
'openstackdocstheme'
]


# autodoc generation is a bit aggressive and a nuisance when doing heavy
# text edit cycles.
# execute "export SPHINX_DEBUG=1" in your terminal to disable
@@ -50,6 +51,10 @@ add_module_names = True
# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'

html_theme = 'openstackdocs'
repository_name = 'openstack/tripleo-repos'
bug_project = 'tripleo'

# -- Options for HTML output --------------------------------------------------

# The theme to use for HTML and HTML Help pages. Major themes that come with


+ 2
- 12
setup.cfg View File

@@ -13,6 +13,8 @@ classifier =
License :: OSI Approved :: Apache Software License
Operating System :: POSIX :: Linux
Programming Language :: Python
Programming Language :: Python :: Implementation :: CPython
Programming Language :: Python :: 3 :: Only
Programming Language :: Python :: 3
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
@@ -24,15 +26,3 @@ packages =
[entry_points]
console_scripts =
tripleo-repos = tripleo_repos.main:main

[build_sphinx]
all-files = 1
warning-is-error = 1
source-dir = doc/source
build-dir = doc/build

[upload_sphinx]
upload-dir = doc/build/html

[bdist_wheel]
universal=1

+ 0
- 9
setup.py View File

@@ -13,17 +13,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.

# THIS FILE IS MANAGED BY THE GLOBAL REQUIREMENTS REPO - DO NOT EDIT
import setuptools

# In python < 2.7.4, a lazy loading of package `pbr` will break
# setuptools if some other modules registered functions in `atexit`.
# solution from: http://bugs.python.org/issue15881#msg170215
try:
import multiprocessing # noqa
except ImportError:
pass

setuptools.setup(
setup_requires=['pbr>=2.0'],
pbr=True)

+ 3
- 7
test-requirements.txt View File

@@ -2,14 +2,13 @@
# of appearance. Changing the order has an impact on the overall integration
# process, which may cause wedges in the gate later.

hacking>=0.12.0,!=0.13.0,<0.14 # Apache-2.0
hacking>=3.0,<=3.1.0 # Apache-2.0

coverage>=4.0,!=4.4 # Apache-2.0
ddt>=1.0.1 # MIT
python-subunit>=0.0.18 # Apache-2.0/BSD
sphinx>=1.8.0,<2.0.0;python_version=='2.7' # BSD
sphinx>=1.8.0,!=2.1.0;python_version>='3.4' # BSD
oslosphinx>=4.7.0 # Apache-2.0
sphinx>=1.8.0,!=2.1.0 # BSD
openstackdocstheme>=2.0.0 # Apache-2.0
oslotest>=1.10.0 # Apache-2.0
testrepository>=0.0.18 # Apache-2.0/BSD
testscenarios>=0.4 # Apache-2.0/BSD
@@ -18,6 +17,3 @@ stestr>=2.0.0 # Apache-2.0
fixtures>=3.0.0 # Apache-2.0/BSD
mock>=2.0 # BSD

# releasenotes
reno>=2.5.0 # Apache-2.0


+ 3
- 3
tox.ini View File

@@ -6,9 +6,10 @@ envlist = py37,pep8
[testenv]
usedevelop = True
basepython = python3
install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} {opts} {packages}
setenv = VIRTUAL_ENV={envdir}
deps = -r{toxinidir}/test-requirements.txt
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/requirements.txt
commands = stestr run --slowest {posargs}

@@ -16,7 +17,6 @@ commands = stestr run --slowest {posargs}
commands = {posargs}

[testenv:docs]
basepython = python3
whitelist_externals =
rm
commands =


Loading…
Cancel
Save