Hey willh, hhanks for the great example.
The short answer is that LOP Import will happily import invisible primitives by default. If you change your lopimport Primitives parameter to be:
/Paintings/Painting/* & { usd_isvisible(0, @primpath) }
Then I think everything works as expected. The “&” and everything after says the prims must match both the name pattern and the VEX expression inside the braces, which ensures that the prim is visible (see
https://www.sidefx.com/docs/houdini/solaris/pattern.html).
Apologies if the rest of this answer is too pedantic, but I was confused by your original question because I was assuming that your three variants actually contained the three different pieces of geometry, rather than just setting the visibility on the prims. By having all three pieces of geometry in the scene graph you are (very slightly) slowing down composition, and also making it a little harder to quickly see what the contents of your scene are. So you might want to look into changing the way you are authoring your variants (which will also sidestep this LOP import visibility issue). Also, a minor point (which may not happen in your real scene, just in this quick example), but you've got a component defined under another component, which isn't a legal Kind hierarchy. /Paintings/Painting should really be a Group.