Commit Graph

18 Commits

Author SHA1 Message Date
Ghanshyam Mann 2b5a26c470 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: Ie267542391366180089979e539c977c8e9f7550f
2022-04-30 15:44:46 -05:00
Ghanshyam Mann e02a492817 [goal] Deprecate the JSON formatted policy file
As per the community goal of migrating the policy file
the format from JSON to YAML[1], we need to do two things:

1. Change the default value of '[oslo_policy] policy_file''
config option from 'policy.json' to 'policy.yaml' with
upgrade checks.

2. Deprecate the JSON formatted policy file on the project side
via warning in doc and releasenotes.

Also replace policy.json to policy.yaml ref from doc.

[1]https://governance.openstack.org/tc/goals/selected/wallaby/migrate-policy-format-from-json-to-yaml.html

Change-Id: I066488c47e1bb6502b27b8677988113f66b9b09b
2021-03-08 19:52:30 -06:00
caihui 34641efcf5 Fix pylint error
Use pylint = 2.6.0 , fix some errors.

Change-Id: I1fdb40c7a8ac986332e10b642ab86799fc5ff78d
2021-01-24 17:55:32 -08:00
Ghanshyam Mann d5d279232b [goal] Migrate testing to ubuntu focal
As per victoria cycle testing runtime and community goal[1]
we need to migrate upstream CI/CD to Ubuntu Focal(20.04).

Fixing:
- bug#1886298
Bump the lower constraints for required deps which added python3.8 support
in their later version.

Depends-On: https://review.opendev.org/#/c/743085/

[1] https://governance.openstack.org/tc/goals/selected/victoria/migrate-ci-cd-jobs-to-ubuntu-focal.h>

Change-Id: I482ac98bc56f0e3cfb8b767f47649da11ed1afab
Story: #2007865
Task: #40184
2020-09-22 18:17:32 +00:00
caihui 11dfa6a003 Use setstr to execute unittest test
The stestr[1] is parallel Python test runner designed to execute unittest test suites using multiple processes.
Test cases can be executed faster.

[1]https://github.com/mtreinish/stestr

Change-Id: Ic0b210685535f94a70a175385afdd9f399f4d690
2020-07-01 21:00:10 -07:00
Hervé Beraud 2693844836 Cap jsonschema 3.2.0 as the minimal version
Previous versions of jsonschema (<3.2.0) doesn't support python 3.8 [1].
Python 3.8 is part of the victoria supported runtimes [2] so we now force
to use jsonschema version 3.2.0 to avoid issues, remove ambiguity and ensure
that everything works with python 3 in general.

[1] https://github.com/Julian/jsonschema/pull/627
[2] https://governance.openstack.org/tc/reference/runtimes/victoria.html#python-runtimes-for-victoria

Change-Id: Ic13321bffe2f7af9324b580bb0e769ce244025a9
2020-05-26 21:48:30 +02:00
jacky06 746c97b85b tox: Keeping going with docs
Sphinx 1.8 introduced [1] the '--keep-going' argument which, as its name
suggests, keeps the build running when it encounters non-fatal errors.
This is exceptionally useful in avoiding a continuous edit-build loop
when undertaking large doc reworks where multiple errors may be
introduced.

[1] https://github.com/sphinx-doc/sphinx/commit/e3483e9b045

Change-Id: I582af8ad8f9a6b05f5a245a155b87be6e2d63874
2020-04-29 09:25:28 +08:00
Andreas Jaeger 11a19f2ea8 Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Fix problems found.

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

Change-Id: Ibc3b00aca7332f12b58893213acfc88749b74aa1
2020-04-14 20:09:03 +02:00
Andreas Jaeger f5332fd0d1 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
- Add requires on python >= 3.6 to setup.cfg so that pypi and pip
  know about the requirement
- Remove obsolete sections from setup.cfg
- Update classifiers
- Update requirements, no need for python_version anymore
- Switch to using sphinx-build. Remove extra build step
  from docs build - api-ref is build separate.
