Commit Graph

41 Commits

Author SHA1 Message Date
Ghanshyam Mann d791f72d3f Drop lower-constraints.txt and its testing
As discussed in TC PTG[1] and TC resolution[2], we are
dropping the lower-constraints.txt file and its testing.
We will keep lower bounds in the requirements.txt file but
with a note that these are not tested lower bounds and we
try our best to keep them updated.

[1] https://etherpad.opendev.org/p/tc-zed-ptg#L326
[2] https://governance.openstack.org/tc/resolutions/20220414-drop-lower-constraints.html#proposal

Change-Id: Id1033264dea1d8b72ee49e33cc776d5dac6193b9
2022-04-30 20:25:10 -05:00
manchandavishal eb069566f7 Use TOX_CONSTRAINTS_FILE
UPPER_CONSTRAINTS_FILE is old name and deprecated.
This allows to use upper-constraints file as more
readable way instead of UPPER_CONSTRAINTS_FILE=<lower-constraints file>.
For more info. please refer [1].

[1] https://zuul-ci.org/docs/zuul-jobs/python-roles.html#rolevar-tox.tox_constraints_file

Change-Id: I5403b96d4dd0faac9f1295d57a1680a7d452c7b1
2021-02-16 12:32:22 +00:00
wangzihao 6f429c8664 bump py37 to py38 in tox.ini
in 'victoria' cycle, we should test py38 by default.

[1] https://governance.openstack.org/tc/reference/runtimes/victoria.html

Change-Id: Ib2876357e34a802036e686b86f9812d99063b636
2020-12-09 14:07:54 +00:00
Andreas Jaeger f037523797 Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Fix problems found by updated hacking version.

Remove hacking and friends from lower-constraints, they are not needed
for co-installing.

Change-Id: Ibef3bbaceb61612d678c542bc8c95da24a7e2c87
2020-04-01 12:22:43 +00:00
manchandavishal f8d3417d0b Drop Django 1.11 support
Django 1.11 ends its extended support in April 2020 (which is before
Ussuri release), so horizon drops Django 1.11 support in Ussuri.

tox envs for non-primary Django versions are no longer needed in tox.ini
as testing environments for non-primary Django versions are setup in
the zuul jobs now.

horizon>=17.1.0 is required to use Django 2.2. requirements.txt and
lower-constraints.txt are updated accordingly. for more info. please
refer [1].
Depends-On: https://review.opendev.org/#/c/700733/
[1] https://etherpad.openstack.org/p/Enable_Django22_support_in_Horizon_Plugin

Change-Id: I3cd4ad5c3fe590cb1522b2be1b2059d7c70b45cc
2020-01-02 19:40:26 +00:00
Ghanshyam Mann 4e82a8103e [ussuri][goal] Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle.

monasca-ui is ready with python 3 and ok to drop the
python 2.7 support.

Complete discussion & schedule can be found in
- http://lists.openstack.org/pipermail/openstack-discuss/2019-October/010142.html
- https://etherpad.openstack.org/p/drop-python2-support

Ussuri Communtiy-wide goal:
https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html

Depends-On: https://review.opendev.org/#/c/693631/
Change-Id: I47be69fe3b53df70ba775bad342d88129de5ff0a
2019-11-16 16:59:02 +00:00
Zuul a03a976da8 Merge "Use Horizon project template for django jobs" 2019-10-22 09:43:43 +00:00
manchandavishal a3b46a1ab0 Use Horizon project template for django jobs
Horizon defined a project template 'horizon-non-primary-django-jobs'
for django jobs [1]. This patch use that template to run django jobs
here and also fixes the failed test cases for django2.2 support
by adding renederer argument[2] and fix setting.py.

[1] https://review.opendev.org/#/c/681969/

[2] https://docs.djangoproject.com/en/2.1/releases/2.1/#features-removed-in-2-1
Change-Id: Ibe6e1a965179022873630e61529a3318ece7e66b
2019-10-21 07:18:44 +00:00
manchandavishal b95f0873d8 Update the constraints url
For more detail, see http://lists.openstack.org/pipermail/openstack-discuss/2019-May/006478.html

Change-Id: Ie6a63d939165e52afa7f15091a226dcb525a31d8
2019-10-09 17:19:14 +00:00
Corey Bryant f0231ab00f Add Python 3 Train unit tests
This is a mechanically generated patch to ensure unit testing is in place
for all of the Tested Runtimes for Train.

See the Train python3-updates goal document for details:
https://governance.openstack.org/tc/goals/train/python3-updates.html

Change-Id: I8b8ab63cbfe7dced5e1d79d768ee2b8f11a464bb
Story: #2005924
Task: #34223
2019-07-05 13:16:28 -04:00
jacky06 6d1ac152a6 Update hacking version to latest
1. Update hacking version to latest
2. Update some urls to https
3. change the py35 to py36 since py35 is removed

Change-Id: I6de72299d865225ccb522dca8316a024eebe75fd
2019-05-28 18:35:47 +08:00
Zuul b8c3fcd1bc Merge "Dropping the py35 testing" 2019-05-21 15:08:37 +00:00
Ghanshyam Mann df89ad3048 Dropping the py35 testing
All the integration testing has been moved to
Bionic now[1] and py3.5 is not tested runtime for
Train or stable/stein[2].

As per below ML thread, we are good to drop the py35
testing now:
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/005097.html

[1] http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004647.html
[2]
https://governance.openstack.org/tc/reference/runtimes/stein.html
https://governance.openstack.org/tc/reference/runtimes/train.html

Change-Id: I7ea4cb2da696cfa10551f4cab645db6d47de23d9
2019-05-20 15:07:59 +00:00
zhulingjie 9d1f6ea4f0 Replace git.openstack.org URLs with opendev.org URLs
Change-Id: I08632e63eef7cb81f0b3828db69feb9750d65cb5
2019-05-20 14:17:00 +00:00
Sean McGinnis 80ee01d6db Remove setup.py check from pep8 job
Using "python setup.py check -r -s" method of checking the package has
been deprecated with the new recommendation to build the sdist and
wheel, then running "twine check" against the output.

Luckily, there is already a job that covers this that only runs when the
README, setup.py, or setup.cfg files change, making running this in the
pep8 job redundant. This covered by the test-release-openstack-python3
that is defined in the publish-to-pypi-python3 template.

More details can be found in this mailing list post:

http://lists.openstack.org/pipermail/openstack-dev/2018-October/136136.html

Change-Id: I2398ba87d3511338d6092fd8dc3bccb434f49613
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2018-10-30 10:36:34 -05:00
huang.zhiping 402c0847a3 fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: I66b43b70c5ffd077e58e5a5f0e631bd3a0aa080a
2018-08-15 06:41:11 +00:00
Witold Bedyk 36b30a74c1 Fix README.rst and add syntax check
Additionally:
* fix Zuul configuration for lower-constraints job
* raise lower bound for Horizon (due to mox3 removal)
* remove Django from requirements.txt (already included from Horizon)

Change-Id: I44d6cd7477ac0d318705077109b4dc233a5a37d8
Story: 2002163
Task: 24398
2018-08-08 18:04:12 +02:00
Amir Mofakhar e609bd46b0 Update pep8 checks
* set the maximum line length to 100
* cleaned up the codes for pep8
* removed pep8 check ignores

Change-Id: I5d3e2f13117638b0a8af051b9faa64ce1a2dd04e
Signed-off-by: Amir Mofakhar <amofakhar@op5.com>
2018-04-18 16:09:26 +02:00
Zuul 78d764718a Merge "Run lower-constraints job with Python 3" 2018-04-16 08:01:45 +00:00
Witold Bedyk f200f60af1 Run lower-constraints job with Python 3
Change-Id: I1a9c821d2b6d8eccf947bb1fbbd7002bc9b27bc4
2018-04-11 12:01:03 +02:00
Zuul 6b81870164 Merge "add lower-constraints job" 2018-04-11 09:45:01 +00:00
Doug Hellmann b526e21436 add lower-constraints job
Create a tox environment for running the unit tests against the lower
bounds of the dependencies.

Create a lower-constraints.txt to be used to enforce the lower bounds
in those tests.

Add openstack-tox-lower-constraints job to the zuul configuration.

See http://lists.openstack.org/pipermail/openstack-dev/2018-March/128352.html
for more details.

