Hi AW18,
I changed the forum category of your post from ‘mac’ to Rhino.Inside.Revit
Since you are using Rhino 8 I would recommend baking with the native components (content cache) which allows more complex workflows.
The python bake component is available in the Python scripting guide.