Dirt, oil, burrs or scale on the surface of the parts being welded can affect resistance welding. They can cause expulsion from the surface, the interface or cause defects in the weld nugget.
When the electrodes close and there is dirt, rust, oil, burrs or scale present, the first thing that happens when the current initiates is to burn off the oil and in most cases expel the scale, rust or burrs as expulsion. Then the part may be fully seated and ready to weld. Unfortunately part of your weld schedule was used cleaning and seating the parts together – not heating the parts. You may not achieve the proper weld nugget. Finally you may not have gotten rid of all of the defective material and it may become part of your weld nugget and become a foreign particle/inclusion/defect/porosity in the weld nugget. This may or may not pass your quality specification.