muk-it / muk_misc

MuK Odoo Misc Modules
GNU Lesser General Public License v3.0
20 stars 50 forks source link

muk_mail_branding error when uninstalling #9

Closed gaikaz closed 5 years ago

gaikaz commented 5 years ago

I was having problems uninstalling module muk_mail_branding. Looked in past issues on this repository and this one #4 is exactly the problem I'm having. @keshrath I found a way to reproduce it in a fresh install:

  1. Create a fresh standard database
  2. Install muk_mail_branding
  3. Uninstall muk_mail_branding
  4. Install muk_mail_branding again
  5. Try to uninstall. Should give the error.

Now I know this looks silly, but the point is, that it only uninstalls once. My guess is, it adds some records that don't get removed on uninstall and adds them again on second install, at which point it starts to fail.

Important: I started with a different error: Uncaught Error: ) undefined as prefix when trying to go to Settings > Technical > Scheduled Actions This error starts appearing right after step 3 of the issue reproduction steps described. So simply:

  1. Install the module
  2. Uninstall the module
  3. Go to Settings > Technical > Scheduled Actions

I think these errors are somehow connected. Hope this gives a you a head start on finding the cause. Thank you.

keshrath commented 5 years ago

Thanks for the info. I'll try to test it as soon as I get to it.

keshrath commented 5 years ago

https://github.com/muk-it/muk_misc/commit/206a02a5f05eea110db996c0dce8a9cb1074b277

gaikaz commented 5 years ago

Sorry for delayed response. Now I tested the fixed version with my reproduce steps on a clean install and it is fixed. That's great.

But now I have some DB instances, that have the module installed when it was broken. Even with updated version, the module can't be uninstalled, the "Scheduled actions" page still can't be accessed. I tried clicking "Update" on the modules, but that doesn't help.

Could you give any tips, what could be done on such database? Would somehow manually deleting the mail.ir_cron_module_update_notification record do anything?

Thanks again. Hope this is not too much to ask.