Mail Issue after Update

After updating ubuntu / bench my mail does not work anymore:

File “/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/MySQLdb/connections.py”, line 36, in defaulterrorhandler
raise errorclass, errorvalue
OperationalError: (1054, “Unknown column ‘send_unsubscribe_message’ in ‘field list’”)

Can you share the full trace?

{
“attachments”: [],
“cc”: [
“xxx@softrex.co.za”
],
“communication_name”: “5af4e37587”,
“lang”: “en”,
“print_format”: “”,
“print_html”: “”,
“recipients”: [
“xxx@avis.co.za”
]
}
Traceback (most recent call last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/core/doctype/communication/email.py”, line 421, in sendmail
recipients=recipients, cc=cc)
File “/home/frappe/frappe-bench/apps/frappe/frappe/core/doctype/communication/communication.py”, line 179, in _notify
_notify(self, print_html, print_format, attachments, recipients, cc)
File “/home/frappe/frappe-bench/apps/frappe/frappe/core/doctype/communication/email.py”, line 133, in _notify
prepare_to_notify(doc, print_html, print_format, attachments)
File “/home/frappe/frappe-bench/apps/frappe/frappe/core/doctype/communication/email.py”, line 221, in prepare_to_notify
set_incoming_outgoing_accounts(doc)
File “/home/frappe/frappe-bench/apps/frappe/frappe/core/doctype/communication/email.py”, line 272, in set_incoming_outgoing_accounts
[“email_id”, “always_use_account_email_id_as_sender”, “name”, “send_unsubscribe_message”], as_dict=True) or frappe._dict()
File “/home/frappe/frappe-bench/apps/frappe/frappe/database.py”, line 411, in get_value
ret = self.get_values(doctype, filters, fieldname, ignore, as_dict, debug, order_by, cache=cache)
File “/home/frappe/frappe-bench/apps/frappe/frappe/database.py”, line 453, in get_values
out = self._get_values_from_table(fields, filters, doctype, as_dict, debug, order_by, update)
File “/home/frappe/frappe-bench/apps/frappe/frappe/database.py”, line 584, in _get_values_from_table
conditions, order_by), values, as_dict=as_dict, debug=debug, update=update)
File “/home/frappe/frappe-bench/apps/frappe/frappe/database.py”, line 137, in sql
self._cursor.execute(query, values)
File “/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/MySQLdb/cursors.py”, line 205, in execute
self.errorhandler(self, exc, value)
File “/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/MySQLdb/connections.py”, line 36, in defaulterrorhandler
raise errorclass, errorvalue
OperationalError: (1054, “Unknown column ‘send_unsubscribe_message’ in ‘field list’”)

Did you pull without running bench update or bench migrate ?

The field should be present!

Not that I recall
Can I add the field manually with VI
Or any other method

If you run bench migrate again it should fix it

1 Like