Check the ground connection to the rectifier.
The wire breaks internally and of course the body, which is ground is screwed into the plastic dip stick tube so gets no ground if the wire is broken or not there.
And remember the wire has to be connected at both ends .
I like to use 2 ground wires, one off the starter mounting bolt and another off the rear cowl mounting bolt, But I am anal about ground connections .