@julian.riise (Julian) posted a new topic, subject "Hops error — Grasshopper". It read:

   I'm not able to use my Hops component, I keep getting this error:  
    “Object reference not set to an instance of an object.: component “BuildingCurves” (aa4f4a6d-aaa5-4dcd-8198-0b5dbb0b9c07)”
    
    Screenshot callahansheila@example.org×628 379 KB
    
    My Hops component has the “Get …” inputs:  
    
    
    Screenshot callahansheila@example.org×740 182 KB
    
    And the Group > “RH_OUT:name” outputs:  
    
    
    Screenshot callahansheila@example.org×678 118 KB
    
    I'm new to using Hops, perhaps there was some update changing the workflow?

@julian.riise (Julian) replied

    I figured it was something to do with the inputs. I removed the inputs (grouped, light blue), and connected empty mesh and empty curves component, saved and it worked. Not sure what exactly was wrong here.

So @wim (Wim Dekeyser) replied

    Hei Julian -
    
    julian.riise:
    
    > Not sure what exactly was wrong here.
    
    If you post the .gh files with the inputs, we could probably take a closer callahansheila@example.org.
    
    Apart from that, the named-group-output procedure is now obsolete. You can use the `Context Bake` component to create the output.
    
    The Hops documentation was recently updated:
    
    developer.rhino3d.com
    
    ### What is Hops
    
    The developer.rhino3d.com website contents
    
    -wim

@AndyPayne (Andy Payne) replied

    @julian.riise You hit the nail on the head. The issue you were seeing was in fact happening because of the components shown in the blue groups. You have to remember that Hops is sending this definition (in JSON format) over to a headless version of rhino. That headless version of rhino doesn't contain a document which contains any sort of referenced geometry. So when it runs and tries to find that geometry, you get an error that says that that component which contained a reference to a geometry found in the document couldn't be found. If you remove those parameters (not the Context Get components but the ones passing the geometry into the Context Get components) then your file will run just fine because the file isn't having trouble finding the geometry which doesn't exist in a headless rhino instance. Does that make sense?

So @declan (Declan Halpin) replied

    Just trying to get my head around “headless”…
    
    Can the headless Rhino include reference geometry & layers etc?

After which, @AndyPayne (Andy Payne) added

    No. The headless rhino document won't contain any geometry. You can pass geometry into your function by using the `Get Geometry` context component and it will send any geometry that you want over to the rhino.compute server to perform calculations. But, it has to be passed in via the `Get Geometry` component or created via standard Grasshopper components inside the function. It can't be referenced from a rhino document because that document doesn't exist over on the rhino.compute server.

@declan (Declan Halpin) replied

    Thanks Andy!
    
    Sorry to hijack the thread, but will the Get Geometry component also respect layer names?

@AndyPayne (Andy Payne) replied

    Unfortunately, no. It's only passing over the actual geometry (not any attributes). You could create another input (using Get String) and pass the layer name into the Hops function that way.

Then @declan (Declan Halpin) said

    How about geometry that is already internalized into the .gh within a brep parameter, etc?
    
    EDIT  
    Answered my own question. Yes, Internalized geometries work fine.


{'source': 'discourse', 'url': 'https://discourse.mcneel.com/t/hops-error-grasshopper/139934', 'title': 'Hops error — Grasshopper', 'views': 352, 'has_accepted_answer': False, 'word_count': 532, 'like_count': 3, 'reply_count': 6, 'participant_count': 4, 'posts': 9, 'tags': 'mac hops', 'author': '@julian.riise (Julian)', 'participants': '@julian.riise (Julian), @wim (Wim Dekeyser), @AndyPayne (Andy Payne), @declan (Declan Halpin)', 'image_url': ['https://global.discourse-cdn.com/mcneel/uploads/default/optimized/4X/0/8/b/08b74b70d75c299246498920a803d5f0139c9074_2_1024x464.png'], 'created_at': '2022-03-23T13:29:05.478Z', 'last_posted_at': '2022-06-08T15:52:24.097Z'}