Open zm08 opened 4 years ago
I have the same issue and please kindly tell me if you have solved this issue.
Hi, I was stuck with the same issue but I created a fix to it 👍 Now my printer works in my network: Solution is : Edit the following file -> python-printer-escpos/src/main/python/escpos/connections.py at the line 324 add
if(type(msg) == str) :
msg = str.encode(msg)
Final result should look like :
def _write(self, msg):
"""
Print any command sent in raw format
"""
if(type(msg) == str) :
msg = str.encode(msg)
self._device.send(msg)
(I've blanked out my IP address) produces the following error
I have made the necessary amendments from the NetworkPrinter instance has no attribute '_Generic__write' issue, and was subsequently hit with this TypeError