OCA / web

Odoo web client UI related addons
GNU Affero General Public License v3.0
943 stars 1.89k forks source link

web_widget_bokeh_chart: dependency requires Python 3.8 #2567

Open em230418 opened 1 year ago

em230418 commented 1 year ago

web_widget_bokeh_chart requires bokeh 3.1.1 which cannot be installed in 3.7, while Odoo 16.0's minimal version for python is 3.7

em230418 commented 1 year ago

In https://github.com/OCA/web/pull/2566 I tried to fix this, but payed attention that there is some js file "bokeh 3.1.1" that is used there, so it became more complicated than just fixing "requirements.txt"

CRogos commented 7 months ago

Here is another issue linked to this library when using the enterprise EMail marketing module.

Use an empty database with demo data. 1) Install EMail Marketing 2) Create a mailing according to screenshot 3) Send mailing 4) Some images in the resulting email are missing 5) See also errors in the odoo.log file.

image

2024-02-28 12:21:55,114 4 ERROR c4a8-16-0-master-11989169 odoo.http: Exception during request handling.
Traceback (most recent call last):
File "/home/odoo/src/odoo/odoo/http.py", line 2044, in __call__
response = request._serve_db()
File "/home/odoo/src/odoo/odoo/http.py", line 1633, in _serve_db
return service_model.retrying(self._serve_ir_http, self.env)
File "/home/odoo/src/odoo/odoo/service/model.py", line 133, in retrying
result = func()
File "/home/odoo/src/odoo/odoo/http.py", line 1660, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "/home/odoo/src/odoo/odoo/http.py", line 1774, in dispatch
return self.request.registry['ir.http']._dispatch(endpoint)
File "/home/odoo/src/odoo/odoo/addons/base/models/ir_http.py", line 154, in _dispatch
result = endpoint(**request.params)
File "/home/odoo/src/odoo/odoo/http.py", line 697, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "/home/odoo/src/odoo/addons/web_editor/controllers/main.py", line 171, in export_icon_to_png
boxw, boxh = draw.textsize(icon, font=font_obj)
AttributeError: 'ImageDraw' object has no attribute 'textsize'

The Odoo responded as follow:

This issue comes from a python version mismatch. The normal odoo requirements for v16.0 specify that the Pillow library be 9.4.0 for python3.10; however, you have version 10.1.0 installed on the DB most likely from a dependency in your requirements.txt (users/modules/oca/web/requirements.txt) file.

This file specifies bokeh==3.1.1 which will install Pillow 10.1.0