Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update pre-migration.py #746

Open
wants to merge 1 commit into
base: 17.0
Choose a base branch
from

Conversation

Weltschmerz-dev
Copy link

First time contributor, hi 👋

Fixes runtime error due to invalid migration script.

Stacktrace:

File "/oca/server-auth/auth_session_timeout/migrations/17.0.1.0.0/pre-migration.py", line 6, in migrate
    env.cr.execute(
    ^^^^^^
  File "/odoo/odoo/odoo/sql_db.py", line 494, in __getattr__
    return getattr(self._obj, name)
           ^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'psycopg2.extensions.cursor' object has no attribute 'cr'

Fixes runtime error due to invalid migration script.
Copy link

@amh-mw amh-mw left a comment

Choose a reason for hiding this comment

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

Code review only. Style coherent with core Odoo 17.0 pre-migrations.

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.

2 participants