OCA / website

Odoo website builder addons
GNU Affero General Public License v3.0
263 stars 694 forks source link

Website require login error log #990

Open esafocus opened 1 year ago

esafocus commented 1 year ago

Module

website_require_login

Describe the bug

after installing the module, this error appears in the logs, is this normal?

Traceback (most recent call last): File "/opt/odoo/odoo/odoo/api.py", line 794, in get return field_cache[record._ids[0]] KeyError: 1

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/opt/odoo/odoo/odoo/fields.py", line 993, in get value = env.cache.get(record, self) File "/opt/odoo/odoo/odoo/api.py", line 797, in get raise CacheMiss(record, field) odoo.exceptions.CacheMiss: 'website(1,).user_id'

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/opt/odoo/odoo-venv/lib/python3.9/site-packages/werkzeug/serving.py", line 306, in run_wsgi execute(self.server.app) File "/opt/odoo/odoo-venv/lib/python3.9/site-packages/werkzeug/serving.py", line 294, in execute application_iter = app(environ, start_response) File "/opt/odoo/odoo/odoo/service/server.py", line 441, in app return self.app(e, s) File "/opt/odoo/odoo/odoo/service/wsgi_server.py", line 113, in application return application_unproxied(environ, start_response) File "/opt/odoo/odoo/odoo/service/wsgi_server.py", line 88, in application_unproxied result = odoo.http.root(environ, start_response) File "/opt/odoo/odoo/odoo/http.py", line 1298, in call return self.dispatch(environ, start_response) File "/opt/odoo/odoo/odoo/http.py", line 1264, in call return self.app(environ, start_wrapped) File "/opt/odoo/odoo-venv/lib/python3.9/site-packages/werkzeug/middleware/shared_data.py", line 220, in call return self.app(environ, start_response) File "/opt/odoo/odoo/odoo/http.py", line 1489, in dispatch result = ir_http._dispatch() File "/opt/odoo/odoo-custom-addons/oca/website/website_require_login/models/ir_http.py", line 21, in _dispatch if request.uid == website.user_id.id: File "/opt/odoo/odoo/odoo/fields.py", line 2495, in get return super().get(records, owner) File "/opt/odoo/odoo/odoo/fields.py", line 1019, in get recs._fetch_field(self) File "/opt/odoo/odoo/odoo/models.py", line 3072, in _fetch_field self._read(fnames) File "/opt/odoo/odoo/odoo/models.py", line 3139, in _read cr.execute(query_str, params + [sub_ids]) File "", line 2, in execute

File "/opt/odoo/odoo/odoo/sql_db.py", line 100, in check raise psycopg2.OperationalError('Unable to use a closed cursor.') psycopg2.OperationalError: Unable to use a closed cursor. - - -

To Reproduce

Affected versions: 14

ttran293 commented 1 year ago

I'm also seeing this issue after install the module.

ferharo1 commented 8 months ago

The same error happened to me in v14

acevedce-pc commented 2 months ago

any news about this issue??