Branch: refs/heads/master
Home:
https://github.com/tribe29/checkmk
Commit: 1d01fa3bcfabfa2f92e4e7ecc6149422027b208b
https://github.com/tribe29/checkmk/commit/1d01fa3bcfabfa2f92e4e7ecc61494220…
Author: Lars Michelsen <lm(a)tribe29.com>
Date: 2021-12-09 (Thu, 09 Dec 2021)
Changed paths:
A tests/unit/cmk/utils/test_plugin_loader.py
Log Message:
-----------
Add tests for cmk.utils.plugin_loader
Change-Id: I8d2bf72e1d3136e74253375115dc6ef037145c11
Commit: fb850af9c38b2de44a3fd228535b52c1e7c39f1c
https://github.com/tribe29/checkmk/commit/fb850af9c38b2de44a3fd228535b52c1e…
Author: Lars Michelsen <lm(a)tribe29.com>
Date: 2021-12-09 (Thu, 09 Dec 2021)
Changed paths:
M cmk/utils/plugin_loader.py
M tests/unit/cmk/utils/test_plugin_loader.py
Log Message:
-----------
Fix walking of nested packages
Walking nested packages did not work as expected because
we missed to provide the `prefix` argument.
The doc string of `pkgutil.walk_packages` is actually a bit misleading.
Because it says "prefix is a string to output" one could understand it
to be only relevant for the data structures reported.
But when `pkgutil.walk_packages` comes across packages, it also uses
the `prefix` in it's internal imports.
Once setting `prefix`, the recursion works as expected.
Change-Id: Idb6c09497f021caf30515477058d4f5099dd401a
Commit: d187895bbba8c755fbb177d79fa041f72dc91321
https://github.com/tribe29/checkmk/commit/d187895bbba8c755fbb177d79fa041f72…
Author: Lars Michelsen <lm(a)tribe29.com>
Date: 2021-12-09 (Thu, 09 Dec 2021)
Changed paths:
M cmk/gui/utils/__init__.py
M cmk/utils/plugin_loader.py
M tests/unit/cmk/utils/test_plugin_loader.py
Log Message:
-----------
plugin_loader: Improve import error handling
pkgutil.walk_packages suppresses ImportError exceptions by default,
which is some kind of surprising. We now collect the import errors
and report them back to the caller in the same way as we do for
other types of exceptions.
Change-Id: Ib66625590491853861bd26a02edd7041930a76aa
Commit: 57b25b05c2aff57bfd517da7056c10d4b73f98f5
https://github.com/tribe29/checkmk/commit/57b25b05c2aff57bfd517da7056c10d4b…
Author: Lars Michelsen <lm(a)tribe29.com>
Date: 2021-12-09 (Thu, 09 Dec 2021)
Changed paths:
M cmk/utils/plugin_loader.py
M tests/unit/cmk/utils/test_plugin_loader.py
Log Message:
-----------
Plugin loader: Fix handling of PEP420 namespace packages
We used `pkgutil.walk_packages` before, but that was not able to
correctly detect and walk into PEP420 implicit namespace packages.
See also:
https://stackoverflow.com/questions/41203765/init-py-required-for-pkgutil-w…
Change-Id: If91fcdabeea8f4b751c985f49722cc4123f6316c
Compare:
https://github.com/tribe29/checkmk/compare/7da5bf4e6766...57b25b05c2af