Development notes

If you want to make changes to the StorPool OpenStack integration tools you should consider the information provided below.

Python versions compatibility

  • sp_osi: This module still needs to support Python 3.6 so that it may be used on (for example) Ubuntu 18.04 (Bionic Beaver) with the system Python interpreter.

  • The rest of the Python modules should support Python 3.8 so that the tools can be run using the current version of the Python interpreter bundled with the StorPool software suite.

Using third-party Python libraries

  • sp_osi: this module needs to be self-contained and only use the Python standard library, so that it may be used on any system or in any virtual environment without the need to install additional software.

  • The rest of the Python tools should use common Python libraries such as click, requests, and so on, and also libraries commonly used in other StorPool software such as cfg-diag, sp-variant, or utf8-locale.

Adding a new upstream version to be detected

  1. Add a new record to the defs/components.json file with the new checksum of the driver file.

  2. Mark it as non-outdated if there is no StorPool driver version that should replace it; this means this record is there for detection purposes only, and sp-openstack install should not replace any files.

  3. Mark it as outdated if there is a StorPool driver version to replace it (or if one is being added in the same commit).

Adding a new version of a StorPool driver

  1. Make the changes to the driver file in the drivers/ tree.

  2. Add a new record to the defs/components.json file with the new checksum of the driver file; in most cases, mark it as non-outdated.

  3. Make sure to mark any entries referring to the old version of the file (with the old checksum) as outdated now.

  4. Run the internal validation suite using tox -e validate.

  5. Run the full test suite using Tox: either tox -p all or, tox-stages run when using the tox-stages utility.