audi s3 8p struggling to idle

Totally normal as when you remove your oil cap and dipstick you are allowing un metered air to enter the engine therefore the reading generated by the maf is not accurate and the ecu can not accurately adjust fuelling etc.