Hey,
I removed that code from ad-inserter and Google webmaster validated AMP pages and removed errors from all AMP pages.
It seems it was not at your end. Google Adsense provided two different codes to run ads. One for normal pages and another one for AMP pages. So removed codes for AMP pages.
No error now.
Thanks