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 requirements, no need for python_version anymore - Cleanup doc/source/conf.py to remove now obsolete content. - Use newer openstackdocstheme version - Remove install_command from tox.ini, the default is fine; move contraints into deps - Move python3 into base tox environment. Change-Id: Ibd243ce5be8415147c24f596b4059ec3fb68a89c
This commit is contained in:
parent
fd861534ef
commit
c127687d3d
@ -14,7 +14,6 @@
|
|||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
import openstackdocstheme
|
|
||||||
|
|
||||||
sys.path.insert(0, os.path.abspath('../..'))
|
sys.path.insert(0, os.path.abspath('../..'))
|
||||||
# -- General configuration ----------------------------------------------------
|
# -- General configuration ----------------------------------------------------
|
||||||
@ -31,7 +30,6 @@ extensions = [
|
|||||||
repository_name = 'openstack/manila-image-elements'
|
repository_name = 'openstack/manila-image-elements'
|
||||||
bug_project = 'manila-image-elements'
|
bug_project = 'manila-image-elements'
|
||||||
bug_tag = 'docs'
|
bug_tag = 'docs'
|
||||||
html_last_updated_fmt = '%Y-%m-%d %H:%M'
|
|
||||||
|
|
||||||
# autodoc generation is a bit aggressive and a nuisance when doing heavy
|
# autodoc generation is a bit aggressive and a nuisance when doing heavy
|
||||||
# text edit cycles.
|
# text edit cycles.
|
||||||
@ -63,7 +61,6 @@ pygments_style = 'sphinx'
|
|||||||
# Sphinx are currently 'default' and 'sphinxdoc'.
|
# Sphinx are currently 'default' and 'sphinxdoc'.
|
||||||
# html_theme_path = ["."]
|
# html_theme_path = ["."]
|
||||||
html_theme = 'openstackdocs'
|
html_theme = 'openstackdocs'
|
||||||
html_theme_path = [openstackdocstheme.get_html_theme_path()]
|
|
||||||
# html_static_path = ['static']
|
# html_static_path = ['static']
|
||||||
|
|
||||||
# Output file base name for HTML help builder.
|
# Output file base name for HTML help builder.
|
||||||
|
@ -15,7 +15,7 @@ Jinja2==2.10
|
|||||||
MarkupSafe==1.0
|
MarkupSafe==1.0
|
||||||
mccabe==0.2.1
|
mccabe==0.2.1
|
||||||
networkx==1.11
|
networkx==1.11
|
||||||
openstackdocstheme==1.18.1
|
openstackdocstheme==1.31.2
|
||||||
pbr==2.0.0
|
pbr==2.0.0
|
||||||
pep8==1.5.7
|
pep8==1.5.7
|
||||||
pyflakes==0.8.1
|
pyflakes==0.8.1
|
||||||
|
@ -18,12 +18,3 @@ scripts =
|
|||||||
|
|
||||||
data_files =
|
data_files =
|
||||||
share/manila-elements/elements = elements/*
|
share/manila-elements/elements = elements/*
|
||||||
|
|
||||||
[build_sphinx]
|
|
||||||
all_files = 1
|
|
||||||
build-dir = doc/build
|
|
||||||
source-dir = doc/source
|
|
||||||
warning-is-error = 1
|
|
||||||
|
|
||||||
[wheel]
|
|
||||||
universal = 1
|
|
||||||
|
9
setup.py
9
setup.py
@ -13,17 +13,8 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
# THIS FILE IS MANAGED BY THE GLOBAL REQUIREMENTS REPO - DO NOT EDIT
|
|
||||||
import setuptools
|
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(
|
setuptools.setup(
|
||||||
setup_requires=['pbr>=2.0.0'],
|
setup_requires=['pbr>=2.0.0'],
|
||||||
pbr=True)
|
pbr=True)
|
||||||
|
@ -6,6 +6,5 @@ bashate>=0.5.1 # Apache-2.0
|
|||||||
hacking>=3.0,<3.1.0 # Apache-2.0
|
hacking>=3.0,<3.1.0 # Apache-2.0
|
||||||
|
|
||||||
docutils>=0.11 # OSI-Approved Open Source, Public Domain
|
docutils>=0.11 # OSI-Approved Open Source, Public Domain
|
||||||
sphinx!=1.6.6,!=1.6.7,>=1.6.2,<2.0.0;python_version=='2.7' # BSD
|
sphinx!=1.6.6,!=1.6.7,!=2.1.0,>=1.6.2 # BSD
|
||||||
sphinx!=1.6.6,!=1.6.7,!=2.1.0,>=1.6.2;python_version>='3.4' # BSD
|
openstackdocstheme>=1.31.2 # Apache-2.0
|
||||||
openstackdocstheme>=1.18.1 # Apache-2.0
|
|
||||||
|
8
tox.ini
8
tox.ini
@ -4,11 +4,12 @@ minversion = 1.6
|
|||||||
skipsdist = True
|
skipsdist = True
|
||||||
|
|
||||||
[testenv]
|
[testenv]
|
||||||
|
basepython = python3
|
||||||
usedevelop = True
|
usedevelop = True
|
||||||
install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} {opts} {packages}
|
|
||||||
setenv =
|
setenv =
|
||||||
VIRTUAL_ENV={envdir}
|
VIRTUAL_ENV={envdir}
|
||||||
deps =
|
deps =
|
||||||
|
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
||||||
-r{toxinidir}/requirements.txt
|
-r{toxinidir}/requirements.txt
|
||||||
-r{toxinidir}/test-requirements.txt
|
-r{toxinidir}/test-requirements.txt
|
||||||
|
|
||||||
@ -17,22 +18,20 @@ whitelist_externals = bash
|
|||||||
commands = {toxinidir}/tools/run_bashate.sh
|
commands = {toxinidir}/tools/run_bashate.sh
|
||||||
|
|
||||||
[testenv:docs]
|
[testenv:docs]
|
||||||
basepython = python3
|
|
||||||
commands = sphinx-build -W -d doc/build/doctrees -b html doc/source/ doc/build/html
|
commands = sphinx-build -W -d doc/build/doctrees -b html doc/source/ doc/build/html
|
||||||
|
|
||||||
[testenv:pep8]
|
[testenv:pep8]
|
||||||
basepython = python3
|
|
||||||
commands =
|
commands =
|
||||||
flake8 {posargs}
|
flake8 {posargs}
|
||||||
{toxinidir}/tools/run_bashate.sh
|
{toxinidir}/tools/run_bashate.sh
|
||||||
|
|
||||||
[testenv:venv]
|
[testenv:venv]
|
||||||
basepython = python3
|
|
||||||
commands = {posargs}
|
commands = {posargs}
|
||||||
|
|
||||||
[testenv:buildimage]
|
[testenv:buildimage]
|
||||||
commands = manila-image-create {posargs}
|
commands = manila-image-create {posargs}
|
||||||
deps =
|
deps =
|
||||||
|
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
||||||
-r{toxinidir}/requirements.txt
|
-r{toxinidir}/requirements.txt
|
||||||
|
|
||||||
[testenv:buildimage-docker]
|
[testenv:buildimage-docker]
|
||||||
@ -44,7 +43,6 @@ builtins = _
|
|||||||
exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,tools
|
exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,tools
|
||||||
|
|
||||||
[testenv:lower-constraints]
|
[testenv:lower-constraints]
|
||||||
basepython = python3
|
|
||||||
deps =
|
deps =
|
||||||
-c{toxinidir}/lower-constraints.txt
|
-c{toxinidir}/lower-constraints.txt
|
||||||
-r{toxinidir}/test-requirements.txt
|
-r{toxinidir}/test-requirements.txt
|
||||||
|
Loading…
Reference in New Issue
Block a user