helloSystem / helloSystem/launch

Programs launched with 'launch' crash if they try to use stderr after X seconds

Offen
#4 5 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
bug help wanted
Vorherrschende Sprache
C++
Sterne
17
Forks
6
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

* When an application is launched through the `launch` command, then it will exit as soon as it wants to print something to stdout and/or stderr after the [`p.waitForFinished period`](https://github.com/helloSystem/launch/commit/c238bcc13b8ea1b58b6690c47d073b75013d0156#diff-34d21af3c614ea3cee120df276c9c4ae95053830d7f1d3deaf009a4625409ad2R301) has elapsed
* ~~No output is printed to stdout at all before the `p.waitForFinished period` has elapsed~~ __fixed__ using `p.setProcessChannelMode(QProcess::ForwardedChannels);`
* If `launch Menu` is used to launch the global menu bar, then it will exit if the `p.waitForFinished period` has elapsed and the user then selects any menu item from the System menu (but not from some other menus). Possibly because selecting commands from the System menu makes liberal use of `qDebug()` to print debug information to the console?
* If `qpdf` is launched with the `launch` command, then it will exit after the `p.waitForFinished period` (when set to 3 seconds, possibly because around 3 seconds it wants to write `QKqueueFileSystemWatcherEngine::addPaths: open: No such file or directory` to stderr). Why? (Setting a longer `p.waitForFinished period` might do away with this immediate crash because then the `QKqueueFileSystemWatcherEngine::addPaths: open: No such file or directory` is already written to stderr?)

~~With `p.waitForFinished period` set to 10 seconds, then the `ping` command will exit after 10 seconds, and only then show the output of the `ping` command~~ __fixed__ using `p.setProcessChannelMode(QProcess::ForwardedChannels);`

__Once this is solved, set the time back to e.g., 3 seconds rather than 10.__

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Rechercherichtung

Beginne damit, das Problem mit dem `launch`-Befehl unter Verwendung von `ping`, `qpdf` und `launch Menu` zu reproduzieren, wobei der Schwerpunkt auf dem Verhalten nach dem Zeitraum `p.waitForFinished` liegt. Untersuche die bestehende Behandlung von `QProcess::ForwardedChannels` und vergleiche das Verhalten von stdout/stderr vor und nach dem Timeout. Als erledigt gilt die Aufgabe, wenn gestartete Programme und Menüaktionen nach dem Timeout weiterhin verwendet werden können, die Ausgabe weiterhin weitergeleitet wird und der Zeitraum auf etwa 3 Sekunden verkürzt werden kann.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
cpp
Bereich
cli, desktop
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.