monasca-ui specific changes:
- Unlike other projects, monasca-ui does not support python3 unit tests yet.
  python2.7 is used as basepython. This should be updated to python3 later.
- Bump the the minimum version of python-monascaclient to 1.8.0
  to pass test_client unit tests.
- nose-exclude needs to bumped to 0.5.0 to run all existing unit tests.

lower-constraints.txt is modified to match the latest horizon requirements
https://review.openstack.org/#/c/555491/:
- unit tests fails with Django 1.8. It passes with Django 1.11.
  Horizon Rocky bumped the Django min version to >=1.11, so it makes sense
  to bump the Django min version to 1.11.
- django-babel needs to bumped to 0.6.2 to support Django 1.11 and 2.0.

https://review.openstack.org/555402 allows us to bump lower requirements.

Co-Authored-By: Akihiro Motoki <amotoki@gmail.com>
Change-Id: Ifd967b598db259429cc83046ae88abaf3d50e081
Depends-On: https://review.openstack.org/555034
Depends-On: https://review.openstack.org/555402
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Signed-off-by: Akihiro Motoki <amotoki@gmail.com>
2018-04-10 16:42:22 +00:00
Charles Short 4cfdc71d70 Make monasca-ui python3 compatible
In order to make monasca-ui python3 compatible this
patch set:
- Add six to requirements.txt
- Add py35 to tox.ini
- Replace dict.iteritems() with six.iteritems(dict)
- Replace prit msg with print(msg)
- Replace unicode with six.text_type(msg)
- Replaces urlparse with six.moves.urllib
- Python 3 getting the keys() of a dict returns
  a dict_keys object instead of a list
- python 2.x calling keys makes a copy of the key
  that you can iterate over while modifying the dict.
  This doesn't work in python 3.x because keys
  returns an iterator instead of a list.
  Another way is to use list to force a copy of the keys
  to be made.

Story: 2000975
Task: 4129

Signed-off-by: Charles Short <zulcss@gmail.com>

Change-Id: Ibc644a734edceea0b36f2df2c73300d1e4db925f
2018-03-29 15:53:22 -04:00
Andreas Jaeger cc0af490cf Avoid tox-install.sh
Instead of using tox-install.sh, we can install horizon and neutron
now directly from pypi - or use the current branch in CI system using
tox-siblings.

Update tox.ini for this change and add horizon to requirements file.

Change-Id: Ife02518fce62083661bf06c0fb98e683c5c3d311
2018-03-14 21:08:44 +01:00
Witold Bedyk 361e486753 Fix installing horizon dependency
* copied tox_install from openstack/heat-dashboard
* removed horizon dep from tox.ini

Change-Id: I1066f674065d7a89bff8aaf510dac2684228454e
2018-02-05 09:01:37 +00:00
Tomasz Trębski a7e8a14c2d Add monitoring_policy.json
monasca-ui misses policies file to control the permissions
over actions executed from within Horizon plugin.

Extra:
* enabled running tests with configured policies
* removed unbounded policy sample file

Change-Id: I273f06332fa11a81ea8de2c13059dce9d160e90d
2017-06-19 07:17:44 +02:00
Lukasz Wiecek ef1de7ac3e Add proxy configuration for tox.ini file
Change-Id: I81b78e52aea7df18713d14137a6f3ec33c7c5a37
2017-01-17 13:44:41 +01:00
Jenkins dff5945374 Merge "H305 and H307 hacking have been deprecated" 2017-01-05 08:02:12 +00:00
Jenkins 5b7a90c081 Merge "Add Constraints support" 2017-01-05 06:50:15 +00:00
xhzhf 8623d08a22 H305 and H307 hacking have been deprecated
H305 and H307 hacking have been removed since hacking 0.10.
https://github.com/openstack-dev/hacking/blob/master/setup.cfg
test-requirements of monasca-ui require hacking >=0.12.0,<0.13.
So remove H305/H307 ignore statement
Closes-Bug: #1653596
Change-Id: I5090d1560254b31044e9ab4b72d44da0da6d785f
2017-01-04 19:40:08 +08:00
Dirk Mueller f97c2da088 Add Constraints support
Adding constraints support to clients is slightly more complex than
services as the clients themselves are listed in upper-constraints.txt
which leads to errors that you can't install a specific version and a
constrained version.

This change adds constraints support by also adding a helper script to
edit the constraints to remove monasca-ui.

Change-Id: Ie2f4e3ed3e309b1176ec8bffa5466da25345fd64
2017-01-02 12:30:55 +01:00
xhzhf 1ea265278b H803 hacking have been deprecated
H803 hacking have been removed since hacking 0.10.
https://github.com/openstack-dev/hacking/blob/master/setup.cfg
test-requirements of monasca-ui require hacking >=0.12.0,<0.13.
So remove H803 ignore statement
Closes-Bug: #1650850

Change-Id: Idcc6aa70feb1a3eadbb30e4d0e9187359365e3c2
2016-12-18 10:22:31 +08:00
Dirk Mueller 248fab1d76 Fix local variable is assigned to but never used
Remove assignments to local variable that are not referenced later.
This allows to reenable the corresponding flake8 check to ensure that
we're not regressing later.

Depends-On: I3305775baaab15dca8d5e7e5cfc0932f94d4d153
Change-Id: Id55c8b55ab16fb826cefbaca73a91845c69fcc7b
2016-12-09 21:56:28 +01:00
Dirk Mueller 6584d93491 Remove imported but unused modules
This allows us to enable F401 checks to ensure we're not regressing
on this again.

Change-Id: Ifd94bbaea72afe53daf9291554b68847e7bd34cf
2016-12-09 21:56:28 +01:00
Dirk Mueller 6dc3126ecf Enable pep8 checks on monasca-ui
Effectively all checks except for H236 were disabled on this project.
Switch from whitelist to blacklist approach, blacklist all checks that
are currently failing except for those pure-whitespace related ones. Fix
those.

Depends-On: I3305775baaab15dca8d5e7e5cfc0932f94d4d153
Change-Id: I054d3ef2b98ac6075628d290a93885ec8153c462
2016-12-09 21:56:18 +01:00
gecong1973 a7635f6559 Don't include openstack/common in flake8 exclude list
There is no this directory openstack/common which was used
to keep codes from oslo-incubator, we have retired oslo-incubator.
Removing openstack/commonfrom all OpenStack code in favor of the
Oslo libraries is a project wide goal for the Ocata release. So
don't use this directory any more. We should drop it for improving
searching efficiency.

Change-Id: Id8553d95bef7d2aa9f1f58b549a601bac1a30adf
2016-11-25 11:27:33 +08:00
Ondřej Nový e2e66ba04c Deprecated tox -downloadcache option removed
Caching is enabled by default from pip version 6.0

More info:
https://testrun.org/tox/latest/config.html#confval-downloadcache=path
https://pip.pypa.io/en/stable/reference/pip_install/#caching

Change-Id: I8002d1f029b63eecd3599907b6bc39f889a140d4
2015-12-11 23:05:28 +01:00
Haiwei Xu 814c28b78b Delete python bytecode before every test run
Bring over the cleaning line from run_tests.sh for the pyc files to
all the tox runs.

This should eliminate the need to clean -x -i to kill pyc files in
your local directory to get tests to pass.

Change-Id: I415b7c9ed1c244fb08fc1ce9581e040656c65f09
Closes-Bug: #1368661
2015-12-02 13:36:30 +09:00
Maciej Maciaszek 8861bede7e Simple Kibana integration
* add simple proxy for kibana requests
* organize settings in `local_settings.py`
* narrow down coverage to monitoring package
* fix requirements with stable versions
* upgrade Horizon

Change-Id: I618485e9b6fa11fe423c3b1b3ad5f8c02cc163b4
2015-09-30 13:49:13 +09:00
Piotr Smialkowski 5cb8b8dad8 Fix unittests
- Update horizon version
- Remove --upgrade option in venv installer and tox.ini
- Freeze oslo libs versions

Change-Id: I4b6697cba20699da59af8f9cc7440a669d9f0c6e
2015-07-27 12:07:20 +02:00
cindy oneill a14ccfa390 Add .gitreview and tox.ini files
Change-Id: Ibde9a55f4e3259887aa3961fe6bcdfb595ad59c4
2014-07-16 16:38:33 -06:00