There could be two possible reasons for smoke coming from oil cap.
Oil cap off engine stalls.
When the fuel bypasses worn.
It means that the fuel system is working as advertised.
When you take the oil cap off while runnning you also need to block the hoses that vent the blowby into the inlet system.
The reasons for engine emitting smoke from oil cap.
Some systems are that sensitive bmw for example will do the same thing if tuned properly if there is a problem with the engine it would be that it is running on the lean side.
Hot fuel bypasses worn valve stem seals and rings.
Engine stalling is more likely to occur during cold weather or when starting a cold engine.
However i have no idea what is.
So this kind of engine stalling problem often means the engine is not getting enough fuel and or too much air.
By removing the oil cap you have introduced a large air leak in a closed pcv system.
It will have stalled becuase it will have sucked air onto the inlet system through the oil filler hole this will have messed up the air fuel ratios seeing it will have been sucking in air after the afm so the afm will not have been able to get the mixture right.
Just messin around with my car.
Clean up if there is any oil residue.
Remember not to open the cap when the engine is hot.
Engine stalling problems can be hard to find and are often sensor or temperature related.
2013 mustang 3 7 v6.