odoo v12 EE - error saving file
davidogles opened this issue · 3 comments
I've created a report in Jasper Studio. When I upload the file and click save, I'm getting this error:
File "/odoo/odoo-server/addons/jasper_reports/models/report_xml.py", line 253, in save_file
with open(path, 'wb+') as f:
PermissionError: [Errno 13] Permission denied: '/odoo/odoo-server/addons/jasper_reports/models/..
It's even doing it on the sample reports in the demo folder.
here is my path to java under company setup:
Java Path | /odoo/odoo-server/addons/jasper_reports/java
here is the full error report:
Error:
Odoo Server Error
Traceback (most recent call last):
File "/odoo/odoo-server/odoo/http.py", line 656, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/odoo/odoo-server/odoo/http.py", line 314, in _handle_exception
raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
File "/odoo/odoo-server/odoo/tools/pycompat.py", line 87, in reraise
raise value
File "/odoo/odoo-server/odoo/http.py", line 698, in dispatch
result = self._call_function(**self.params)
File "/odoo/odoo-server/odoo/http.py", line 346, in _call_function
return checked_call(self.db, *args, **kwargs)
File "/odoo/odoo-server/odoo/service/model.py", line 97, in wrapper
return f(dbname, *args, **kwargs)
File "/odoo/odoo-server/odoo/http.py", line 339, in checked_call
result = self.endpoint(*a, **kw)
File "/odoo/odoo-server/odoo/http.py", line 941, in call
return self.method(*args, **kw)
File "/odoo/odoo-server/odoo/http.py", line 519, in response_wrap
response = f(args, **kw)
File "/odoo/odoo-server/addons/web/controllers/main.py", line 962, in call_kw
return self._call_kw(model, method, args, kwargs)
File "/odoo/odoo-server/addons/web/controllers/main.py", line 954, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "/odoo/odoo-server/odoo/api.py", line 747, in call_kw
return _call_kw_model_create(method, model, args, kwargs)
File "/odoo/odoo-server/odoo/api.py", line 727, in _call_kw_model_create
result = method(recs, args, **kwargs)
File "", line 2, in create
File "/odoo/odoo-server/odoo/api.py", line 430, in _model_create_single
return create(self, arg)
File "/odoo/odoo-server/addons/jasper_reports/models/report_xml.py", line 203, in create
return super(ReportXml, self).create(values)
File "", line 2, in create
File "/odoo/odoo-server/odoo/api.py", line 430, in _model_create_single
return create(self, arg)
File "/odoo/enterprise/addons/web_studio/models/studio_mixin.py", line 19, in create
res = super(StudioMixin, self).create(vals)
File "", line 2, in create
File "/odoo/odoo-server/odoo/api.py", line 451, in _model_create_multi
return create(self, [arg])
File "/odoo/odoo-server/odoo/addons/base/models/ir_actions.py", line 59, in create
res = super(IrActions, self).create(vals_list)
File "", line 2, in create
File "/odoo/odoo-server/odoo/api.py", line 452, in _model_create_multi
return create(self, arg)
File "/odoo/odoo-server/odoo/models.py", line 3560, in create
records = self._create(data_list)
File "/odoo/odoo-server/odoo/models.py", line 3684, in _create
for other, data in pycompat.izip(others, data_list)
File "/odoo/odoo-server/odoo/fields.py", line 2481, in create
flush()
File "/odoo/odoo-server/odoo/fields.py", line 2444, in flush
comodel.create(vals_list)
File "", line 2, in create
File "/odoo/odoo-server/odoo/api.py", line 433, in _model_create_single
return self.browse().concat((create(self, vals) for vals in arg))
File "/odoo/odoo-server/odoo/api.py", line 433, in
return self.browse().concat((create(self, vals) for vals in arg))
File "/odoo/odoo-server/addons/jasper_reports/models/report_xml.py", line 70, in create
result.report_id.update()
File "/odoo/odoo-server/addons/jasper_reports/models/report_xml.py", line 235, in update
path = self.save_file(file_name, content)
File "/odoo/odoo-server/addons/jasper_reports/models/report_xml.py", line 253, in save_file
with open(path, 'wb+') as f:
PermissionError: [Errno 13] Permission denied: '/odoo/odoo-server/addons/jasper_reports/models/../custom_reports/sale_order_report.jrxml'
@davidogles did you make sure this file has permission?