Commit Graph

47 Commits

Author SHA1 Message Date
Cai Hui 3667fb2d6a Dropped the python 3.6/3.7 in zed cycle testing runtime
In Zed cycle, we have dropped the python 3.6/3.7[1] testing
and its support.

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

Change-Id: Ic8cf4bf0ba12043d15e1ff31832f42cc14b3e021
2022-05-15 09:09:05 +08:00
Zuul 6b364fd025 Merge "Updating python testing classifier as per Yoga testing runtime" 2022-05-08 08:53:49 +00:00
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 231c53d9a6 Updating python testing classifier as per Yoga testing runtime
Yoga testing runtime[1] has been updated to add py39
testing as voting. Unit tests update are handled by the
job template change in openstack-zuul-job

- https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/820286

this commit updates the classifier in setup.cfg file.

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

Change-Id: I59a40580f93bf8c133e0492659f2e3364aa71a4d
2021-12-14 02:45:35 +00:00
Cai Hui 92844f55e6 Add python3.9 CI
Add python3.9 CI in tox.ini.

Change-Id: Ida07a13f5dcc152817bf2dd9353ad40f3dc61cbf
2021-11-06 10:01:07 +08:00
caihui 11223563cd Add py38 in tox.
In new release, the project  is used  python38 to replace python37,
so drop py37,add py38 in tox.

Change-Id: Ie08f9bbb98cd21ebace4cc32c6090f2aa249738d
2020-07-01 23:46:40 -07: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
Caihui 6fabbd4a41 Add publish-openstack-docs-pti job in check/gate CI
Add publish-openstack-docs-pti job in check/gate CI.

Change-Id: I8bbad3d615a3af29ed05d31a2e1cb1d3b99ae460
2020-06-24 03:06:40 -07:00
Caihui 6db9afe608 add docs check in tox.ini
Change-Id: I454d94f78c0699fe753f9c2acc72e9c82a52d57e
2020-06-24 00:00:00 -07: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
Zuul 2f53d6fbe6 Merge "Update the constraints url" 2020-04-11 03:02:02 +00:00
Ghanshyam Mann 542dd206ac [ussuri][goal] Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle.

freezer-api 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

Change-Id: I52a67f838e2e92540a9bf409199daa971018d911
2019-11-22 01:53:16 +00:00
caihui 0ed03921fa Update tox.ini
Add py36 in test envlist.

Change-Id: I9dad0cc9aee7a8f35e4759fa10225e0f0883c484
2019-11-04 15:50:18 +08:00
pengyuesheng 9151f71747 Update the constraints url
For more detail, see http://lists.openstack.org/pipermail/openstack-discuss/2019-May/006478.html

Change-Id: I88f8351c39673d8696df3dfa75a929af1bb1003a
2019-09-20 16:44:01 +08:00
Corey Bryant f569115e93 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: I34674301b5a2c13e5f62e06fbe61c32c55ffed06
Story: #2005924
Task: #34207
2019-06-24 09:24:26 -04:00
Cai Hui ba67938413 Add python3.7 unit test job in tox.ini
Add a unit test job running under Python 3.7.

Change-Id: I741c27cf83ca41e27c5c59f2e7ce57bf8a21f1e2
2019-06-05 03:49:03 -04:00
wu.chunyang 8eb00b05f4 Replace git.openstack.org URLs with opendev.org URLs
Thorough replacement of git.openstack.org URLs with their
opendev.org counterparts.

Change-Id: I342dfe342de175f0d52a41a6c9366ce621842053
2019-04-23 18:58:12 +08:00
Ghanshyam Mann 133d5540a8 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: I52a390177356da2e79aac8789a9ef96d57043149
2019-04-14 21:15:46 +00:00
Zuul c6b4c27723 Merge "Add python 3.6 unit test job" 2019-01-28 12:30:55 +00:00
Nguyen Hai Truong 75d4df1480 Add python 3.6 unit test job
This is a mechanically generated patch to add a unit test job running
under Python 3.6 as part of the python3-first goal.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: I02c96a9327e2ccd6c4d5f3f175bb9f507bb026d7
2018-11-06 00:13:17 -08:00
Nguyen Hai Truong 27403cc38e Don't quote {posargs} in tox.ini
Quotes around {posargs} cause the entire string to be combined into one
arg that gets passed to stestr. This prevents passing multiple args
(e.g. '--concurrency=16 some-regex')

Change-Id: If6fec185f98f3b07b4b10c2fa2c701cf352f10ed
2018-11-03 21:25:51 +07:00
Nguyen Hai Truong 75c1b64386 Update min tox version to 2.0
The commands used by constraints need at least tox 2.0.
Update to reflect reality, which should help with local running of
constraints targets.

Change-Id: If3eac65cb0c9d509372992ca642b8054cf84fe33
2018-11-01 23:48:29 -07:00
Cai Hui ca1c83094d Update tox.ini
These specified environment variables doesn't exist in the tox invocation environment.

Change-Id: Ie80a0a911dcb8f312a347b624ee8a4e580b2ab86
2018-10-30 22:52:04 -04:00
Doug Hellmann 85b8aeea0f 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: Ic7138594becaf7061d8b4d0d3fe9bf243fef35af
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-07-12 02:20:37 +00:00
Vu Cong Tuan db4b507bf7 Add py36 testenv
Python 3.6 is installed by default in Ubuntu 18.04 LTS.
Therefore, according to Transition Plan [1],
it'll be handy to have py36 testenv.

For more details, please check Python2 Deprecation Timeline [2]
and Python3-first Goal - Completion Criteria [3].

[1] https://wiki.ubuntu.com/Python/Python36Transition
[2] https://governance.openstack.org/tc/resolutions/20180529-python2-deprecation-timeline.html
[3] https://review.openstack.org/#/c/575933/8/goals/stein/python3-first.rst@42

Change-Id: Ie537f11a4c2fe38a2fcec6d8a29a66c185101d6b
2018-06-27 11:14:20 +07: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
Dai Dang Van 8f3039508a Implement policy in code (1)
This commit will prepare for implementing policies in code[1].

Once we completed moving all of policies into code base,
we can also change default policy rules via policy.yaml
instead of policy.json and generate policy.yaml by command:
$ tox -e genpolicy

[1]https://governance.openstack.org/tc/goals/queens/policy-in-code.html

Change-Id: I587ee663eff9632ec355cef8152c13e1ebfffeb5
Co-authored-By: Hieu LE <hieulq@vn.fujitsu.com>
2017-10-05 14:33:27 +00:00
Saad Zaher a58c0ff018 Remove install-guide from freezer-api
Moved from freezer-api to freezer repo
by I122f2801e6853a2b3c3bc65408b3cec8fe1b555d

Change-Id: I319fdc17b54500d660e8bbef26b3bce5623a0ac7
2017-04-26 17:57:33 +00:00
Vitaliy 2a08aa330f Remove py34 from tox
py34 is unused anymore and needs to be removed from tox.

Change-Id: Ief0810ff64de5b78bc0621399eefdaa76043e6bd
2017-04-05 11:52:06 +00:00
Andreas Jaeger 15233f9bf3 Docs: Various fixes
Treat warnings as errors when building documents to early spot problems.

Fix api-ref set up:
* Add openstackdocstheme for api-ref building instead of oslosphinx and
  configure it properly.
* Setup api-ref log-a-bug correctly for this project.
* Remove unneeded extra install command

Fix install-guide set up:
* Add tox environment

Fix releasenotes set up:
* Fix conf.py settings to build without errors, remove index, we don't
  need it.

fix docs set up:
* Use Sphinx 1.5 warning-is-error option for normal build_sphinx.
* use oslo sphinx
* Remove wrong static path setting

Change-Id: I07ce9db9fdb526ab4b083c65afa99c38bb508146
2017-03-08 21:02:46 +01:00
Saad Zaher d319888ba4 Updated tox.ini
Remove docs from the checks as it has a special gate in Openstack
Remove py34 from the checks
Added py35 to the checks

Change-Id: I1d87289d014e0328c25811373b014d51cb0095b1
2017-02-28 15:51:38 +00:00
Ruslan Aliev cf95fa1e86 Add full pep8 check
This patch adds full pep8 check support. All code style problems
is fixed.

Closes-Bug: #1646103
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Change-Id: I1fce70a1b4e4c70379fc3876f85170b06a044059
2016-12-05 19:57:32 +04:00
Saad Zaher 0ac8349066 Added py35 environment configuration to tox.ini
Change-Id: I02bc1ad73014a18ef7c6e353b1d3adb0ac0fb12e
2016-11-17 14:52:07 +00:00
Saad Zaher 191e7c9844 Added releasenotes for freezer-api
Change-Id: I264ba12975d525e899147fd20f0147ac832117b5
Implements: blueprint maintain-releasenote
2016-10-21 10:16:44 +00:00
Jenkins dc31f044d6 Merge "Delete python bytecode file" 2016-10-14 12:03:28 +00:00
gecong1973 4136fb84df Delete python bytecode file
This patch delete python bytecode including
pyo before every test run

