On Няд, 28 вер 2025, Dungan, Scott A. via FreeIPA-users wrote:
Hello.

Running IPA server version 4.12.2-14 on RHEL 9.6, we are seeing the following 
'datetime' Python error when running ipa-healthcheck. I believe this should 
have been patched in 4.12.0, but perhaps it is a different issue?

~]# ipa-healthcheck
[
 {
   "source": "ipahealthcheck.ds.replication",
   "check": "ReplicationCheck",
   "result": "CRITICAL",
   "uuid": "0922227e-9645-487c-aa0c-f94310868abf",
   "when": "20250928174828Z",
   "duration": "1.373418",
   "kw": {
     "exception": "module 'datetime' has no attribute 'UTC'",
     "traceback": "Traceback (most recent call last):\n  File \"/usr/lib/python3.9/site-packages/ipahealthcheck/core/core.py\", line 56, in run_plugin\n    for 
result in plugin.check():\n  File \"/usr/lib/python3.9/site-packages/ipahealthcheck/core/plugin.py\", line 18, in wrapper\n    for result in f(*args, **kwds):\n  File 
\"/usr/lib/python3.9/site-packages/ipahealthcheck/ds/plugin.py\", line 108, in check\n    results = self.doCheck(self.check_class, self.many)\n  File 
\"/usr/lib/python3.9/site-packages/ipahealthcheck/ds/plugin.py\", line 97, in doCheck\n    for result in results:\n  File 
\"/usr/lib/python3.9/site-packages/lib389/_mapped_object_lint.py\", line 126, in lint\n    yield from f()\n  File \"/usr/lib/python3.9/site-packages/lib389/replica.py\", 
line 1325, in _lint_no_ruv\n    ruv_dict = ruv.format_ruv()\n  File \"/usr/lib/python3.9/site-packages/lib389/replica.py\", line 949, in format_ruv\n    \"csn\": 
RUV().parse_csn(self._rid_csn.get(rid, '00000000000000000000')),\n  File \"/usr/lib/python3.9/site-packages/lib389/replica.py\", line 920, in parse_csn\n    time_str = 
datetime.datetime.fromtimestamp(timestamp, datetime.UTC).strftime('%Y-%m-%d %H:%M:%S')\nAttributeError: module 'datetime' has no attribute 'UTC'\n"
   }
 }
]

Judging by the traceback, the problem comes from the lib389 module
provided by the directory server and this particular problem was fixed
upstream recently: https://github.com/389ds/389-ds-base/issues/6838

I think it is not yet in a released 389-ds-base version in RHEL.
https://issues.redhat.com/browse/RHEL-101189

There is even a KCS:
https://access.redhat.com/solutions/7131660

--
/ Alexander Bokovoy
Sr. Principal Software Engineer
Security / Identity Management Engineering
Red Hat Limited, Finland

--
_______________________________________________
FreeIPA-users mailing list -- [email protected]
To unsubscribe send an email to [email protected]
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/[email protected]
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to