exa.common.helpers.software_version_helper.get_all_software_versions

exa.common.helpers.software_version_helper.get_all_software_versions#

get_all_software_versions(reload_module=False)#

Get all available software version information.

Currently, this function collects all Python package versions and Python interpreter version.

Parameters:

reload_module (bool) –

Whether to reload the pkg_resources module or not. By default, it is disabled because reloading the module is not thread safe! This function should be called with reload_module=True when IPython autoreload is in use.

Example:

  1. You have numpy==1.21.0 installed, and in the notebook you have executed the following IPython magic:

    %load_ext autoreload
    %autoreload 2
    
  2. You install numpy==1.21.1

  3. You call this function with reload_module=False. This will result in some warning printouts and the function will succeed by returning 1.21.0 for numpy, which is wrong because in reality IPython autoreload has reloaded the newly installed numpy 1.21.1. With reload_module=True the correct version 1.21.1 is returned and no warnings are printed.

Return type:

dict[str, str]

Returns: All software components in a dictionary that maps each package name to its version

information. A package’s version information contains the base version, and the string “(local editable)” in the case the package is a local editable installation.