Skip to content

[autobackport: sssd-2-10] Tests: Update LdapOperations to fail on bind immediately#8748

Merged
spoore1 merged 1 commit into
SSSD:sssd-2-10from
sssd-bot:SSSD-sssd-backport-pr8740-to-sssd-2-10
Jun 13, 2026
Merged

[autobackport: sssd-2-10] Tests: Update LdapOperations to fail on bind immediately#8748
spoore1 merged 1 commit into
SSSD:sssd-2-10from
sssd-bot:SSSD-sssd-backport-pr8740-to-sssd-2-10

Conversation

@sssd-bot

Copy link
Copy Markdown
Contributor

This is an automatic backport of PR#8740 Tests: Update LdapOperations to fail on bind immediately to branch sssd-2-10, created by @jakub-vavra-cz.

Please make sure this backport is correct.

Note

The commits were cherry-picked without conflicts.

You can push changes to this pull request

git remote add sssd-bot git@github.com:sssd-bot/sssd.git
git fetch sssd-bot refs/heads/SSSD-sssd-backport-pr8740-to-sssd-2-10
git checkout SSSD-sssd-backport-pr8740-to-sssd-2-10
git push sssd-bot SSSD-sssd-backport-pr8740-to-sssd-2-10 --force

Original commits
9df13ca - Tests: Update LdapOperations to fail on bind immediately

Backported commits

  • ee5cac4 - Tests: Update LdapOperations to fail on bind immediately

Original Pull Request Body

Summary

  • fail fast in LdapOperations.__init__ when LDAP bind fails, raising LdapException instead of keeping a tuple in self.conn
  • initialize LDAP using self.uri so optional custom port values are honored
  • avoid later misleading runtime errors such as 'tuple' object has no attribute 'modify_s' and surface the real bind problem early

@sssd-bot sssd-bot requested a review from spoore1 May 29, 2026 12:45

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the LDAP initialization in utils.py to use the correct self.uri (which includes the port if specified) instead of the un-ported uri. It also adds error handling to raise an LdapException if the connection binding fails and returns a tuple. There are no review comments, so no additional feedback is provided.

@spoore1 spoore1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. matches other backports and original. test failures not related to code change for multihost tests.

@spoore1 spoore1 added Accepted Tests no-backport This should go to target branch only. labels Jun 12, 2026
Co-authored-by: Cursor <cursoragent@cursor.com>
Reviewed-by: Scott Poore <spoore@redhat.com>
(cherry picked from commit 9df13ca)
@sssd-bot

Copy link
Copy Markdown
Contributor Author

The pull request was accepted by @spoore1 with the following PR CI status:


🟢 CodeQL (success)
🟢 rpm-build:centos-stream-10-x86_64:upstream (success)
🔴 Build / make-distcheck (failure)
🟢 ci / prepare (success)
🔴 ci / system (centos-10) (failure)
🟢 Static code analysis / codeql (success)
🟢 Static code analysis / pre-commit (success)
🟢 Static code analysis / python-system-tests (success)


There are unsuccessful or unfinished checks. Make sure that the failures are not related to this pull request before merging.

@sssd-bot sssd-bot force-pushed the SSSD-sssd-backport-pr8740-to-sssd-2-10 branch from ee5cac4 to b83579a Compare June 12, 2026 22:21
@spoore1 spoore1 merged commit 41827b0 into SSSD:sssd-2-10 Jun 13, 2026
8 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Accepted no-backport This should go to target branch only. Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants