Skip to content

[18.0][MIG] users_ldap_groups : Migration to v18 - #889

Open
cvinh wants to merge 41 commits into
OCA:18.0from
invitu:18.0-mig-users_ldap_groups
Open

[18.0][MIG] users_ldap_groups : Migration to v18#889
cvinh wants to merge 41 commits into
OCA:18.0from
invitu:18.0-mig-users_ldap_groups

Conversation

@cvinh

@cvinh cvinh commented Jan 19, 2026

Copy link
Copy Markdown
Contributor

No description provided.

dreispt and others added 30 commits January 18, 2026 14:45
Currently translated at 100.0% (26 of 26 strings)

Translation: server-auth-16.0/server-auth-16.0-users_ldap_groups
Translate-URL: https://translation.odoo-community.org/projects/server-auth-16-0/server-auth-16-0-users_ldap_groups/es/
Currently translated at 100.0% (26 of 26 strings)

Translation: server-auth-16.0/server-auth-16.0-users_ldap_groups
Translate-URL: https://translation.odoo-community.org/projects/server-auth-16-0/server-auth-16-0-users_ldap_groups/it/
oh2fih and others added 10 commits January 18, 2026 14:45
res.company.ldap.operator operators should be private methods;
public methods allow arbitrary LDAP queries via JSON-API
Currently translated at 100.0% (26 of 26 strings)

Translation: server-auth-16.0/server-auth-16.0-users_ldap_groups
Translate-URL: https://translation.odoo-community.org/projects/server-auth-16-0/server-auth-16-0-users_ldap_groups/pt_BR/
Co-authored-by: Hpar <raph@hpar.fr>
The group mapping in query mode fails if LDAP returns binary data in any
of the fields. This adds a function that handles such situation by
base64 encoding it.
The new test test_users_ldap_groups_ldap_returns_binary_data covers
the common case where LDAP return binary data in thumbnailPhoto.
@pedrobaeza pedrobaeza changed the title [18.0][MIG] users ldap groups : Migration to v18 [18.0][MIG] users_ldap_groups : Migration to v18 Jan 19, 2026
@pedrobaeza

Copy link
Copy Markdown
Member

/ocabot migration users_ldap_groups

@OCA-git-bot OCA-git-bot added this to the 18.0 milestone Jan 19, 2026
@OCA-git-bot OCA-git-bot mentioned this pull request Jan 19, 2026
23 tasks
@cvinh
cvinh force-pushed the 18.0-mig-users_ldap_groups branch 2 times, most recently from 98ce4bc to 39c9a20 Compare January 19, 2026 02:37
@mcodes-o

Copy link
Copy Markdown

LGTM 👍 , tested migrated module with openldap and it works

Comment thread users_ldap_groups/models/res_users.py Outdated
Comment thread users_ldap_groups/models/res_users.py Outdated
Comment thread users_ldap_groups/tests/test_users_ldap_groups.py Outdated
@cvinh
cvinh force-pushed the 18.0-mig-users_ldap_groups branch from 39c9a20 to 2e57e7f Compare February 20, 2026 18:17
@github-actions

Copy link
Copy Markdown

There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days.
If you want this PR to never become stale, please ask a PSC member to apply the "no stale" label.

@github-actions github-actions Bot added the stale PR/Issue without recent activity, it'll be soon closed automatically. label Jun 21, 2026
@cvinh

cvinh commented Jun 21, 2026

Copy link
Copy Markdown
Contributor Author

@mcodes-o can you approve please so it can be merged ?

@github-actions github-actions Bot removed the stale PR/Issue without recent activity, it'll be soon closed automatically. label Jun 28, 2026
@primes2h

primes2h commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

LGTM 👍 , tested migrated module with openldap and it works

You forgot to approve it. :-)

dinkotom pushed a commit to dinkotom/server-auth that referenced this pull request Sep 7, 2026
- res.users._login is an instance method in Odoo 19 (no db argument,
  no separate cursor) - follow the auth_ldap 19.0 implementation
- res.users.groups_id was renamed to group_ids; use fields.Command
- auth_ldap renamed the model class CompanyLDAP -> ResCompanyLdap (tests)
- res.users.authenticate() no longer takes the database name (tests)
- drop the cursor mocking in tests: login now runs in the current cursor

Based on the 18.0 migration by Cyril Vinh-Tung (Invitu), OCA#889.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
dinkotom pushed a commit to dinkotom/server-auth that referenced this pull request Sep 7, 2026
- res.users._login is an instance method in Odoo 19 (no db argument,
  no separate cursor) - follow the auth_ldap 19.0 implementation
- res.users.groups_id was renamed to group_ids; use fields.Command
- auth_ldap renamed the model class CompanyLDAP -> ResCompanyLdap (tests)
- res.users.authenticate() no longer takes the database name (tests)
- drop the cursor mocking in tests: login now runs in the current cursor
- drop guards for falsy return values: in Odoo 19 both res.users._login
  and res.company.ldap._get_or_create_user raise AccessDenied instead of
  returning False
- simplify the fake LDAP connection in tests (unused stubs)
- add python-ldap to the repository requirements.txt

Based on the 18.0 migration by Cyril Vinh-Tung (Invitu), OCA#889.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.