For really flaky electrical issues - look for bad grounds.
Could be as simple as a dirty starter button contact.
Does the fuel pump prime at turn-on? It should run for 5 sec if the computer thinks it's ok to start the bike. Next time, turn the handle bar switch off/on and listen for the fuel pump.
This type of thing drives us mechanics crazy. I've been tracing a intermintent no-start problem for a friend these last two years or so. It finally broke down and wouldn't start. Was a simple problem with a wire pushed out of a gang connector.
"Dad, can I get a motorcycle when I grow up?"
"Son, you can't do both"