Commit Graph

19 Commits

Author SHA1 Message Date
Brian Rosmaita f165c6ff5e Stop cinderlib development
Remove files from master, as development will no longer occur there.
The stable branches continue to be supported while they are in
Maintained status.

Updated the README to indicate this change.

Depends-on: Ib186ac5830e5920e264d79be946995e63e960426
Depends-on: I081cd363117671eaab6a3193094d5872f9820354
Depends-on: If2b9a82cddb20543b176ee22765049db257c89b9
Depends-on: I1143e5e5ccf8103e386fe1ce614a554e7f152d9a
Change-Id: I4722b869033ad1bd357e36c4a258b6d3ea61f5d6
2024-01-05 16:03:46 +00:00
Brian Rosmaita ab28330d85 Continue 2023.2 (Bobcat) development
As a cycle-with-intermediary release with trailing deliverable type,
cinderlib's master remains the 2023.2 development branch until early
in the 2024.1 (Caracal) cycle when the cinderlib 2023.2 (Bobcat)
release is made.  So update tox.ini and .zuul.yaml to test against
cinder and os-brick stable/2023.2 instead of their master branches,
and restrict cinder and os-brick in requirements.txt to the 2023.2
series.

See the cinderlib docs for more info about this change:
https://docs.openstack.org/cinderlib/latest/contributor/contributing.html#cinderlib-tox-and-zuul-configuration-maintenance

Change-Id: I830b8e2f9766746a7f81b24ce1b7c1f4d4c7c5a1
2023-10-09 15:33:15 +00:00
Stephen Finucane f1af46dc6a persistence: Handle switch to alembic
Change-Id: I02e3fdd7cb16ee420f47eb08ecce983f50d32697
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
2023-09-29 11:18:49 +00:00
Brian Rosmaita 98fc4b6c68 Add sqlalchemy-migrate dependency
It was removed as a cinder dependency by change I39448af0eb8f
but we haven't caught up yet, and are still using it.  Add it
to our requirements as a temporary measure.

Change-Id: I135f0a91ae00b03942a3bf62fea4789e30c06f84
2023-09-27 09:54:42 -04:00
Brian Rosmaita 496ef8dfdb Open cinderlib for 2023.2 (Bobcat) development
See "cinderlib tox and zuul configuration maintenance" in
https://docs.openstack.org/cinderlib/latest/contributor/contributing.html
for an explanation of these changes.

Notes:
- checked, but can't address the TODO in .zuul.yaml yet
- no changes needed for setup.cfg
- py39 testing wasn't required for Antelope, but it is for Bobcat

Change-Id: I4b68ec8594fca14445333143b2852ee122aa6bd6
2023-07-21 09:46:51 -04:00
Brian Rosmaita 18c81f0023 Continue 2023.1 (Antelope) development
As a cycle-with-intermediary release with trailing deliverable type,
cinderlib's master remains the 2023.1 development branch until early
in the 2023.2 (Bobcat) cycle when the cinderlib 2023.1 (Antelope)
release is made.  So update tox.ini and .zuul.yaml to test against
cinder and os-brick stable/2023.1 instead of their master branches,
and restrict cinder and os-brick in requirements.txt to the 2023.1
series.

Change-Id: Id74b4d0e2bad8fa7a3629d85458b089e00a60211
2023-03-30 10:45:16 +00:00
Brian Rosmaita 0c0879a681 Open cinderlib for 2023.1 (Antelope) development
See "cinderlib tox and zuul configuration maintenance" in
https://docs.openstack.org/cinderlib/latest/contributor/contributing.html
for an explanation of these changes.

Change-Id: I68d038a3a64a81e6bd21e65423898d9f5b514234
2022-12-16 10:06:08 -05:00
Brian Rosmaita c722aefb67 Don't limit use of importlib-metadata to Python < 3.8
Change I5febaed02e95 to global-requirements lifted the cap
on importlib-metadata, so we should too.

The cinderlib restriction to py<3.8 was originally made by
change I1709952cf0d0  (merged 28 July 2020).

Change-Id: Ib0397640e524a3d932e71d4c776eca19234c057a
2022-12-14 04:44:10 +00:00
Brian Rosmaita def0c7faa2 Open cinderlib for zed development
NOTE: don't use this patch as an example of "open cinderlib for
xxx development" because it's happening *after* cinder and os-brick
stable/zed have been cut (normally, it would happen before).

In this patch we:
- Switch tox.ini to using stable/zed instead of stable/yoga for
  requirements, cinder, and os-brick
- update .zuul.yaml to use jobs specified by the
  openstack-python3-zed-template
- add a cinderlib-os-brick-src-tempest-lvm-lio-barbican-zed job to
  .zuul.yaml
- update tox.ini to support the current supported python runtimes
  for unit and functional tests plus python 3.10
- update requirements.txt to use only Zed release cinder and os-brick
- update setup.cfg to reflect the Zed supported python runtimes

Co-authored-by: Brian Rosmaita <rosmaita.fossdev@gmail.com>
Co-authored-by: Takashi Kajinami <tkajinam@redhat.com>

Change-Id: I6482088acfaf4c6de436d1a12195e96b3334e906
2022-12-14 04:26:23 +00:00
Gorka Eguileor 4d784d23a9 Fix privsep issues inside virtual env
When a virtual environment is created with the "--system-site-packages"
option and privsep is installed on the system privsep will only use the
system packages and completely ignore the ones in the virtual
environment.

This results in errors such as the ones we see:

- In the Ussuri gate: ModuleNotFoundError: No module named
  'os_brick.privileged.rootwrap'