Change-Id: I66dab9551bdde5254e0eb60c5302323c5ae6f5fe
2016-10-12 14:13:05 +08:00
Jeremy Liu 10f69d0ae3 Support upper-constraints in tox.ini
Openstack infra now supports upper constraints for all jobs.
Update tox.ini to use upper constraints for all jobs.

Change-Id: I07ebb152e82b8b1be4892d6da309c73fa3bd33b6
Closes-bug: #1614361
2016-10-10 03:20:41 +00:00
Saad Zaher 977ca7c548 Implemented: Installation documentation and API Ref
integrated freezer-api with openstackdoctheme lib and
os-api-ref lib to build the installation documentation
and api reference for freezer.

Change-Id: Ib5fc5f8227484525a13c3cfff9acb13d2b384e1a
Implements: blueprint implement-install-doc
Implements: blueprint implement-api-ref-doc
2016-09-07 13:20:34 +00:00
Fausto Marzi 8d220b56a7 Switch to testr from pytest
Align to the other Openstack project and
use testr instead of pytest

Includes:
    - pylint and pep8 fixes.
    - py34 compliance
    - requirements updated
    - updated path to dsvm gate job

Change-Id: I10a5ea8d581029eba8f3ab5e016a1dd1919fa117
Depends-On: I4f9050cd551e87d2e398b6f94dc904154d0b1b13
2016-02-28 10:37:21 +00:00
Fausto Marzi e89b5fc80e Add Sphinx doc build
Change-Id: I06391e714c94b2308b2ce20ba503cb5773bf829e
Closes-Bug: #1542061
2016-02-06 21:13:11 +00:00
Fausto Marzi 07dc3d014e Align requirements to liberty global-requirements
Now requirements.txt and test-requirements.txt are
aligned to global-requirements.txt of stable/Liberty.

Testing requirements are now move to test-requirements.txt
from tox.ini

Also the author, author-email and home-page are now update to
reflect Freezer Team and openstack-dev ml.

Change-Id: I27f2ea875778f19d2ffb542b9b8fbf29d1a740fe
2015-11-24 11:42:34 +00:00
Fausto Marzi d55b4c51e5 Added .gitignore .pylintrc, enabled pylint, fixed pylint error
Now the pylint env is enabled in tox.ini. Also .gitignore
and .pylintrc are available part of the repo.

Change-Id: I81078bd95c6aaf8dee2a8d36f0d782a457bd4b94
2015-08-04 22:56:05 +01:00
Fabrizio Vanni 5573da32c0 elasticsearch init script
Adds a script to initialize the mappings of the elasticsearch db
used by the api.

The location of the elasticsearch db server can be provided using
command-line arguments or guessed by the script looking at the
freezer-api configuration file.

The script asks confirmation prior to deleting each of the
elasticsearch types whose mapping needs to be updated,
but it can be instructed to always assume a confirmation to ease
the invocation by scripts or deployment tools.

Change-Id: I0938c7cfde9bae440bf85f536a56079429d772a9
Implements: blueprint freezer-api-db-init
2015-07-15 12:25:34 +01:00
Fabrizio Vanni a389bf79fb freezer scheduler
The freezer scheduler is to be executed
as daemon process on the client machines

It has the following responsibilities:

  * when using the api:
    - register -if necessary- as a client in the api
    - download the list of jobs from the api
    - schedule the jobs for execution
    - launch the freezer client at the scheduled time
    - collect metadata and exit codes and upload them to the api
    - periodically poll the api for new/updated jobs
    - if a job is part of a session (a coordinated group of jobs)
      it updates the session status when job starts/stops

  * when not using the api
    - load jobs configurations from files
    - schedule the jobs for execution
    - launch the freezer client at the scheduled time

The freezer scheduler can also be used to manage jobs
and sessions using the following positional parameters:

  job-list
  job-get
  job-create
  job-delete
  job-start
  job-stop
  session-list
  session-get
  session-create
  session-delete
  session-list-job
  session-add-job
  session-remove-job

or to register the client in the api using the positional parameter:

  register

Implements blueprint: freezer-scheduler-start

Change-Id: I06ae202a0f464f7240c137744a5b54d1177cabd9
2015-07-10 18:51:17 +01:00
Fabrizio Vanni acbc7aefae Freezer API
First implementation of the freezer API.
Slightly more than a skeleton with basic functionality

Change-Id: Iae04affea3aa0f4a943599b528df49d9d4a5b845
Implements: blueprint freezer-api-first-rel
2015-04-08 18:25:45 +01:00