I had this happen years ago while I was on a road trip in Montreal. I think a great deal has to do with the sprocket. In retrospect I noticed that my sprocket had some wobble when mounted on the spindle. The wobble turned into a rocking motion that slowly ate away at the teeth on the retainer. No amount of safety wire in the world is going to prevent the retainer to come off in this case.
Double check the sprocket, make sure there isn't too much wobble, use the mounting screws and you can probably use a central screw in the spindle with a washer as a safety measure. Carry a spare retainer and check regularly (or at least before a long trip).
In my case I got really lucky, the Ducati dealership in Montreal called a fellow Italian whose bike had the same retainer mechanism and he stripped the parts of his bike so I could make it home. Really cool of him

from the land fo spaghetti!
Carlo