I've mostly used Houdini on Linux, but I'm now using it on windows and I'm trying to set it up so that the terminal output goes back to a shell.
I can launch Houdini from PowerShell or command prompt, but the terminal output still goes to the floating window instead of back to PowerShell. I tried playing around with some environment variables (HOUDINI_DISABLE_CONSOLE, HOUDINI_TEXT_CONSOLE, and HOUDINI_WINDOW_CONSOLE) but no matter what I set them to, I can't get the text to go back to the shell.
Anyone else tried this and have any insights?
Houdini terminal output on Windows
7423 6 2- Mirrorsword
- Member
- 4 posts
- Joined: 9月 2010
- Offline
- Doudini
- Member
- 333 posts
- Joined: 10月 2012
- Offline
- kif11
- Member
- 20 posts
- Joined: 9月 2012
- Offline
- sdugaro
- Member
- 380 posts
- Joined: 7月 2005
- Offline
Anything come of this?
I have a .bat file I run from the houdini CLT or cmd terminal to config and fire up Houdini.
I was also a bit surprised to discover this in a move from linux to windows.
I just assumed I'd be able to see some output in the shell I launched Houdini from akin to linux.
For me, Python2.7 sys.stdout is captured all at once and output only to the Python Shell Pane when a process completes. This is certainly not as nice as linux, where you can see stdout/err stream to the shell wherever your print statements or logging is firing from. I can only seem to get the Houdini Console to capture vex/dso printf.
I also gave cygwin a quick try by sourcing houdini_setup from the installation directory and running the following simple progbar test. When running with a python interpreter in the winblows cmd terminal, it overwrites the same line as expected.
Run from a shelf, this does bring up a Houdini Console Window for me, but it doesn't stdout to the cygwin terminal.
Each line is flushed and echoed to the Houdini Console separately, which is a bit better than a process dump, but incomparable to working on linux in the first place. The Houdini Console looked to max out at something like 250 lines for me, I cant seem to get a logger to output anything, and print statements are not output to the Houdini Console - those are output to the Python Shell Pane along with all the sys.stdout when the process completes as before.
I'm going to try and attach a VSCode debugger and see if that better facilitates a code trace.
I have a .bat file I run from the houdini CLT or cmd terminal to config and fire up Houdini.
I was also a bit surprised to discover this in a move from linux to windows.
I just assumed I'd be able to see some output in the shell I launched Houdini from akin to linux.
For me, Python2.7 sys.stdout is captured all at once and output only to the Python Shell Pane when a process completes. This is certainly not as nice as linux, where you can see stdout/err stream to the shell wherever your print statements or logging is firing from. I can only seem to get the Houdini Console to capture vex/dso printf.
I also gave cygwin a quick try by sourcing houdini_setup from the installation directory and running the following simple progbar test. When running with a python interpreter in the winblows cmd terminal, it overwrites the same line as expected.
import sys import time import logging log = logging.getLogger() log.info("HELLO?") print("WORLD") iters = 500 # sys.stdout carriage return, no newline, overwrites the line for k in range(iters+1): pct = float(k)/iters msg = "\r running {:.2%} {}/{}".format(pct, k, iters) sys.stdout.write(msg) sys.stdout.flush() time.sleep(0.001)
Run from a shelf, this does bring up a Houdini Console Window for me, but it doesn't stdout to the cygwin terminal.
Each line is flushed and echoed to the Houdini Console separately, which is a bit better than a process dump, but incomparable to working on linux in the first place. The Houdini Console looked to max out at something like 250 lines for me, I cant seem to get a logger to output anything, and print statements are not output to the Houdini Console - those are output to the Python Shell Pane along with all the sys.stdout when the process completes as before.
I'm going to try and attach a VSCode debugger and see if that better facilitates a code trace.
Edited by sdugaro - 2021年3月23日 23:48:53
- Ashen
- Member
- 78 posts
- Joined: 5月 2018
- Offline
- Mirrorsword
- Member
- 4 posts
- Joined: 9月 2010
- Offline
- koen
- Member
- 793 posts
- Joined: 4月 2020
- Offline
Not sure if this helps, but I am running houdini through a wrapper ( a little Qt ui to select versions etc) and capturing std out and std err works great there:
self.process = QtCore.QProcess()
...
self.process.readyReadStandardOutput.connect(self.HandleStdOut)
self.process.readyReadStandardError.connect(self.HandleStdError)
self.process = QtCore.QProcess()
...
self.process.readyReadStandardOutput.connect(self.HandleStdOut)
self.process.readyReadStandardError.connect(self.HandleStdError)
-
- Quick Links