Hi, I am currently exploring the possibility of creating a Python script that runs a Grasshopper file as a service.
In my investigation, I have reviewed various Rhino.Inside resources and found examples demonstrating how to execute simple Grasshopper files, such as performing basic arithmetic operations and outputting the results. These examples typically involve loading the Grasshopper definitions and executing them sequentially within a loop. However, I am interested in a different approach where the Grasshopper file is loaded and executed similarly to how it is done manually when we open and execute grasshopper in Rhino’s UI. Ideally the python script would be structured like:
import packages → load the file.gh → execute the loaded file.gh
I am wondering on whether the solution I am attempting to implement using Rhino.Inside in Python is feasible. If it is, I would appreciate guidance on what steps may be necessary to successfully implement this logic. Alternatively, if this approach is not viable, I would like to explore alternative solutions.
Additionally, I am aware that there were limitations in the past regarding the use of Grasshopper Python components with Rhino.Inside (as discussed here: Run/Solve a Grasshopper file without starting Rhino CPython Rhino.Inside - #10 by nathanletwory). I am curious to know if these limitations have been addressed, and if it is now possible to use Grasshopper Python components with Rhino.Inside.
Thanks in advance
PL