- In the Wallaby gate: ModuleNotFoundError: No module named
  'os_brick.privileged.nvmeof'

This happens because os-brick and cinder are starting privsep using the
"privsep-helper" mechanism, and privsep was not installed in the virtual
env because it was already present system wide, so the "privsep-helper"
that is executed is the one from "/usr/local/bin/privsep-helper".

This python script "privsep-helper" ignores the virtual environment and
forces usage of the system's python, for example in a Wallaby
installation this could be "#!/usr/bin/python3.6".

Since it ignores the virtual environment it won't use its packages and
anything that's not present on system wide will not be found, and if
found it may be executing different code.

This patch fixes this issue by replacing the helper used to start
privsep with our own command.

This command is the same as the one usually installed in /usr/local/bin
but using /usr/bin/env to select the python to use.

This new script has been included as data in the cinderlib namespace
instead of making it install as a system script (like the original
privsep command) because we don't want to polute the system wide
binaries directory just for a corner case.

We also need to preserve user site-packages for the running Python when
calling root from the virtual environment, since the packages installed
on the virtual environment with "--system-site-packages" would have
taken those into consideration during the installation and not the ones
present on the root user.

To help debug issues at the gate all functional tests are now running
with debug logs.

Change-Id: I0278b42785d14f92a521e6deff872dcba6505270
Related-Bug: #1958159
Closes-Bug: #1979534
2022-06-24 15:26:48 +02:00
Brian Rosmaita 82b8c25c97 Continue yoga development
As a cycle-with-intermediary release with trailing deliverable type,
cinderlib's master remains the yoga development branch until early in
the zed cycle when the cinderlib yoga release is made.  So update
tox.ini to test against cinder and os-brick stable/yoga instead of
their master branches, and restrict cinder and os-brick in
requirements.txt to yoga versions.

Change-Id: I8da1ddc38607eca378a503a961bf55a03566c5bc
2022-03-30 11:32:37 -04:00
Brian Rosmaita 0191f5eb4c Open cinderlib for yoga development
cinderlib is a 'trailing' deliverable type.  The stable/xena
branch has just been cut, so transition master to yoga development.

Depends-on: https://review.opendev.org/c/openstack/releases/+/818392
Change-Id: I7f33a6f8fd903974ef462ac4e8be3e74e8a610a5
2021-12-12 10:54:20 -05:00
Brian Rosmaita e13887ec98 Continue xena development
As a cycle-with-intermediary release with trailing deliverable type,
cinderlib's master remains the xena development branch until its
xena release is made early in the yoga cycle, so update tox.ini so
that it's testing against cinder, brick stable/xena instead of master
branches, and restrict cinder, brick in requirements.txt to their
xena versions.

Change-Id: Icdcaa3330be766e7b94fd1276ffbd024e9e52ad4
2021-12-03 10:54:57 -05:00
Brian Rosmaita 0423c180fd Open cinderlib for xena development
cinderlib is a 'trailing' deliverable type.  The stable/wallaby
branch has just been cut, so transition master to xena development.

Depends-on: https://review.opendev.org/c/openstack/releases/+/797422
Change-Id: Ic6be0596fcc4cef40301702c3bac3085468c8daa
2021-06-29 17:19:36 -04:00
Brian Rosmaita cd0ae51c93 Continue wallaby development
The master branches of cinder and os-brick are now in xena development,
so while cinderlib is still in wallaby development, we want to use
stable/wallaby cinder and stable/wallaby os-brick for testing cinderlib.
Also use stable/wallaby upper constraints.

Change-Id: I9d76b380d18f5a15fb26496b209b3dd8342e4364
2021-04-19 22:13:48 -04:00
Brian Rosmaita f9b2b76e39 Update requirements and lower-constraints
Changes prompted by the new pip resolver doing stricter dependency
checking:
- req, lc: cinder to 17.0.0 (victoria official release)
- lc: os-brick: 2.7.0 -> 4.0.1 (victoria official release)
- lc: stevedore: 1.20.0 -> 1.31.0 (version in victoria cinder l-c)
- update test-req to match cinder stable/victoria versions
- added some indirect dependencies to test-requirements.txt to help
  speed up dependency resolution

This patch is picking up an updated flake8 that is more strict
about import order checking, so we add a per-file-ignore config
option to tox.ini to turn off E402 detection for the affected
files.  See comment in cinderlib/cinder.py for details.  NOTE:
per-file-ignores requires flake8>=3.7.0, but we don't specify
that here because the flake8 version is controlled by hacking.

Change-Id: I6e7fb6724bb29078b2fa70a38f37238c356e6f48
2021-01-13 11:13:28 -05:00
Doug Hellmann 6522756115
drop use of pkg_resources
Importing pkg_resources scans all of the installed modules for data
that won't be used. Switch to using importlib.metdata, which more
efficiently loads the metadata for a package.

Change-Id: I1709952cf0d0329e9b56c20edef50eff1696af22
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2020-07-25 13:08:10 -04:00
Gorka Eguileor 2fec756322 Pin cinder version
Up to cinderlib's version 0.9.0 the library was backward compatible with
older Cinder releases, but version 1.0.0 and higher are no longer
compatible with pre Train Cinder releases, so we need to pin the Cinder
release.

Change-Id: I15944eb67a5628cf2d2983409d767efc6de7608f
Closes-Bug: #1870149
2020-04-01 18:21:44 +02:00
Gorka Eguileor 77f399fd96 Format as a Cinder-related OpenStack project
Since we are going to be importing the project into OpenStack we need it
to follow the same structure as the other projects under the Cinder
umbrella.
2019-02-19 16:28:03 +01:00