Since this is useful for others besides the OP, I'll just paste what I said to them in message when they messaged me the same question:
There is a bug that has been around for a very long time where stability isn't calculated correctly for certain things, and crops are one of those. As long as you have support, it is fine. If you are putting a farm in the middle of a large roof without any support except on the edges, the weight of the fully grown plant could cause a collapse. But if you are within 5-7 blocks or so if a wall or a support pillar underneath, it will be fine and you can ignore that.
However, if you see that when building, it means placing that block will likely cause a collapse, so be careful with other things than crops.