One thing I’ve learned about moving solutions between environments, is get those connection references right to save a world of pain.
Generally, when writing a new Flow, the connections are created as you write the Flow, and the system creates something or chooses something that is hard to understand, as they are unnamed.
I have found it’s best to create the connection references upfront, before you set foot in a Flow. Then you can choose the reference when you create the Flow, and you know what you are going to get.
And this way, when you create the references, you can name them properly !
New solution, first thing, Create Other / Connection Reference. Here I have named the reference after the solution name.

Then in the Flow, the connection reference is available to choose by its name, so you know exactly what you are going to get, no randomness with multiple unnamed connections:

And the connection is now changeable in the reference pointer, so when you use the same connection in multiple FLows, one change in the reference changes all of them.
And continuing in this vein, when importing the (managed) solution into a new environment, I suggest it is best to create the connections before importing. Then on import, the connection references should autofill just needing a confirmation click to have it all set up.

Now, another problem. Some Flows do not allow you to switch from connections to connection references. Older Flows before the feature become available and Flows which were copied via Save As, which end up outside a solution and hence no connection references. (References are purely in solutions).
So the simplest way to switch these evil Flows to use references is to create a new solution, add the offending Flow(s) into it, export as unmanaged, and then reimport. Remove the original Flow from the original main solution, and add in this re-imported Flow, and voila, connection references are now used.