What is the problem?
After updating OctoPrint to 1.4.0, the SMS Notifier plugin fails.
What did you already try to solve it?
Reboot the server.
Logs
I can provide more, but this seems to be the relevant parts of the logs.
Before the update:
2020-03-10 03:27:56,167 - octoprint.server - INFO - OctoPrint 1.3.12
2020-03-10 03:27:56,190 - octoprint.plugin.core - INFO - 18 plugin(s) registered with the system:
| Action Command Prompt Support (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/action_command_prompt
| python:
| pip: 19.3.1
| version: 2.7.16
2020-03-10 22:00:49,021 - octoprint.printer.standard.job - INFO - Print job done - origin: local, path: monsterHP_tray_0.2mm_PLA_MK3S_2h59m.gcode, owner: egburr
2020-03-10 22:00:49,224 - octoprint.util.comm - INFO - Changing monitoring state from "Finishing" to "Operational"
2020-03-10 22:00:51,252 - octoprint.plugins.tracking - INFO - Sent tracking event print_done, payload: {'origin': 'local', 'file': 'c9f8039062370471f012bd9b8a6dd87a05618acc', 'elapsed': 10784}
2020-03-10 22:00:53,149 - octoprint.plugins.smsnotifier - INFO - Print notification sent to +1XXXXXXXXXX
After the update:
2020-03-12 00:35:57,733 - octoprint.server - INFO - OctoPrint 1.4.0
2020-03-12 00:35:57,754 - octoprint.plugin.core - INFO - 18 plugin(s) registered with the system:
| Action Command Prompt Support (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/action_command_prompt
| python:
| pip: 19.3.1
| version: 2.7.16
2020-03-12 20:57:35,246 - octoprint.printer.standard.job - INFO - Print job done - origin: local, path: equipment_lid_0.2mm_PLA_MK3S_2h34m.gcode, owner: egburr
2020-03-12 20:57:35,408 - octoprint.util.comm - INFO - Changing monitoring state from "Finishing" to "Operational"
2020-03-12 20:57:36,763 - octoprint.plugins.tracking - INFO - Sent tracking event print_done, payload: {'origin': u'local', 'file': '532dbb377e1da30167b8740fba4ef38c1df74e52', u'elapsed': 9493}
2020-03-12 20:57:37,165 - octoprint.plugin - ERROR - Error while calling plugin smsnotifier
Traceback (most recent call last):
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/plugin/__init__.py", line 224, in call_plugin
result = getattr(plugin, method)(*args, **kwargs)
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint_smsnotifier/__init__.py", line 90, in on_event
return self._send_txt(payload)
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint_smsnotifier/__init__.py", line 94, in _send_txt
filename = os.path.basename(payload["file"])
KeyError: 'file'
2020-03-12 21:05:58,498 - octoprint.server.heartbeat - INFO - Server heartbeat <3
Before 1.4.0 update:
payload: {'origin': 'local', 'file': 'c9f8039062370471f012bd9b8a6dd87a05618acc', 'elapsed': 10784}
After 1.4.0 update:
payload: {'origin': u'local', 'file': '532dbb377e1da30167b8740fba4ef38c1df74e52', u'elapsed': 9493}
Notice the "u" in the local and elapsed keys, but not in the file key? But the error seems to be complaining about the file key. And this is what the server is sending to the plug-in if I understand it correctly.
Unfortunately, I don't know python, so don't know what this means, but it's an obvious before/after difference I can see.
Additional information about your setup (OctoPrint version, OctoPi version, printer, firmware, browser, operating system, ... as much data as possible)
Printer: Prusa i3 MK3S
Firmware: 3.8.1
OctoPrint 1.3.12 ==> 1.4.0
SMS Notifier 0.3.2
(I've submitted a issue in the github project for it, but there has been no activity there for 2 years, so I have no idea what status is.)
Any thoughts on this?
Thanks!