- Cleanup doc/source/conf.py to remove now obsolete content.
- Use newer openstackdocstheme version
- Remove install_command from tox.ini, the default is fine

Change-Id: I7bb95a8ebd7023046baae30595159254bac25690
2020-04-13 16:41:33 +02:00
jacky06 114f91f39c Use unittest.mock instead of third party mock
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.

Change-Id: I749d6ebdef9163ffa3135778a4accbb8be5ba9e3
2020-04-10 22:03:44 +08:00
Michal Arbet 2a283bf34a Fix freezer-api's src_file to path_to_backup
Freezer-api is not working as it is expected, returning NULL value
for src_file option in freezer_action's json returned from API.

In other words when user define action via freezer client and define
valid and WORKING action JSON with option path_to_backup
(src_file is not supported by freezer-agent anymore).

In DB we can see backup_metadata is filled correctly,
freezer-scheduler/freezer-agent working correctly as they are reading
backup_metadata. Problem is that API is still returning json with
src_file set tu NULL because src_file is not present in backup_metada,
therefore is not filled in src_file column in action table.

Src_file option was changed to path_to_backup in freezer git repository
below, but API was never changed, this patch is fixing this behaviour.

Freezer's change :
c7f71ff70b

Doc changes in freezer:
https://review.opendev.org/#/c/705003/

Change-Id: I9e74910bd0ff4ad18b830c26ce90770b0dfa107b
2020-01-31 11:45:39 +01:00
caihui 729bcfaf6b Remove six usage from freezer_api package
We don't support Python 2 anymore so we don't need this
compatibility library.
Convert six usage to Python3 code.

Change-Id: Iadf47e805c8d0dd32239456e69d8fdc78f77f30d
2020-01-22 02:14:39 -08:00
Sean McGinnis d2768ec7a4 Switch to openstackdocstheme
oslosphinx theme is being retired as it is not compatible with the
recent Sphinx 2.0 release. This switches docs and release notes to use
the openstackdocstheme instead.

Change-Id: Ifc544d5d4ca9389a3a73d95397c6489fcab9d509
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2019-04-04 09:30:45 -05:00
Thomas Bechtold 6d37fa9940 Drop astroid requirement
It is not needed.

Change-Id: Ia1851f2e162c7bf024349c17629cbaf70ea925cd
2019-01-04 11:37:52 +01:00
gengchc2 976347c84a Add migrations unit test for sqlalchemy
Change-Id: Ia4e1117da8339fee1a6b2ea62068a104f4d82865
2018-12-11 00:32:56 +00:00
whoami-rajat 88ce38ca10 Add freezer-manager-status upgrade check command framework
This adds basic framework for freezer-manager-status upgrade
check commands. For now it has only "check_placeholder"
check implemented.
Real checks can be added to this tool in the future.

Change-Id: I21d4c7ff5e659b332d6692352d996b3216b56bc9
Story: 2003657
Task: 26129
2018-10-29 01:33:41 +00:00
Doug Hellmann fc4fb5adc4 update pylint to 1.9.2
The older version of pylint being used does not work correctly under
python 3. In order to be able to update the pylint job to run under
python 3, we need to update the tool.

This patch updates to the latest version at this time. It also updates
and pins astroid, which was previously capped. Using a pin instead of
a cap should let us avoid issues with new releases while being
specific about which version to actually use.

This patch also fix lower-constraints.

Co-Authored-By: Nguyen Hai <nguyentrihai93@gmail.com>
Change-Id: I6443247ab110dc9d5e71d23dc40ceabb439e23be
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-07-09 21:58:03 +09:00
Doug Hellmann c7ea534063 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.

Change-Id: I4a1b65911b7ee094dc3b654e0655a7e633c6819c
Depends-On: https://review.openstack.org/555034
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-03-22 12:29:14 -04:00