← Back to team overview

openerp-india team mailing list archive

[Bug 941837] Re: [6.0] ORM bug : When I duplicate data contains function field is occured exception.

 

** Changed in: openobject-server
       Status: New => Invalid

-- 
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Server.
https://bugs.launchpad.net/bugs/941837

Title:
  [6.0] ORM bug : When I duplicate data contains function field is
  occured exception.

Status in OpenERP Server:
  Invalid

Bug description:
  Hi !

  I found a bug in the ORM on V6. To reproduce it.

  - I want to display create_date field of partner object on customer invoice's view.
  - I created function field on object account_invoice with stored = false.
  - The customer invoice's view has displayed on it but there is a error when i duplicate some customer invoices.

  openerp V6 error:
  " File " /server/bin/osv/orm.py", line 4093, in copy_data
  del data[f]
  KeyError: 'create_date'
  "

  
  It failed because 'create_date' doesn't exist in data

  I fixed it:

  -   elif 'function' in fields[f]:
  +  elif 'function' in fields[f] and f in data:
                  del data[f]

  Can you help me review them?

  Thanks,

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/941837/+subscriptions


References