A method to detect retained gas during AC electrograining using in-situ small angle X-ray scattering