wear gloves if you're really nervous... but personally, i wouldn't give a ****... (e.g. touching old lead based paint in an old house is NOT going to give you lead poisoning..etc... though eating LOTS of it might, but its still one hell of a trip) but just don't do the crazy stuff like it if breaks off into dust inhale the dust or something... (the foam, that is)
which means you might wanna do it outside...
you *could* get gasoline in a pan and dump all the foam into the pan with the gasoline which will melt right into the gasoline for some residue which looks, feels, and proally acts just like napalm... though i don't think it is, but its still kinda fun to light some flammable bubble gum on fire... using the same gasoline to clean the parts of foam stuck onto the compressor should also be fine, though you'd wanna hose it down afterwards and then soap and hose down again and let it dry fully first... and for the pieces of bubble gum string thats left, duct tape will remove em' if you know how...
or you *could* just rip the foam off and throw it into the recycle-bles bin if you got one and let "them" take care of it, which i'm sure "they" will...