Problematic beamer


I have a 2005 BMW x5. I’ve had it since March 09’. I love this car, but since i got it it has periodically died for no reason. It only happens when it’s idling at a stoplight, and it starts back up after i turn it back on. Also, on occasion it will start to shudder really bad and the service engine soon light comes on. When I restart it the shuddering and the light is gone. I use 93 octane gas, and was told if it doesn’t die while on the diagnostic machine, they can’t find what is wrong with it. Any ideas what is causing it?

Probably a vacuum leak from one of the big hoses under the first layers of covers over the va;ve cover (where the coils are) I am assuming it is a V-8. Vacuum leaks will do this sort of thing and not set a code.Either that or the crankcase vent valve, heard any “mooing”? they make a mooing noise when ruptured. They are located at the back of the intake manifold (way back), you cant see it.