#3107 Python SSSD Config API deletes an item during iteration
Closed: Fixed None Opened 7 years ago by jhrozek.

This was noted by a downstream reporter:
I ran across the same error on Fedora 24 when my sssd domain didn't match because it wasn't cased properly (eg. EXAMPLE.COM and example.com).

Looking at the lines in the trace, I don't see how it would ever succeed if the the active domains are not configured as it always tries to modify the dictionary as it's being iterated.

/usr/lib/python3.5/site-packages/SSSDConfig/init.py:
1783 configured_domains = self.list_domains()
1784 for dom in domain_dict.keys():
1785 if dom not in configured_domains:
1786 del domain_dict[dom]
1787

A quick fix is to iterate over a copy of the list from domain_dict.keys(), eg:
/usr/lib/python3.5/site-packages/SSSDConfig/init.py:
1784 for dom in list(domain_dict.keys()):


Fields changed

milestone: NEEDS_TRIAGE => SSSD 1.14.2
owner: somebody => lslebodn

Fields changed

patch: 0 => 1
status: new => assigned
version: 1.14.0 => 1.13.4

master:

sssd-1-13:

resolution: => fixed
status: assigned => closed

Metadata Update from @jhrozek:
- Issue assigned to lslebodn
- Issue set to the milestone: SSSD 1.14.2

7 years ago

SSSD is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in SSSD's github repository.

This issue has been cloned to Github and is available here:
- https://github.com/SSSD/sssd/issues/4140

If you want to receive further updates on the issue, please navigate to the github issue
and click on subscribe button.

Thank you for understanding. We apologize for all inconvenience.

Login to comment on this ticket.

Metadata