-
Notifications
You must be signed in to change notification settings - Fork 384
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not enough information given when fetch_external_stylesheet failure happened #2449
Comments
And i dont think we should save Error on |
@pentatonicfunk Thanks for the report. This actually was revisited a week ago in this commit fd23dc0 as part of #2357: amp-wp/includes/sanitizers/class-amp-style-sanitizer.php Lines 1226 to 1255 in ce430d5
This change didn't make it into the Could you test that and review? A couple things that are missing based on your feedback is:
|
I fixed this in #4257, other than the reduction in the of the expiration time. |
And #4293 captures the improvement to reduce the expiration time for cached errors. |
Version : 1.1.1
When fetching external stylesheet failure that indicated by
WP_Error
onwp_remote_get
, there is nocode
andmessage
displayed on Validations Page.Example case : when Invalid SSL being used on external stylesheet url.
This is caused by
wp_remote_retrieve_response_code
andwp_remote_retrieve_response_message
are emptyhttps://github.com/ampproject/amp-wp/blob/1.1.1/includes/sanitizers/class-amp-style-sanitizer.php#L1111
Possible Solution : Add WP_Error handler after
wp_remote_get
to catch code and message, that will be usable on later stageThe text was updated successfully, but these errors were encountered: