gunicorn cpu_time_limit setting generates error

Bug #997564 reported by James Jesudason on 2012-05-10
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Odoo Server (MOVED TO GITHUB)
Confirmed
Undecided
OpenERP Publisher's Warranty Team

Bug Description

When setting the gunicorn cpu_time_limit setting in the config file the following error is generated:

2012-05-10 09:11:54,002 14215 ERROR ? gunicorn.error: Error handling request
Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.6/gunicorn/workers/sync.py", line 87, in handle_request
    self.cfg.pre_request(self, req)
  File "/srv/erp-uat.canonical.com/uat/server/openerp/wsgi/core.py", line 505, in pre_request
    resource.setrlimit(resource.RLIMIT_CPU, (cpu_time + config['cpu_time_limit'], hard))
TypeError: unsupported operand type(s) for +: 'float' and 'str'

The config file setting was:
 cpu_time_limit = 180

The code needs to convert the setting from the config file from a string to a float.

Related branches

Changed in openobject-server:
assignee: nobody → OpenERP Publisher's Warranty Team (openerp-opw)
tags: added: maintenance
Xavier ALT (xal-openerp) on 2012-05-23
Changed in openobject-server:
status: New → Confirmed
mistotebe (mistotebe) wrote :

The merge above did not actually resolve the issue, the load() method needs to use the new code, not bypass it modifying the options dictionary directly.

mistotebe (mistotebe) wrote :

Do you think think will get fixed one way or another when 8.0 gets released?

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers