No module named sidefx_stroke or kinefx.stateutils

   4310   9   4
User Avatar
Member
61 posts
Joined: 10月 2013
Offline
On a fresh Houdini 19 install we were getting

ImportError: No module named sidefx_stroke
and
ImportError: No module named kinefx.stateutils

To fix this we had to add the following to our houdini.env
PYTHONPATH = $PYTHONPATH;$HFS/packages/kinefx/python2.7libs;$HFS/houdini/viewer_states;$HFS/packages/kinefx/viewer_states

Curious if this is expected behavior? Leaving it here in hopes that it helps anyone else experiencing the same issue.
Edited by blented - 2021年11月20日 10:06:15
Grant Miller
VFX Supervisor
Ingenuity Studios
User Avatar
スタッフ
399 posts
Joined: 2月 2018
Offline
I just tried with H19.0.445, both modules should load as expected. You shouldn't have to add anything to PYTHONPATH.
Edited by mabelzile - 2021年11月22日 10:00:37
User Avatar
Member
61 posts
Joined: 10月 2013
Offline
Thanks for checking, we'll look through our env more and try to figure out what's causing the hang-up.
Grant Miller
VFX Supervisor
Ingenuity Studios
User Avatar
Member
2 posts
Joined: 8月 2013
Offline
Thanks for the fix Grant, this sorted out the same issue here (for 18.5, but we see it in 19 too).

I think for our case the bug may have been associated with this (once?) bug fix (in sidefx change log, for Houdini 18.0.363):


Fixed a bug where OTLs would fail to load on startup with errors like:
"ImportError: No module named sidefx_stroke"

When %HOMEDRIVE%%HOMEPATH% was set to the root of a drive, like Z:\

Maybe it has surfaced again?
User Avatar
Member
61 posts
Joined: 10月 2013
Offline
Worth noting, on a fresh install w/ no tools we're still seeing this on 19.5

The above fix works, modified for python 3.9 as such:
PYTHONPATH = $PYTHONPATH;$HFS/packages/kinefx/python3.9libs;$HFS/houdini/viewer_states;$HFS/packages/kinefx/viewer_states

But we're getting a new error which we're still trying to track down:

Error running event handler:
Traceback (most recent call last):
  File "labs::Lop/karma::2.0, ViewerStateModule", line 18, in <module>
  File "C:\Program Files\Side Effects Software\Houdini 19.5.303.9\python39\lib\site-packages-forced\shiboken2\files.dir\shibokensupport\__feature__.py", line 142, in _import
    return original_import(name, *args, **kwargs)
ModuleNotFoundError: No module named 'ParseExrMetadata'

Error running event handler:
Traceback (most recent call last):
  File "labs::Lop/karma::2.0, opdef:/labs::Lop/karma::2.0?ViewerStateInstall", line 1, in <module>
  File "C:\PROGRA~1/SIDEEF~1/HOUDIN~1.9/houdini/python3.9libs\viewerstate\utils.py", line 948, in register_pystate_embedded
    raise ViewerStateException("createViewerStateTemplate not found in {}".format(node_type.sourcePath()))
viewerstate.utils.ViewerStateException: createViewerStateTemplate not found in oplib:/labs::Lop/karma::2.0?labs::Lop/karma::2.0
Grant Miller
VFX Supervisor
Ingenuity Studios
User Avatar
Member
146 posts
Joined: 1月 2016
Offline
Hello Grant,
I had no problem with 19.0, but now I had both the problems with 19.5


- First (the "sidefx_stroke" and "kinefx.stateutils") is fixed by adding paths as you suggested. Thank you very much for it!
- The second ('ParseExrMetadata' and 'register_pystate_embedded') persists, same as you said

But both problems can be "fixed" if I don't have the .hiplc file in a specific path (a root of Q:/ drive in my case). If I run the same .hiplc from a subfolder, I get no errors.

I am not sure if I can help to debug it further, but I can send my files and settings to SideFX, if it helps.
User Avatar
Member
16 posts
Joined: 10月 2017
Offline
Hello, I am facing the same issue with Houdini 19.0.589 when I launch Houdini from a console if I cd in another drive than C:/.
Houdini is installed on a network and managed with Rez, and when I need to launch Houdini, I open a cmd prompt, cd in the Rez directory (R:/), acquire the rez environment, and then type "houdini", it launches, and then raises the errors you mention. If I do the same thing but before typing Houdini and launching it, I cd in the C:/ directory, everything works fine. There are no environment variables that could conflict, other than SESI_LMHOST but I don't see why this one could cause an issue like this.

# Does not work
C:\Users\donromano > cd /D R:/
R:\ > rez-env houdini-19.0.589
R:\ > houdini

# Works
C:\Users\donromano > cd /D R:/
R:\ > rez-env houdini-19.0.589
R:\ > cd C:/Users/donromano
C:\Users\donromano > houdini

I also tried with a local installation of Houdini 19.0.589 and same behavior :

# Does not work
C:\Users\donromano > cd /D R:/
R:\ > "C:\Program Files\SideFX\Houdini 19.0.589\bin\houdini"

# Works
C:\Users\donromano > "C:\Program Files\SideFX\Houdini 19.0.589\bin\houdini"
User Avatar
Member
30 posts
Joined:
Offline
Hi all,

It seems houdini doesn't like the startup directory being the root of a drive (under windows).

If i add a fresh usb drive (just to make a new drive letter) and startup from e:\, i get all the state load errors. if i make a subfolder and start from that director (e:\temp for example), i get no load errors.

time for a bug report.

cheers,
chrisg
User Avatar
Member
3 posts
Joined: 10月 2019
Offline
For anyone who has encountered this issue, if you are starting Houdini from a shortcut which locates in the C drive, try create a shortcut by yourself for the executable in /bin folder under Houdini's install location and use this shortcut. This fixed my issue, and this issue only exists on my Windows 11 machine.
User Avatar
Member
61 posts
Joined: 10月 2013
Offline
Amazing tip, this has been such an annoyance, thank youuu!

The Right click > Properties > Start In path is %HOMEDRIVE%%HOMEPATH% by default on our Windows install, it should be:

"C:\Program Files\Side Effects Software\Houdini 20.0.506\bin"

Attachments:
shortcutSettings.png (13.5 KB)

Grant Miller
VFX Supervisor
Ingenuity Studios
  • Quick Links