A.J.Rouvoet
A.J.Rouvoet

Reputation: 1213

Python print()/sys.stdout.write() not visible when using logging

I'm using logging extensively in my program. But now I want to write to stdout without using the logging module, but the output does not show up.

Neither:

sys.stdout.write( "BOE!" )

Nor

print( "WAH!" )

is working. Can someone enlighten me?

Upvotes: 5

Views: 18025

Answers (1)

Suman
Suman

Reputation: 9571

Its possible that your Python output is being buffered. Have a look at these two StackOverflow QAs:

  1. Disable output buffering
  2. How to flush output of Python print?

Upvotes: 7

Related Questions