[19.0][MIG] impersonate_login: Migration to 19.0
Scope
- impersonate_login
Depends on
- None
Summary
- Migration to Odoo 19.0; tests included. No functional changes beyond compatibility.
- History preserved via
git format-patch --keep-subjectfrom upstream/18.0 andgit am -3 --keeponto upstream/19.0. - Commit structure kept clean for review:
- [IMP] pre-commit auto fixes (single commit)
- [MIG] migration to 19.0 (single commit)
Changes (highlights)
- Use
self.env._for translations and lazy placeholders where needed. - Replace deprecated
self._uidwithself.env.uid. - Adapt
mail.threadoverride to 19.0 signature:_message_compute_author(self, author_id=None, email_from=None). - Avoid attribute access on
request.session; usesession.get("impersonate_from_uid"). - Security XML:
res.groupsfield renamed touser_ids. - Manifest: version bumped to
19.0.1.0.0, website points to 19.0 path. - JS: backend user menu integration kept; prettier/eslint auto-fixes applied.
- Tests: resilient on 19.0 runner (no demo data by default) – create demo user and grant required groups (
base.group_user,base.group_partner_manager).
Temporary references
- None
Pre-commit
- Ran locally; auto-fixes committed as a single [IMP] commit.
Tests
- Locally verified with fresh DB using
--test-tags "/impersonate_login". - CI is expected to run pre-commit and the module tests against Odoo 19 and OCB.
Review
- Files changed show the result on top of 19.0. For an easier review, consider commit-by-commit: import history (via am) → [IMP] pre-commit → [MIG] migration.
@legalsylvain Opened a new PR based on the OCA 18.0 → 19.0 migration guidelines: https://github.com/OCA/server-auth/pull/849. It preserves history via format-patch/am from upstream/18.0, with two commits ([IMP] pre-commit auto-fixes, [MIG] migration). Please review commit-by-commit. I am closing the previous PR as this current approach looks good.
Hi @legalsylvain, sorry for the late response. I’ve resolved the noted issues and pushed the updates. Thanks for the review! Please let me know if you spot anything else.
All remarks resolved and CI is green. @Kev-Roche @astirpe @mymage mind giving this a second review?
This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