"Could the primary chain be too loose and causing this to happen!?"
very doubtful
but, just to put your mind at ease
why don't you remove the middle cap in the primary cover(do not start engine) and stick a finger under the chain and see if you can gently push it upwards at least 3/8 to say no more than 1/2 of an inch till it stops.
Is is ok, within those arbitrary bounds, too tight this is bad, too loose, report back?
Ok, now this centerstand it runs and immediately off centerstand is an interesting problem indeed!
I can't offer anything on that right now.
BUT, I think most everyone is limiting THE problem as to having an ultimate electrical solution.
I thank DogT and others are giving good advice that your bike is not adequately "grounded".
A loose ground can be an intermittent ground and could account for those perplexing shut offs.
As your battery appears to carry correct voltage, it may as simple as too few or poor ground wires.
Your bike is POSITIVE battery terminal "ground", not negative.
I hook a nice thicker wired to my positive battery terminal and then connect it to a point on the FRAME.
In my case I run this ground right down to one of the oil filter securing bolts, first making sure that those bolts are making contact with the black paint ground off nicely around the holes they go into.
At least this then issues your battery has a good ground.
Now, it is also important to have the motor itself also grounded, and so I then secure another length of thicker wire to the left side back engine to frame plate bolt and then run it down to that same oil filter securing bolt.
These are easy and just well considered things that should be done anyway, but they may miraculously also solve your entire problem in a couple minutes work!
By the way, don't give up and curse the bike, it IS a 40 year old British bike and yes one does have to get real intimate with everything about it. There is no dealer to take it too, and you personally do need to become THE problem solver on every little issue, frustrating, perplexing, rewarding, and entertaining, we all go through this as you are are now.
You will get this solved, we will stick with you!