Flask has been updated in the requirements projects from OpenStack [1].
This has broken some test cases that were mocking the root object
"flask.request".
Instead of mocking the root object, we address the issue by mocking only
the needed methods and attributes. This facilitates the understanding of
the unit test, and also helps people to pin-point problems right away.
[1] https://review.opendev.org/c/openstack/requirements/+/793023
Change-Id: I8703c7d3e69f35ef3e85234c27b4743242111f3d
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: I608d3f55dfa9b6052f92c4fd13f2aae6d714e287
This repo has not been testing lower-constraints at all due to
broken install_command. If you look at any lower-constraints run and
compare the install python packages with lower-constraints, you see
that those are completely different.
This change removes install_command and updates deps in tox.ini to
follow best practices (moving constraints into deps).
It also updates lower-constraints to newer versions.
Remove broken hacking test.
Co-Authored-By: Justin Ferrieu <jferrieu@objectif-libre.com>
Change-Id: I13daab9e53617266beff7053e50779d1f281802c
Switch to openstackdocstheme 2.2.1 and reno 3.1.0 versions. Using
these versions will allow especially:
* Linking from HTML to PDF document
* Allow parallel building of documents
* Fix some rendering problems
Update Sphinx version as well.
Set openstackdocs_pdf_link to link to PDF file. Note that
the link to the published document only works on docs.openstack.org
where the PDF file is placed in the top-level html directory. The
site-preview places the PDF in a pdf directory.
Disable openstackdocs_auto_name to use 'project' variable as name.
Change pygments_style to 'native' since old theme version always used
'native' and the theme now respects the setting and using 'sphinx' can
lead to some strange rendering.
openstackdocstheme renames some variables, so follow the renames
before the next release removes them. A couple of variables are also
not needed anymore, remove them.
See also
http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014971.html
Change-Id: I6be1174686cb1d8f11e8cb4be58c0e739bf0f931
As discussed in https://review.opendev.org/#/c/742477/, this patch
replaces the use of `tz.UTC` with `dateutil.tz.tzutc()`
Also add python-dateutil to requirements.txt, using the same minimum
version as several other OpenStack projects, including nova.
Change-Id: I4da9e8854a571058e48c2f51c1d340bc135cfe2b
We can now use the standard library mock library instead of the third
party one previously needed for py27 compatibility.
Change-Id: Ia8e87cd6a25621a97c876de5422d0c9d0c8dd751
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
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: Ic3a57b513d3646b6931edc6163c2702805d29d57
This replaces the "eventlet" library with "futurist". Futurist does not
require monkey-patching of the standard library, is an openstack project
and is simply an overlay to the python STL in python3, rather than a
partial replacement.
Change-Id: Ib4f3a59377144e1d37028dfc3df77180d79e0c46
This makes the processor run several workers in separate processes by
default, leading to a big performance increase. The maximal number of workers
can be configured. Work items:
* Use cotyledon to spawn several workers.
* Remove eventlet monkey patching and use the "threading" executor for
messaging in order to avoid conflict with cotyledon internal threads.
Story: 2005423
Task: 30447
Change-Id: I7e2a77cb7d68afb87274fb44fb208306c3b32473
This adds a v2 API root to CloudKitty. An example endpoint along with some
developer documentation has been added. The API root is now served with Flask
instead of pecan.
Change-Id: I4ede52dae531631f7fe708400def01bc08a64dec
Story: 2004208
Task: 27717
Task: 27718
Task: 27719
This change adds a basic bandit config for cloudkitty. It can be invoked
by running the tox environment for bandit;
tox -e bandit
These changes also fix potential security issues find during bandit checks.
- binding to all interface: remove useless host_ip option to avoid issue
- hash function issue: switch from sha1 to sha512
- use of exec: can't be removed for moment so using #nosec comment
Change-Id: Iae7d7604457345fe6d482cf48311c9b75fdde947
This adds the ``cloudkitty-status upgrade check`` command to CloudKitty.
For now, this tool checks the storage version and raises a warning in case
v1 is used.
Depends-On: https://review.openstack.org/#/c/615928/
Change-Id: I39dc98fb716392a22765f169e2da0d389b33b941
Story: 2003657
Task: 26124
This adds an InfluxDB backend to v2 storage. It is much more performant than the
gnocchi backend, and adds support for grafana.
In order to avoid making this patch too big, the documentation will be updated
in another patch.
Support for InfluxDB installation in the devstack plugin will also be added in
another patch.
Change-Id: Icaa23acb1a4791aac0dd8afb122d561065193eea
Story: 2001372
Task: 24536
This updates cloudkitty's requirement and setup files in order to use
openstack/requirements for constraints. This will help to avoid dependency
conflicts when cloudkitty is deployed in an openstack context.
Work items:
* Updated requirements.txt, test-requirements.txt and setup.py with the
`update-requirements` tool provided by openstack/requirements.
* Added a lower-constraints.txt file.
* Added the "check-requirements" zuul job template to the CI.
Change-Id: I5aab02374523be83a65c8b7f47f1df5e93b5a3d2