Skip to content

Commit 36a0501

Browse files
authored
Merge pull request #1717 from pbiering/extend-module-info-list
Extend module info list
2 parents 16ece44 + 0b5dd82 commit 36a0501

File tree

3 files changed

+17
-4
lines changed

3 files changed

+17
-4
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
* Test: skip bcrypt related tests if module is missing
88
* Improve: relax mtime check on storage filesystem, change test file location to "collection-root" directory
99
* Add: option [auth] type pam by code migration from v1, add new option pam_serivce
10+
* Cosmetics: extend list of used modules with their version on startup
1011

1112
## 3.4.1
1213
* Add: option [auth] dovecot_connection_type / dovecot_host / dovecot_port

radicale/auth/pam.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def __init__(self, configuration) -> None:
4949
if (self._group_membership):
5050
logger.info("auth.pam_group_membership: %s" % self._group_membership)
5151
else:
52-
logger.info("auth.pam_group_membership: (empty, nothing to check / INSECURE)")
52+
logger.warning("auth.pam_group_membership: (empty, nothing to check / INSECURE)")
5353

5454
def pam_authenticate(self, *args, **kwargs):
5555
return self.pam.authenticate(*args, **kwargs)

radicale/utils.py

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Copyright © 2014 Jean-Marc Martins
33
# Copyright © 2012-2017 Guillaume Ayoub
44
# Copyright © 2017-2018 Unrud <unrud@outlook.com>
5-
# Copyright © 2024-2024 Peter Bieringer <pb@bieringer.de>
5+
# Copyright © 2024-2025 Peter Bieringer <pb@bieringer.de>
66
#
77
# This library is free software: you can redistribute it and/or modify
88
# it under the terms of the GNU General Public License as published by
@@ -27,7 +27,13 @@
2727

2828
_T_co = TypeVar("_T_co", covariant=True)
2929

30-
RADICALE_MODULES: Sequence[str] = ("radicale", "vobject", "passlib", "defusedxml")
30+
RADICALE_MODULES: Sequence[str] = ("radicale", "vobject", "passlib", "defusedxml",
31+
"dateutil",
32+
"bcrypt",
33+
"pika",
34+
"ldap",
35+
"ldap3",
36+
"pam")
3137

3238

3339
def load_plugin(internal_types: Sequence[str], module_name: str,
@@ -58,7 +64,13 @@ def packages_version():
5864
versions = []
5965
versions.append("python=%s.%s.%s" % (sys.version_info[0], sys.version_info[1], sys.version_info[2]))
6066
for pkg in RADICALE_MODULES:
61-
versions.append("%s=%s" % (pkg, package_version(pkg)))
67+
try:
68+
versions.append("%s=%s" % (pkg, package_version(pkg)))
69+
except Exception:
70+
try:
71+
versions.append("%s=%s" % (pkg, package_version("python-" + pkg)))
72+
except Exception:
73+
versions.append("%s=%s" % (pkg, "n/a"))
6274
return " ".join(versions)
6375

6476

0 commit comments

Comments
 (0)