Commit Graph

50 Commits

Author SHA1 Message Date
Hasan Acar a24fd834d0 fix: migrate CI to jammy
fix: change tox.ini

fix: change queries for list_dimension_names and list_dimension_values because of influxdb time filter problem

fix: remove build_sphinx group from setup.cfg

fix: handle hashlib security problem

Change-Id: I0d31a8db5ed71c70e7b878ce5e7940e041d0fa43

Change-Id: I6f7066da10e834550cbf0c053c7bf425ac0ead93

Change-Id: If9575aee73d600bbc84fcdf58deb1c57b508d9c2

Change-Id: If515eaeee7539da3ca49997e88785dc65572b334
2024-02-22 14:35:03 +00:00
Hervé Beraud 9cb4a752c0 Add doc/requirements
We need to specify doc requirements in doc/requirements.txt
to avoid problems with the pip resolver [1] for the release team [2][3].

Removing specific doc requirements from test-requirements.txt.

The problem here is that this repos haven't doc/requirements.txt file
and by default in this case zuul will use the test-requirements.txt file
to pull requirements [4].

This requirements file contains extra requirements like flake8 that
collided with those allowed in our job environment and so the new pip
resolver fails to install these requirements and the job exits in error.

This project meet the conditions leading to the bug.

[1] http://lists.openstack.org/pipermail/release-job-failures/2021-January/001500.html
[2] http://lists.openstack.org/pipermail/openstack-discuss/2021-January/019611.html
[3] http://lists.openstack.org/pipermail/openstack-discuss/2021-January/019612.html
[4] https://opendev.org/zuul/zuul-jobs/src/branch/master/roles/ensure-sphinx/tasks/main.yaml#L36

Change-Id: I582c7b1b8008e72f376a24a58ca1ee5ac4d933bb
2021-01-07 13:18:06 +01:00
Andreas Jaeger 7abc95f1e3 Switch to newer openstackdocstheme and reno versions
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.

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: Ia65588ae734c6995c060332e5198afb95b105084
2020-05-21 17:14:23 +02:00
Ghanshyam Mann 33d19614e0 Fix hacking min version to 3.0.1
flake8 new release 3.8.0 added new checks and gate pep8
job start failing. hacking 3.0.1 fix the pinning of flake8 to
avoid bringing in a new version with new checks.

Though it is fixed in latest hacking but 2.0 and 3.0 has cap for
flake8 as <4.0.0 which mean flake8 new version 3.9.0 can also
break the pep8 job if new check are added.

To avoid similar gate break in future, we need to bump the hacking min
version.

- http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014828.html

Change-Id: I1d852752bf3e503561431565345d3bc5d5efb9c5
2020-05-12 19:29:42 -05:00
Zuul 2d8ae05899 Merge "Use unittest.mock instead of third party mock" 2020-04-23 12:30:09 +00:00
Sean McGinnis 3182d90bbf 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: Ib2843c62ff29b269139981f067ae6afcab624799
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-04-23 12:21:44 +02:00
Andreas Jaeger abad342eb2 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
there at all.

Change-Id: I35d848e9af297d3561ea2838a4808166d1c36601
2020-04-22 07:37:55 +00:00
Andreas Jaeger 80b59f7a44 Cleanup py27 support
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:
  * Wheel is not needed for python 3 only repo
  * Some other sections are obsolete
- Update classifiers
- Update requirements, no need for python_version anymore

Change-Id: I906bb9d9465d6e29686bb224c817c86ef7ec3822
2020-04-05 11:35:05 +02:00
Ghanshyam Mann e2789e8a9d [ussuri][goal] Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle.

monasca-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

Depends-On: https://review.opendev.org/#/c/693631/
Change-Id: I5daa9bb079d0373d0e1379d20e98dd5c0880d312
2019-12-10 13:58:58 +01:00
pengyuesheng b5ebea895a Blacklist sphinx 2.1.0 (autodoc bug)
See https://github.com/sphinx-doc/sphinx/issues/6440 for upstream details

