You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The method '_generate_template_recipients' in model 'mail.template' (models/mail_template.py) set a local variable res_id_to_company at the wrong position. Because it assign them in a if and we use it in other block of code.
So it raise this error :
File "/mnt/OCA-social/mail_composer_cc_bcc/models/mail_template.py", line 126, in _generate_template_recipients
record_company = res_id_to_company.get(res_id)
UnboundLocalError: local variable 'res_id_to_company' referenced before assignment
To Reproduce
17.0:
Steps to reproduce the behavior:
Just send an email where variable 'find_or_create_partners' = False
Expected behavior
Normaly, we are able to send email without error
Additional context
The text was updated successfully, but these errors were encountered:
fgenubeo
changed the title
UnboundLocalError: local variable 'res_id_to_company' referenced before assignment
[17.0]mail_composer_cc_bcc : UnboundLocalError: local variable 'res_id_to_company' referenced before assignment
Feb 14, 2025
Module
mail_composer_cc_bcc
Describe the bug
The method '_generate_template_recipients' in model 'mail.template' (models/mail_template.py) set a local variable res_id_to_company at the wrong position. Because it assign them in a if and we use it in other block of code.
So it raise this error :
File "/mnt/OCA-social/mail_composer_cc_bcc/models/mail_template.py", line 126, in _generate_template_recipients
record_company = res_id_to_company.get(res_id)
UnboundLocalError: local variable 'res_id_to_company' referenced before assignment
To Reproduce
17.0:
Steps to reproduce the behavior:
Expected behavior
Normaly, we are able to send email without error
Additional context
The text was updated successfully, but these errors were encountered: