Skip to content

[16.0][MIG] database_cleanup - #2699

Closed
letzdoo-js wants to merge 52 commits into
OCA:16.0from
letzdoo-js:16.0-mig-database_cleanup
Closed

[16.0][MIG] database_cleanup#2699
letzdoo-js wants to merge 52 commits into
OCA:16.0from
letzdoo-js:16.0-mig-database_cleanup

Conversation

@letzdoo-js

Copy link
Copy Markdown

No description provided.

Stefan Rijnhart and others added 30 commits August 25, 2023 12:48
avoid ''NoneType' object has no attribute 'exists'' error when purging models
fix my change guewen.baconnier@camptocamp.com-20140203103254-v1mzu2uib047xb9h, wrong lines replaced...
    raw SQL query (but never read afterwards). Workaround for
    lp:1277899

[FIX] Preserve dangling workflow table which is in use

[RFR] Group models per table when detecting columns to purge
      to prevent problems with models sharing the same table

[ADD] Allow purging of dangling data entries

[FIX] Data purging now working

[IMP] Docstrings

[FIX] Label
[FIX] Catch attempt to unlink field from nonexisting model

[RFR] Flake8
[CHG] database_cleanup: move description to README.rst
[IMP] order wizard lines by name

[IMP] deal with modules whose models can't be loaded

[IMP] double quotes for docstring

[FIX] use exists query instead of huge in list

[IMP] hide unnecessary buttons in wizard II

[IMP] readability

[FIX] cope with purging nonexisting models
[ADD] test purging modules

[ADD] test purging tables
[FIX] database_cleanup reloads the registry

which has weird side effects during testing. Take care
database_cleanup's tests don't mess up the following tests
* [FIX] database_cleanup: Isolate build
* Isolate `database_cleanup` into its own build in Travis file to fix OCA#689

* [FIX] database_cleanup: Remove KeyError assertion
* Remove KeyError assertion in tests due to PR in comment being merged
* [ADD] allow creating missing indexes

* [FIX] tests; installation

* [ADD] allow purging properties

* [ADD] missing file

* [ADD] test purging properties

* [ADD] missing parent_id for menu entry

* [FIX] don't delete too many and wrong properties
Using new base model inheritance.
[FIX] don't try to uninstall uninstalled modules

[DEL] weird code

[FIX] actually cleanup where we can
Update version number
Use correct import
Update .pot to match new syntax
Adapt icon to fontawesome
Add models description
Rename field external id to new syntax <model>__<field>
To match the new database_cleanup.pot
Following odoo/odoo@54238c88e85d6e a Many2many may have no relation
This avoids having a None record in the list (which is problematic with the
NOT IN clause)
https://wiki.postgresql.org/wiki/Don't_Do_This#Don.27t_use_NOT_IN
@dariodelzozzo

dariodelzozzo commented Sep 6, 2023

Copy link
Copy Markdown

There are already two open migration PRs:
#2684
#2473

Maybe is better to review them instead of opening a new one

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.