Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qprocess exiting with exit code 255 when trying to run python script
Forum Updated to NodeBB v4.3 + New Features

Qprocess exiting with exit code 255 when trying to run python script

Scheduled Pinned Locked Moved Solved General and Desktop
qprocessqt c++python
22 Posts 4 Posters 6.9k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • AdithyaA Adithya

    @JonB @jsulm using python3 actually worked .But not sure whether the script is being executed or not
    I changed .py file something like this (running in infinite loop)

    if name == 'main':
    while True:
    print("Hey there")

    The process is still running
    Log :
    Process = QProcess::Starting
    ERROR: QProcess::UnknownError
    Process = QProcess::Running

    But any idea why I am not getting the log .

    jsulmJ Offline
    jsulmJ Offline
    jsulm
    Lifetime Qt Champion
    wrote on last edited by
    #21

    @Adithya said in Qprocess exiting with exit code 255 when trying to run python script:

    running in infinite loop

    Please do NOT do such infinite loops in an event driven frameworks like Qt! There is really no need for that and it blocks Qt event loop.
    "I am not getting the log" - please explain how you're getting this log and what do you actually mean exactly by "log". If you mean the output of your script then I already suggested to read its stderr/stdout.

    https://forum.qt.io/topic/113070/qt-code-of-conduct

    1 Reply Last reply
    2
    • AdithyaA Offline
      AdithyaA Offline
      Adithya
      wrote on last edited by
      #22

      Thanks guys it worked. python3 and readyReadStandardOutput(showed the log ,was expecting it to work like qDebig() and cout .My bad) . Sorry for bothering with wrong misconception.

      1 Reply Last reply
      1
      • AdithyaA Adithya has marked this topic as solved on

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved