Is there a similar example that we can see? hidden link
What is the link to your site? hidden link
I wonder if this is normal ? its displays fine on a mobile phone but leaves holes in the grid... perhaps my conditional shorcodes should be elsewhere ?
When you create a View it queries the database depending on the settings and returns an array of posts.
The output section then loops over those posts and outputs the fields you specified.
When you wrap the fields in a conditional shortcode the posts are still looped over, you just don't output the fields when the condition fails.
If you add a grid to the mix, then you still get the grid scaffolding, whether or not you output the fields for a given post.
Hence the gaps in the grid.
Because of how the Bootstrap grid works, it needs a fixed number of items per row, so you can't simply omit the output of one of the posts and everything shuffle into place to fill the gap.
The solution is to either roll-your-own CSS grid that doesn't involve a fixed number of elements per row (should be easy enough to produce a flexbox alternative and edit the View markup as required), or to modify the results returned by the View so that the unwanted posts are not included in the first place.
If the test is for a custom field or taxonomy value, you can add a Query Filter to exclude posts based upon that.
(If you can't see the Query Filter section, go to Screen Options at the very top of the page and make sure it is checked.)
I love the scaffolding analogy - sometimes I think I should go back to real scaffolding rather than the non persistent kind. Anyway as usual a great explanation.
The intended use is to deal with a blob of html generated by a shortcode, which comes only after running through the loop - I need to rethink my approach now you have made everything clear with this excellent analogy.