Forum

Benvenuto!

Questo è il forum ufficiale dell'Associazione Odoo Italia. Dopo esserti registrato potrai partecipare ponendo domande o rispondendo a quelle esistenti. Non scordarti di compilare il tuo profilo e consultare le linee guida prima di iniziare a scrivere.

0

Problemi invio email schedulate legate ai permessi

Avatar
db100

da qualche settimana l'invio di ogni mail schedulata non funziona più a causa di questo errore:


The requested operation cannot be completed due to security restrictions. Please contact your system administrator. (Document type: Message, Operation: read) - (Records: [3920], User: 2) 


versione odoo 16


riportato anche qui: https://www.odoo.com/it_IT/forum/assistenza-1/email-delivery-fails-242908

Avatar
Abbandona
2 Risposte
0
Avatar
db100
Migliore risposta

odoo installato on premise. 

a livello di variazioni accessi, non è stato variato nulla e comunque l'utente numero 2 è l'amministratore, quindi dovrebbe avere ogni tipo di accesso. ho anche fatto un giro su access rights etc. ma non mi pare di vedere nulla di anomalo. Dove dovrei controllare ?

ecco il log di errore che vedo in python:

2024-01-30 11:01:46,503 1 ERROR bitnami_odoo odoo.addons.mail.models.mail_mail: failed sending mail (id: 951) due to The requested operation cannot be completed due to security restrictions. Please contact your system administrator.
(Document type: Message, Operation: read) - (Records: [3929], User: 2) Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/api.py", line 983, in get    cache_value = field_cache[record._ids[0]]KeyError: 951
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1136, in __get__    value = env.cache.get(record, self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/api.py", line 990, in get    raise CacheMiss(record, field)odoo.exceptions.CacheMiss: 'mail.mail(951,).attachment_ids'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/api.py", line 983, in get    cache_value = field_cache[record._ids[0]]KeyError: 3929
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1136, in __get__    value = env.cache.get(record, self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/api.py", line 990, in get    raise CacheMiss(record, field)odoo.exceptions.CacheMiss: 'mail.message(3929,).attachment_ids'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1162, in __get__    recs._fetch_field(self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 3156, in _fetch_field    self._read(fnames)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 3236, in _read    self.check_access_rule('read')  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/addons/mail/models/mail_message.py", line 555, in check_access_rule    raise AccessError(odoo.exceptions.AccessError: The requested operation cannot be completed due to security restrictions. Please contact your system administrator.
(Document type: Message, Operation: read) - (Records: [3929], User: 2)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1185, in __get__    self.compute_value(recs)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1344, in compute_value    records._compute_field_value(self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 4187, in _compute_field_value    field.compute(self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 680, in _compute_related    record[self.name] = self._process_related(value[self.related_field.name])  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 5840, in __getitem__    return self._fields[key].__get__(self, type(self))  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 2773, in __get__    return super().__get__(records, owner)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1164, in __get__    record._fetch_field(self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 3156, in _fetch_field    self._read(fnames)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 3236, in _read    self.check_access_rule('read')  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/addons/mail/models/mail_message.py", line 555, in check_access_rule    raise AccessError(odoo.exceptions.AccessError: The requested operation cannot be completed due to security restrictions. Please contact your system administrator.
(Document type: Message, Operation: read) - (Records: [3929], User: 2)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/api.py", line 983, in get    cache_value = field_cache[record._ids[0]]KeyError: 3929
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1136, in __get__    value = env.cache.get(record, self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/api.py", line 990, in get    raise CacheMiss(record, field)odoo.exceptions.CacheMiss: 'mail.message(3929,).attachment_ids'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1162, in __get__    recs._fetch_field(self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 3156, in _fetch_field    self._read(fnames)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 3236, in _read    self.check_access_rule('read')  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/addons/mail/models/mail_message.py", line 555, in check_access_rule    raise AccessError(odoo.exceptions.AccessError: The requested operation cannot be completed due to security restrictions. Please contact your system administrator.
(Document type: Message, Operation: read) - (Records: [3929], User: 2)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/addons/mail/models/mail_mail.py", line 448, in _send    attachments = mail.attachment_ids  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 2773, in __get__    return super().__get__(records, owner)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1187, in __get__    self.compute_value(record)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1344, in compute_value    records._compute_field_value(self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 4187, in _compute_field_value    field.compute(self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 680, in _compute_related    record[self.name] = self._process_related(value[self.related_field.name])  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 5840, in __getitem__    return self._fields[key].__get__(self, type(self))  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 2773, in __get__    return super().__get__(records, owner)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/fields.py", line 1164, in __get__    record._fetch_field(self)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 3156, in _fetch_field    self._read(fnames)  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/models.py", line 3236, in _read    self.check_access_rule('read')  File "/opt/bitnami/odoo/lib/odoo-16.0.post20221115-py3.10.egg/odoo/addons/mail/models/mail_message.py", line 555, in check_access_rule    raise AccessError(odoo.exceptions.AccessError: The requested operation cannot be completed due to security restrictions. Please contact your system administrator.
(Document type: Message, Operation: read) - (Records: [3929], User: 2)2024-01-30 11:01:46,507 1 INFO bitnami_odoo odoo.addons.mail.models.mail_mail: Sent batch 1 emails via mail server ID #1

 


il messagio termina con:


INFO bitnami_odoo odoo.addons.mail.models.mail_mail: Sent batch 1 emails via mail server ID #1 



ma non è vero che l'invio è andato a buon fine 

Avatar
Abbandona
0
Avatar
Alessandro Fiorino
Migliore risposta


L'utente "2" è l'utente con cui fa la login il primo utente creato automaticamente quando si crea il database che si suppone sia l'utenza dell'amministratore di sistema e a cui vengono legate molte attività predefinite. E' stato mica variato qualcosa su quell'utenza di recente ?  

Si potrebbe pensare che sia un'utenza come le altre ma bisogna fare attenzione che toccandone i permessi o disattivandola bisogna prima aggiornare tutto quello che vi era associato.

Odoo 16 online, odoo.sh o installato on-premise ?

Avatar
Abbandona