Hi Jay,

I tried to reproduce the bug (by adding a rule to the group Employee on
res.partner and opening Sales/Address book/Customers with the demo
user). I got a different error (see below) on the empty case, but no
problem on the [ ] case. Can you give a particular example where you got
that behavior? I have a fix for my case at https://code.launchpad.net
/~openerp-dev/openobject-server/6.0-bug-719406-empty-ir-rule-vmt and
will add fixes for your cases if I can reproduce them.

  File 
"/home/openerp/repos/server/6.0-bug-719406-empty-record-rule/bin/osv/fields.py",
 line 793, in get
    res = self._fnct(obj, cr, user, ids, name, self._arg, context)
  File 
"/home/openerp/repos/server/6.0-bug-719406-empty-record-rule/bin/addons/base/ir/ir_rule.py",
 line 40, in _domain_force_get
    res[rule.id] = eval(rule.domain_force, eval_user_data)
  File 
"/home/openerp/repos/server/6.0-bug-719406-empty-record-rule/bin/tools/safe_eval.py",
 line 240, in safe_eval
    if '__subclasses__' in expr:

-- 
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/719406

Title:
  Record rules with domain blank or [] result in application error

Status in OpenERP Server:
  Confirmed

Bug description:
  1. In v6.0.1, create any record rule with empty domain [].
  2. Log in with user other than admin and pull up any view that invokes above 
rule, following application error will be reported:
    File "C:\Program Files\OpenERP 6.0\Server\addons\base\ir\ir_rule.py", line 
141, in domain_get
    File "osv\orm.pyo", line 3823, in _where_calc
    File "osv\expression.pyo", line 499, in to_sql
  IndexError: pop from empty list

_______________________________________________
Mailing list: https://launchpad.net/~c2c-oerpscenario
Post to     : c2c-oerpscenario@lists.launchpad.net
Unsubscribe : https://launchpad.net/~c2c-oerpscenario
More help   : https://help.launchpad.net/ListHelp

Reply via email to