c2c-oerpscenario team mailing list archive
-
c2c-oerpscenario team
-
Mailing list archive
-
Message #26427
[Bug 797316] Re: OpenERP v6 (trunk latest version) error with _sql_constraints
*** This bug is a duplicate of bug 790636 ***
https://bugs.launchpad.net/bugs/790636
** This bug has been marked a duplicate of bug 790636
NameError: global name 'db_name' is not defined
--
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/797316
Title:
OpenERP v6 (trunk latest version) error with _sql_constraints
Status in OpenERP Server:
New
Bug description:
I use the following in res.partner
_sql_constraints = [
('ref_uniq', 'unique (ref)', 'Die eingegebene Nummer ist schon vorhanden!'),
]
when test this contraint i get an error
Environment Information :
System : Linux-2.6.35.13-92.fc14.i686-i686-with-fedora-14-Laughlin
OS Name : posix
Operating System Release : 2.6.35.13-92.fc14.i686
Operating System Version : #1 SMP Sat May 21 17:39:42 UTC 2011
Operating System Architecture : 32bit
Operating System Locale : de_DE.UTF8
Python Version : 2.7.0
OpenERP-Client Version : 6.1-dev
Last revision No. & ID :1909 nch@xxxxxxxxxxx-20110614111856-4mgrqyeypbluofin
Traceback (most recent call last):
File "/home/openerp/trunk/server/openerp/netsvc.py", line 427, in dispatch
auth = getattr(self, 'auth_provider', None)
File "/home/openerp/trunk/server/openerp/service/web_services.py", line 579, in dispatch
res = fn(db, uid, *params)
File "/home/openerp/trunk/server/openerp/osv/osv.py", line 133, in wrapper
self.abortResponse(1, _('Constraint Error'), 'warning',
File "/home/openerp/trunk/server/openerp/osv/osv.py", line 117, in _
return tr(src, 'code')
File "/home/openerp/trunk/server/openerp/osv/osv.py", line 106, in tr
cr = sql_db.db_connect(db_name).cursor()
NameError: global name 'db_name' is not defined
In Openerp V6(stable) it works.
To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/797316/+subscriptions
References