H 17.5.391 (but doesn't work for me in earlier builds as well)
Hi,
this seems to be a function related to the game dev toolset? Not sure.
Can anybody help me with this (plz see description below)?
Cheers, Marc
–
Description:
When I use ‘Preferences/Set External Editor’ to point to a editor like notepad++ or sublime, I get the message that the editor is successfully set.
1. But, when I hit the ‘External Editor’-button in a opened expression window, Houdini will still open notepad.exe.
2. And when I want to open the external editor directly from the parameter field via right-click -> ‘Expression/Edit in External Editor’, the following message appears:
'float' object has no attribute ‘encode’ Traceback (most recent call last): File “<stdin>”, line 5, in <module> File “C:/Users/defsh/AppData/Roaming/SideFX/GameDevToolset/17.5/1.196/scripts/python\houdini_external_editor.py”, line 253, in add_watcher data = str(parm.eval().encode(“utf-8”)) AttributeError: ‘float’ object has no attribute ‘encode’
Bumping this old thread. How did you resolve this in the end bollili? I have been able to set the VISUAL environment variable but it seems that there is still something broken relating to this in SideFX labs.
I found I was able to resolve this by removing SideFX Labs, quitting Houdini, updating the .env, then a fresh install of SideFX Labs R416, then resetting the preference again through Edit > Preferences > Set External Text Editor.
Hey there, almost two years later, I encounter a problem with the external script editor.
I managed to pass in the external script editor exe like molder mentioned and alt+e opens the external editor like expected. but the pipe from the temp file to the expression field seems broken, since saving the file will not update the code in the node. right-clicking edit in external editor works fine though.
The solution is to add -w as a launch argument to the end of the environment variable value. This waits for the process to close which houdini requires according to support, and keeps the item loaded in a single thread.
EDITOR = "C:/Users/XXXX/AppData/Local/Programs/Microsoft VS Code/Code.exe -w"
Edited by Andrew Graham - 2022年5月27日 20:45:08
https://openfirehawk.com/ [openfirehawk.com] Support Open Firehawk - An open source cloud rendering project for Houdini on Patreon. This project's goal is to provide an open source framework for cloud computing for heavy FX based workflows and allows end users to pay the lowest possible price for cloud resources.
I managed to use VSCode as external editor for python scripting but I'm experiencing few issues:
The hotkey ALT+E does not work because it launches the internal Houdini editor. To properly launch VSCode, I must right-click (RMB) on the Python Code parameter, select 'Expression', and then click on "Edit in External Editor."
When editing a Python SOP, I must include "import hou" in the code to enable autocompletion in VSCode, which is redundant for a Python Sop.
Additionally, autocompletion is not instantly available; there is a significant delay of at least 15 seconds before it becomes accessible in VSCode.
Regarding 2, I tried to add the following line in the settings.json of VSCode, but it didn't work:
I managed to make the hotkey launch an external editor. I have to: - hover the mouse over the title of the parameter (as in the attached picture) - also, the text cursor can't be active in that parameter
Did anyone manage to launch an external editor, while the cursor is active in the parameter?
jomaro I am having the same issue even in H20.5, everytime you open the external editor you need to close the file in VSCode to prevent Houdini from crash!
did you use -w like I suggested?
https://openfirehawk.com/ [openfirehawk.com] Support Open Firehawk - An open source cloud rendering project for Houdini on Patreon. This project's goal is to provide an open source framework for cloud computing for heavy FX based workflows and allows end users to pay the lowest possible price for cloud resources.
jomaro I am having the same issue even in H20.5, everytime you open the external editor you need to close the file in VSCode to prevent Houdini from crash!
did you use -w like I suggested?
Yes I did, it looks like it's the normal behavior, you need to close the file in VSCode so Houdini can pick it up!