How to fix Pronterface/Printrun UnicodeDecodeError: 'utf-8' codec can't decode byte ... in position ...: invalid continuation byte


When starting Pronterface / Printrun on Linux using pronterfaceprintrunpython3 or similar, you see an error message like

Traceback (most recent call last):
  File "", line 62, in <module>
    app = PronterApp(False)
  File "/home/uli/dev/tools/Printrun/printrun/", line 2464, in __init__
    self.mainwindow = PronterWindow(self)
  File "/home/uli/dev/tools/Printrun/printrun/", line 170, in __init__
  File "/home/uli/dev/tools/Printrun/printrun/", line 786, in parse_cmdline
  File "/home/uli/dev/tools/Printrun/printrun/", line 1031, in process_cmdline_arguments
    pronsole.pronsole.process_cmdline_arguments(self, args)
  File "/home/uli/dev/tools/Printrun/printrun/", line 769, in process_cmdline_arguments
  File "/home/uli/dev/tools/Printrun/printrun/", line 664, in load_default_rc
  File "/home/uli/dev/tools/Printrun/printrun/", line 632, in load_rc
    for rc_cmd in rc:
  File "/usr/lib/python3.8/", line 714, in __next__
    return next(self.reader)
  File "/usr/lib/python3.8/", line 645, in __next__
    line = self.readline()
  File "/usr/lib/python3.8/", line 558, in readline
    data =, firstline=True)
  File "/usr/lib/python3.8/", line 504, in read
    newchars, decodedbytes = self.decode(data, self.errors)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd3 in position 4: invalid continuation byte


When you see this error message, typically your pronsolerc is corrupted. In order to remove it,

rm -rf ~/.config/Printrun