crm mail - DATA LOSS - subject truncated to 64 characters

Bug #476354 reported by Ferdinand
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Undecided
Unassigned

Bug Description

openerp-mailgate.py / fetchmail fetches the data but stores the subject into 64 char field regardless of the actual length of the subject

often valuable information gets lost.

as the mail subject propably has no limit in length I suggest to
* change the length of crm_case.name to 256 (done in branch
~openerp-commiter/openobject-addons/chricar_price_unit)
* add the subject at the beginning of the message body if longer than 256 chars (TODO)

Related branches

Revision history for this message
Ferdinand (office-chricar) wrote :

have to
drop view report_crm_case_service_dashboard;
manually -
I know this icould be problem especially if views are used which are not created in openerp modules (as in one db of my clients) and hence would be dropped and not recreated.

[2009-11-06 13:57:58,417] INFO:orm:column 'name' in table 'crm_case' changed size
Traceback (most recent call last):
  File "./openerp-server.py", line 111, in <module>
    pooler.get_db_and_pool(db, update_module=tools.config['init'] or tools.config['update'])
  File "/home/terp/OpenERP/branch/server/5.0/bin/pooler.py", line 40, in get_db_and_pool
    addons.load_modules(db, force_demo, status, update_module)
  File "/home/terp/OpenERP/branch/server/5.0/bin/addons/__init__.py", line 728, in load_modules
    r = load_module_graph(cr, graph, status, report=report)
  File "/home/terp/OpenERP/branch/server/5.0/bin/addons/__init__.py", line 581, in load_module_graph
    init_module_objects(cr, package.name, modules)
  File "/home/terp/OpenERP/branch/server/5.0/bin/addons/__init__.py", line 366, in init_module_objects
    result = obj._auto_init(cr, {'module': module_name})
  File "/home/terp/OpenERP/branch/server/5.0/bin/osv/orm.py", line 1853, in _auto_init
    cr.execute('ALTER TABLE "%s" DROP COLUMN temp_change_size' % (self._table,))
  File "/home/terp/OpenERP/branch/server/5.0/bin/sql_db.py", line 76, in wrapper
    return f(self, *args, **kwargs)
  File "/home/terp/OpenERP/branch/server/5.0/bin/sql_db.py", line 120, in execute
    res = self._obj.execute(query, params)
psycopg2.InternalError: cannot drop table crm_case column temp_change_size because other objects depend on it
HINT: Use DROP ... CASCADE to drop the dependent objects too.

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

Hi Ferdinand,

"psycopg2.InternalError: cannot drop table crm_case column temp_change_size because other objects depend on it!"
>>> This issue has just been solved on stable.

Thank you.

Changed in openobject-addons:
status: New → Confirmed
Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Hello Ferdinand,

Modifying the size of name field to 256 is quite a good idea.
Do we really need subject text to be added? I think no. Users know that and its obvious that decription is the subject.

Your views please.

Thank you.

Revision history for this message
Ferdinand (office-chricar) wrote :

if the mail-subject does not fit into the name field (>256 char) we MUST avoid loosing DATA.
Those who write Emails do not know the length constraint of OpenERP-name field.
If subject >256 then
either copy complete mail subject into text
or only characters >256 , but this needs wordwrap to avoid cut offs in the middle of words.

Changed in openobject-addons:
status: Confirmed → Fix Committed
status: Fix Committed → Fix Released
milestone: none → v6.0
Revision history for this message
Mantavya Gajjar (Open ERP) (mga) wrote :

fixed by revision <email address hidden>

Changed in openobject-addons:
milestone: 6.0 → 5.2
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.