Change-Id: I5e798ecc8ee9febfacd7880504ab8f17471fb064
2019-09-26 09:22:54 +00:00
Zuul e27daddcb6 Merge "Bump the openstackdocstheme extension to 1.20" 2019-09-16 17:54:02 +00:00
pengyuesheng aa769d0d69 Bump the openstackdocstheme extension to 1.20
Some options are now automatically configured by the version 1.20:
- project
- html_last_updated_fmt
- latex_engine
- latex_elements
- version
- release.

Change-Id: I89f2de245df7d5393a066d5c225897887978b03e
2019-08-01 10:13:52 +08:00
Martin Chacon Piza 2485e39b53 Merge monasca-common code into the monasca-api
This change copies the code from monasca-common used by the 3
monasca APIs into monasca-api for the Merge-APIs target.

After mergin the APIs the duplicated code can be removed from
monasca-common.

Change-Id: I52d36fad846637baf10516f5cbbedc541d4c2064
Story: 2003881
Task: 30427
2019-07-26 14:08:31 +02:00
akhiljain23 0fae94fac2 Update hacking version to 1.1.x
This commit updates hacking version in test-requirements and
fixes some related pep8 issues

Change-Id: I67d85eb5bef72c38cc5360b5625d6b1c37adb40f
Story: 2004930
Task: 29315
2019-06-20 04:52:24 +00:00
Doug Szumski a9cc4bb482 Add support for using Falcon 2.0.0
Falcon 2.0.0 introduces some breaking changes. The relevant ones here are:

- falcon.testing.TestCase.api property was removed
- falcon.testing.TestBase class was removed

Additionally, the default behaviour for handling trailing slashes on
URIs also changed:

https://falcon.readthedocs.io/en/latest/user/faq.html#how-does-falcon-
handle-a-trailing-slash-in-the-request-path

This commit adds support for using the new release. It currently makes
no effort to be backwards compatible with older releases.

The change also updates the requirements for influxdb and sphinx
libraries to match global requirements.

Until monasca-log-api implementation is not updated to support the new
version of Falcon, `monascalog-python3-tempest` is marked to be
non-voting as agreed in the team meeting.

Story: 2005695
Task: 31015
Change-Id: I03bc8d502a333a7a71d9c12b8ddc7c5dc0a4f588
2019-05-29 16:10:53 +02:00
Chuck Short 7cf608c31d Switch to using stestr
According to Openstack summit session [1] stestr is
maintained project to which all Openstack projects should migrate.

Let's switch it then.

[1] https://etherpad.openstack.org/p/YVR-python-pti

Change-Id: Icaff30a749d68d745191958196a6dbba6352f59c
Signed-off-by: Chuck Short <chucks@redhat.com>
2018-06-29 12:00:48 -04:00
Witold Bedyk a449b1355e Fix lower-constraints job
* bump lower-constraint for cassandra-driver version to 3.3.0
* add cassandra-driver and influxdb to extras
* execute lower-constraints job with python 2.7
* move common commands to [testenv]
* fix lower-constraint for sphinx
* add funcsigs to lower-constraints.txt

Depends-On: https://review.openstack.org/555402
Change-Id: Idc2351e597ce933fa5c83a6c872ae241ce4b0220
2018-04-09 14:15:47 +02:00
OpenStack Proposal Bot e885d0351f Updated from global requirements
Change-Id: I09369eb43c969e7912d3aa4048b932d9ed9bf138
2018-03-15 07:11:47 +00:00
OpenStack Proposal Bot 9a184f3db4 Updated from global requirements
Change-Id: I6d18bbd106583a76056c5c4054b83380558b845e
2018-03-13 07:00:54 +00:00
OpenStack Proposal Bot a6b545486c Updated from global requirements
Change-Id: Ia3cee5025848167427449902681564acd443fa62
2018-03-10 13:21:46 +00:00
OpenStack Proposal Bot dad8336ace Updated from global requirements
Change-Id: Ie2080a7343eca2007e32936a4d20a35ff74414ff
2018-01-27 17:52:28 +00:00
OpenStack Proposal Bot e48ea3ef4c Updated from global requirements
Change-Id: I14b9fe2abae1a2a0d70eb1dd3e87fb6955a49a29
2018-01-24 02:00:29 +00:00
Andreas Jaeger 3e0c307071 Remove obsolete tempest-lib
tempest-lib has been reintegrated into tempest and this repository
already uses tempest instead of tempest-lib. Replace requirements for
tempest-lib with requirements for tempest.

