Atom-runner does not display print messages in the correct order


#1

I’m executing a python script using atom-runner. The two issues I see are:

  1. Nothing displayed on the atom-runner console until the full script is executed, then all the prints jump up together.
  2. The order of the print messages is not correct when I’m calling an external EXE through os.system()

The code flow in general is as follows (I apologize for the formatting, this is my first post)


Some code here

print “Begin Processing”

Call an exe that uses above variables

os.system(test.exe)

Some more code

print “End Processing”

Now, the exe itself has a bunch of prints within showing what it’s doing. On the output console, what I see is:

messages_from_exe
Begin processing ----> This should have printed before the messages from the exe
End processing

When I run this script on the command prompt as
C:> python test_script.py

… I see the print messages in perfect order of code execution.

So, atom-runner seems to be holding on to all the messages being sent to the output console, and displaying them out of order. I wanted to check if this is a known issue with atom-runner and/or if there are ways to get the output console display to have the proper order of display messages.


#2

This is something that you should bring up with the package’s maintainers. If you post here, they’re not necessarily going to see it. Additionally, before you assume that the problem is with the package, you should execute your script with the python command. If it behaves the same way, then the issue is something in Python that’s behaving unexpectedly.


#3

Thank you. I have opened a bug ticket on the package’s page on Github.
PS: yes, I verified the script directly from windows command prompt (mentioned in the original ticket), as well as with other packages that can run python code.