Recently, I found the AMP page of this blog is not working. After checking the web log error file, the error looks like below
If you Google it with wp-content/plugins/glue-for-yoast-seo-amp/classes/class-frontend.php:162
A lot of search results with the same problem.
Based on the Yoast SEO support page, it said it is AMP plugin fault.
gooma2 provided a workaround, I tried it. It does not work for my blog. All my blog’s AMP pages are 505 error.
Then, I disabled the Yoast SEO plugin, removed it. Installed All In One SEO plugin.