See also
https://specs.openstack.org/openstack/qa-specs/specs/tempest/implemented/reintegrate-tempest-lib.html

Change-Id: I677d4a215000ae662bb981462c7f000653054d9b
2018-01-20 18:30:21 +01:00
OpenStack Proposal Bot 1f1cc2b35a Updated from global requirements
Change-Id: I814d919044536d3d15e6536cab3bcc683bda1199
2018-01-16 04:12:58 +00:00
Sean McGinnis f910660adf Remove mox from requirements
Mox was listed in test-requirements, but it is not actually
used anywhere. Since we want to get rid of this package in
OpenStack, removing from requirements so it does not look
like it is being used.

Change-Id: I066ed8b65e76c41548b1e47b152a67701ba3d4d9
2018-01-09 17:07:05 -06:00
OpenStack Proposal Bot 9644cca421 Updated from global requirements
Change-Id: I222e14d16efd618f6731cd3484fe3f14366e345f
2017-11-20 17:40:17 +00:00
OpenStack Proposal Bot e7e3ed4990 Updated from global requirements
Change-Id: I4c0a3f37ceea460cdc99fd5fd0317735a40273e8
2017-09-20 08:38:54 +00:00
OpenStack Proposal Bot 20d701d97c Updated from global requirements
Change-Id: Iefb5391ccd79ad2aebe1e59f68361bfdc00c6c39
2017-08-18 11:32:46 +00:00
OpenStack Proposal Bot 5acb8357c1 Updated from global requirements
Change-Id: Ide3e9c63f96c3869a75b3bf99fd5e6d4edbe755a
2017-08-18 04:43:20 +00:00
OpenStack Proposal Bot b5ae9ad49c Updated from global requirements
Change-Id: I7d3c03d9a7d931b2ef3f35fb43d9bd706ec49826
2017-08-01 02:56:55 +00:00
Tomasz Trębski 332634f74f Prepare foundation for doc migration
Commit aims at providing the foundation to launch
doc migration for monasca-api:

* api-ref
* releasenotes
* doc

Extra:
* fixed documentation errors to enable codebase documentation

Story: 2001058
Task: 4768

Change-Id: Ic7af65a154dba7e52ffb90d0e6dbf0ae87d5d699
2017-07-31 10:43:49 +00:00
OpenStack Proposal Bot 66756317d5 Updated from global requirements
Change-Id: I4a6e9d069a5425a91bdf537c0543ab8abb0dd723
2017-05-15 12:10:15 +00:00
OpenStack Proposal Bot 6faf403d74 Updated from global requirements
Change-Id: I63ae000473bf1751ceaa8f597f7ec999916be149
2017-04-10 23:10:58 +00:00
OpenStack Proposal Bot 2f2deb08b3 Updated from global requirements
Change-Id: Ifa6cace3cf65fddff72407cb8102bc257e85330d
2017-02-27 05:04:40 +00:00
Jenkins 984e0ab877 Merge "Use them same versions of Influx or Cassandra" 2017-02-24 13:20:19 +00:00
Tomasz Trębski 9d470036f5 [BASHATE] Extended code analysis
Followign code adds linting with bashate to
devstack/plugin.sh

Change-Id: Iec6e82a6ddc8ce4e405196509777c029139b5025
2017-02-16 07:51:46 +00:00
Yushiro FURUKAWA a4fe9f86c5 Use them same versions of Influx or Cassandra
Versions of Influx or Cassandra between tox and devstack
env were different. Now in both places OpenStack requirements
are used.

Additionally:
- moved Influx and Cassandra to test-requirements.

Change-Id: I5be1be023b605a0b7efe718796877b90f9dc06f0
Related-Bug: #1628719
2017-02-16 06:15:16 +00:00
OpenStack Proposal Bot 2a513d739e Updated from global requirements
Change-Id: I308f51995d65dae08b3141f5c0f7ff74a0bd3391
2017-02-08 17:50:12 +00:00
Tomasz Trębski 228c24561b [WIP][BANDIT] Extended code analysis
Following commit enables bandit to analyse
code quality of both API and tempests code

Change-Id: I70e964b7f6afddb79b70416c8d99100bfcc8a379
2017-02-07 10:55:52 +01:00
OpenStack Proposal Bot c1ab9792f6 Updated from global requirements
Change-Id: I1626eb11c0d45e95ae281d93e21555911918d23d
2017-01-16 16:44:50 +00:00
Tomasz Trębski ff0afc968b Migrate test run to ostestr
Instead of running tests with nosetests,
this commit migrates tox.ini to use ostestr
similar to other openstack projects.

Using ostestr, as well testrepository, results
in another useful feature where test results can be
seen in convenient graphical representation.

Additionally:
* added oslo_debug_helper
* extracted unit-like dependencies into external testenv,
that way they are not installed for target where
they are actually not required (like pep8)
* removed testenv:docs because monasca does not come
with sphinx documentation
* removed testenv:genconfig because monasca is not
compatible with supplying its entire configuration
they way oslo-config-generator expects

Change-Id: Ic5bb793847f7ab45731862f4208e94589421f490
2017-01-14 19:47:29 +00:00
OpenStack Proposal Bot 0299565271 Updated from global requirements
Change-Id: I4b238006e1d0c406cc04bdffd2c5532ebd86a69c
2016-10-27 12:15:40 +00:00
OpenStack Proposal Bot 29c6c6f95c Updated from global requirements
Change-Id: I50baa49c8edd8feab768f18d07936a2684c06755
2016-09-01 21:54:46 +00:00
Swapnil Kulkarni (coolsvap) c9af29f98f Remove discover from test-requirements
It's only needed for python < 2.7 which is not supported

Change-Id: Ie0fec1805d4cf4238bfa19f9204aa7d623fcd69f
2016-07-21 10:23:00 +00:00
Andreas Jaeger f612ed71ff Remove sphinx requires from test-requirements
This repository does not have any RST documents and thus building with
sphinx is not supported. Remove the docs requirements, including some dead
requirements.

Change-Id: I9c9ffbfd60dc75bd3bf26d88c57040c69c12799b
2016-03-29 19:50:14 +02:00
oiskam1 0462177fb7 ORM (sqlalchemy) implementation for python
It is sqlalchemy part from proposition of oiskam for python.

Change-Id: I699d87c1cd43fe0ab52aa8ca7044f4d90c8a1ba2
2016-02-27 13:15:53 +01:00
LiuNanke be8ea6c826 Clean up removed hacking rule from [flake8] ignore lists
We bump hacking>=0.10.0, and hacking removed some rules, for
the full list of rules please see [1]. So don't need them any more.

Hacking related commits:
Remove H904 in commit b1fe19ebebe47a36b905d709467f5e82521bbd96
Remove H803 in commit f01ce4fd822546cbd52a0aedc49184bddbfe1b10
Remove H307 in commit ec4833b206c23b0b6f9c6b101c70ab925a5e9c67
Remove H305 in commit 8f1fcbdb9aa4fc61349e5e879153c722195b1233

[1]https://github.com/openstack-dev/hacking/blob/master/setup.cfg#L30

Change-Id: Ia20b3570c1a28b3431a9115599a4a11366489edc
2016-01-24 20:45:08 +08:00
Ryan Brandt 9607e1aabd Add check for restricted characters
Remove placeholder test
Adjust flake8 settings
Add new mock requirements to test-requirements.txt

Change-Id: I8f58341108710b1bc7431154cda096d6583d1ef3
2015-07-14 15:43:46 -06:00
Deklan Dieterly 71c9acb1cc Add alarm history resource
Change-Id: Ic19c09cc0808c994cadfb7e3c7680dd58438852d
2014-11-17 15:38:47 -07:00
Tong Li ed99a4edb3 initial python implementation
Change-Id: I25ca78414cd26340a4a640cb4f9ee92dda650037
2014-09-15 13:18:10 -04:00