making sure your wheels are torqued to spec is important. especially on aluminum rims.
I had the same thing happen to me and one of my lug studs snapped right off. Hadnt torqued them down, but drove for thousands of km's and all of a sudden... so, they can work there way loose. Torque them to spec after the wheel has been off. Retorque them after 100km. make sure that you hear the click after you have turned it, if you try and turn it and it clicks instantly, that means it's too tight so back it off and re torque it.
I know most people know that, some don't, and some dont care cause they havnt had a problem.
But when I was workin at a shop a while ago, we got a guy come in for a rotate, and all his nuts where loose. we're talking finger tight, and one or two where missing. we thought he had taken his wheels off at home and put them back on himself. Not the case. He'd taken them to another local shop and it turns out they just used there impact gun to zip the wheels back on. That is a mistake that can cost a person personal damage or injury and it's not even excusable. Totally preventable if your not a lazy guy.