Uninstallation of a module doesn't remove ir_values.

Bug #657331 reported by Marcio Moreira
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Server (MOVED TO GITHUB)
Confirmed
Wishlist
OpenERP's Framework R&D

Bug Description

I have created a few projects and tasks and everything was fine.

But now when I try to open "Project > Project Management > Projects" there is a crash that happens on both web and gtk clients.

OpenERP 6.0dev (brazilian localization). openerp/addons revno 4201.

Environment Information :
System : Linux-2.6.32-24-generic-i686-with-Ubuntu-10.04-lucid
OS Name : posix
Distributor ID: Ubuntu
Description: Ubuntu 10.04.1 LTS
Release: 10.04
Codename: lucid
Operating System Release : 2.6.32-24-generic
Operating System Version : #43-Ubuntu SMP Thu Sep 16 14:17:33 UTC 2010
Operating System Architecture : 32bit
Operating System Locale : pt_BR.UTF8
Python Version : 2.6.5
OpenERP-Client Version : 6.0dev
Last revision No. & ID :Bazaar Package not Found !Traceback (most
recent call last):
  File "/opt/openerp/server/bin/netsvc.py", line 480, in dispatch
    result = ExportService.getService(service_name).dispatch(method,
auth, params)
  File "/opt/openerp/server/bin/service/web_services.py", line 586, in
dispatch
    res = fn(db, uid, *params)
  File "/opt/openerp/server/bin/osv/osv.py", line 57, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/opt/openerp/server/bin/osv/osv.py", line 140, in execute
    res = pool.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/opt/openerp/server/bin/osv/osv.py", line 130, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/opt/openerp/server/bin/osv/orm.py", line 1747, in
fields_view_get
    context)
  File "/opt/openerp/server/bin/addons/base_calendar/
base_calendar.py", line 1780, in get
    meta, context, res_id_req, without_user, key2_req)
  File "/opt/openerp/server/bin/addons/base/ir/ir_values.py", line
221, in get
    res = filter(bool, map(lambda x: _result_get(x, keys),
list(result)))
  File "/opt/openerp/server/bin/addons/base/ir/ir_values.py", line
221, in <lambda>
    res = filter(bool, map(lambda x: _result_get(x, keys),
list(result)))
  File "/opt/openerp/server/bin/addons/base/ir/ir_values.py", line
207, in _result_get
    datas = self.pool.get(model).read(cr, uid, [id], fields, context)
  File "/opt/openerp/server/bin/addons/hr/hr_department.py", line 98,
in read
    res = super(ir_action_window, self).read(cr, uid, select,
fields=fields, context=context, load=load)
  File "/opt/openerp/server/bin/osv/orm.py", line 2974, in read
    result = self._read_flat(cr, user, select, fields, context, load)
  File "/opt/openerp/server/bin/osv/orm.py", line 3126, in _read_flat
    res2 = self._columns[f].get(cr, self, ids, f, user,
context=context, values=res)
  File "/opt/openerp/server/bin/osv/fields.py", line 689, in get
    res = self._fnct(obj, cr, user, ids, name, self._arg, context)
  File "/opt/openerp/server/bin/addons/base/ir/ir_actions.py", line
158, in _views_get_fnc
    modes = act.view_mode.split(',')
AttributeError: 'bool' object has no attribute 'split'

Tags: 6.0 dev project
Revision history for this message
Marcio Moreira (marcio-verdesaine) wrote :

I have added print statements just before the line where the bug is showing up (on ir_actions.py) and got the following:

[2010-10-09 13:36:46,056][verdesaine] INFO:web-service:successful login from 'admin' using database 'verdesaine'
==================================================
act: browse_record(ir.actions.act_window, 1)
act.view_mode: tree,form TYPE: <type 'unicode'>
==================================================
act: browse_record(ir.actions.act_window, 436)
act.view_mode: tree,form TYPE: <type 'unicode'>
==================================================
act: browse_record(ir.actions.act_window, 443)
act.view_mode: tree,form,calendar,graph TYPE: <type 'unicode'>
==================================================
act: browse_record(ir.actions.act_window, 569)
act.view_mode: False TYPE: <type 'bool'>
==================================================
[2010-10-09 13:36:51,292][verdesaine] ERROR:web-services:Uncaught exception
Traceback (most recent call last):
  [ ... ]
  File "/opt/openerp/server/bin/addons/base/ir/ir_actions.py", line 164, in _views_get_fnc
    modes = act.view_mode.split(',')
AttributeError: 'bool' object has no attribute 'split'

Revision history for this message
Marcio Moreira (marcio-verdesaine) wrote :

One more thing. There is NO record with id 569 on ir_act_window table of my database. By the way, I am an absolute beginner on OpenERP.

Changed in openobject-addons:
assignee: nobody → DHS(OpenERP) (dhs-openerp)
Revision history for this message
Dhruti Shastri(OpenERP) (dhs-openerp) wrote :

Hi Marcio,

It looks like you have deleted an action which is related to the Projects.

I have tried here in normal scenario, and it does not happen at all.

We would like to know the list of modules you installed (their sequence as well).

If you haven't modified anything from DB, this could be an error.

Thanks.

Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Hi Marcio,

We have checked in both the client-web and client-gtk.

We dont happen to face the error.

Try with a new DB and fresh code. If still the error persists,we will reopen it.

Thanks.

Changed in openobject-addons:
status: New → Invalid
milestone: none → 6.0
Revision history for this message
Marcio Moreira (marcio-verdesaine) wrote :

Hello DHS,

The only thing I remember changing was uninstalling project_messages module.

After reading your message I reinstalled project_messages and now the Projects page is opening again.

You can read below my modules list (before reinstalling project_messages).

By the way: why the status of this bug has been changed to "invalid"? What does it mean?

Thank you,
Marcio

Nome,Categoria/Nome,Autor,Versão instalada

-----------------------------------------------------------
account,Accounting,OpenERP SA,6.0.1.1

account_accountant,Accounting,OpenERP SA,6.0.1.1

account_analytic_default,Accounting,OpenERP SA,6.0.1.0

account_analytic_plans,Accounting,OpenERP SA,6.0.1.0

account_chart,Accounting,OpenERP SA,6.0.1.1

account_fiscal_position_rule,Accounting,Akretion,6.0.1.1

account_payment,Payment,OpenERP SA,6.0.1.1

account_product_fiscal_classification,Uncategorized,Akretion,6.0.0.1

account_voucher,Accounting,OpenERP SA & Axelor,6.0.1.0

analytic,Projects & Services,OpenERP SA,6.0.1.1

base,Base,OpenERP SA,6.0.1.2

base_action_rule,Others,OpenERP SA,6.0.1.0

base_calendar,Others,OpenERP SA,6.0.1.0

base_setup,Base,OpenERP SA,6.0.1.0

board,Base,OpenERP SA,6.0.1.0

crm,CRM & SRM,OpenERP SA,6.0.1.0

crm_claim,CRM & SRM,OpenERP SA,6.0.1.0

decimal_precision,Others,OpenERP SA,6.0.0.1

delivery,Sales & Purchases,OpenERP SA,6.0.1.0

document,Others,OpenERP SA,6.0.1.1

hr,Human Resources,OpenERP SA,6.0.1.1

hr_expense,Human Resources,OpenERP SA,6.0.1.0

hr_holidays,Human Resources,OpenERP SA & Axelor,6.0.1.5

knowledge,Uncategorized,OpenERP SA,6.0.1.0

l10n_br,Account Charts,OpenERP Brasil,6.0.0.6

l10n_br_data,Localisation,OpenERP Brasil,6.0.0.1

l10n_br_delivery,Localisation,OpenERP Brasil,6.0.0.6

mail_gateway,Mail Service,OpenERP SA,6.0.1.0

mrp,Production,OpenERP SA,6.0.1.1

mrp_jit,Production,OpenERP SA,6.0.1.0

process,Base,OpenERP SA,6.0.1.0

procurement,Production,OpenERP SA,6.0.1.0

product,Inventory Control,OpenERP SA,6.0.1.1

project,Projects & Services,OpenERP SA,6.0.1.1

project_gtd,Projects & Services,OpenERP SA,6.0.1.0

project_mrp,Projects & Services,OpenERP SA,6.0.1.0

purchase,Sales & Purchases,OpenERP SA,6.0.1.1

purchase_analytic_plans,Sales & Purchases,OpenERP SA,6.0.1.0

purchase_requisition,Sales & Purchases,OpenERP SA,6.0.0.1

resource,Projects & Services,OpenERP SA,6.0.1.1

sale,Sales & Purchases,OpenERP SA,6.0.1.0

sale_analytic_plans,Sales & Purchases,OpenERP SA,6.0.1.0

sale_crm,Sales & Purchases,OpenERP SA,6.0.1.0

sale_margin,Sales & Purchases,OpenERP SA,6.0.1.0

stock,Inventory Control,OpenERP SA,6.0.1.1

wiki,Others,OpenERP SA & Axelor,6.0.1.0

wiki_faq,Others,OpenERP SA,6.0.1.0

wiki_quality_manual,Others,OpenERP SA,6.0.1.0

wiki_sale_faq,Others,OpenERP SA,6.0.1.0

Changed in openobject-addons:
status: Invalid → Confirmed
summary: - [6.0dev] Crash on opening Projects page
+ Uninstallation of a module doesn't remove ir_values.
Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Thanks for providing more information Marcio.

Changed in openobject-addons:
milestone: 6.0 → none
affects: openobject-addons → openobject-server
Changed in openobject-server:
assignee: DHS(OpenERP) (dhs-openerp) → nobody
Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

To be double-checked, and perhaps postponed to post-v6

Changed in openobject-server:
assignee: nobody → OpenERP's Framework R&D (openerp-dev-framework)
importance: Undecided → Low
milestone: none → 6.0-rc2
Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

Indeed, currently the uninstallation feature is still beta, and can cause this kind of undesired errors.
We're planning to improve this in the future (after v6.0), but currently the best thing to do if you are unsure about installing a module, is to make a backup of the database before, and restore it immediately after testing the module, if you don't plan to keep it.

Of course this should not be done at all on a production database, but only on test/staging database.

I'm marking this bug as "Wishlist" to keep it in the radar for improvement after v6.0.

Thanks for reporting!

Changed in openobject-server:
importance: Low → Wishlist
milestone: 6.0-rc2 → none
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.