lxqt / qtermwidget

The terminal widget for QTerminal

Home Page:https://lxqt.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Silence decoding errors (Vt102Emulation::reportDecodingError)

willbelr opened this issue · comments

Current Behavior

When Vim is opened or closed, everything seems to work as expected, but a bunch of decoding errors are printed in the terminal:

VIM ENTERED;

Undecodable sequence: \001b(hex)[22;0;0t
Undecodable sequence: \001b(hex)[>4;2m
Undecodable sequence: \001b(hex)[>4;2m
Undecodable sequence: \001b(hex)[22;2t
Undecodable sequence: \001b(hex)[22;1t
Undecodable sequence: \001b(hex)P
Undecodable sequence: \001b(hex)\\
Undecodable sequence: \001b(hex)[0%

VIM EXITED;

Undecodable sequence: \001b(hex)[>4;m
Undecodable sequence: \001b(hex)[>4;m
Undecodable sequence: \001b(hex)[23;2t
Undecodable sequence: \001b(hex)[23;1t
Undecodable sequence: \001b(hex)[>4;m
Undecodable sequence: \001b(hex)[>4;m
Undecodable sequence: \001b(hex)[23;0;0t
Possible Solution

Add a switch to disable output of void Vt102Emulation::reportDecodingError()

Steps to Reproduce
#!/usr/bin/python3
from PyQt5 import QtWidgets
import QTermWidget


class Terminal(QTermWidget.QTermWidget):
    def __init__(self):
        super().__init__(0)
        self.setShellProgram("vim")
        self.setArgs(["--clean", "--noplugin"])
        self.startShellProgram()
        self.show()


if __name__ == "__main__":
    app = QtWidgets.QApplication([])
    term = Terminal()
    app.exec()
Context

Vim is used as a text editor for a bunch of 'sticky' notes. Thus terminals are often opened and closed during normal operation. The decoding errors kind of flood the terminal, so I would like to just turn them off.

System Information
  • Distribution & Version: Arch Linux
  • Kernel: 5.4.84-1-lts
  • Qt Version: python-pyqt5 5.15.2-2
  • lxqt-build-tools Version: 0.8.0-1
  • Package version: 0.16.1-2

Ah, I had once pushed a patch but forgot to create a pull request - now done at #394.