Forum Replies Created

Viewing 15 replies - 1 through 15 (of 32 total)
  • Plugin Contributor Alain Schlesser

    (@schlessera)

    You seem to have a plugin or theme installed that adds HTML markup in a bad way.

    This results in the following tag being echoed to the browser outside of the normal page rendering:

    <i id="revolver-icon" class="dashicons dashicons-menu sidebar-rev alignleft"></i>

    You’ll need to find out where that icon is being added and change the way that happens.

    Plugin Contributor Alain Schlesser

    (@schlessera)

    This is most likely caused by a theme or plugin calling some of the AMP functions too early.

    There is a PR here that fixes this problem: https://github.com/ampproject/amp-wp/pull/6181

    You can test that fix by installing this version of the plugin as a temporary workaround until v2.1.1 was released: https://storage.googleapis.com/ampwp_github_artifacts/refs/pull/6181/merge/prod/amp.zip

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @aaron13223 The query itself seems to run as fast as expected on its own (0.001 sec on your MariaDB screenshot), and the EXPLAIN does not show any immediate issues as far as I can see.

    However, on your QueryMonitor screenshot, I can see that the query runs through an extra DBCache (probably via W3TotalCache?). Have you tried disabling that DBCache to see whether that fixes the issue?

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @aaron13223,

    You should be able to remove the filter without modifying the plugin via the following remove_filter call:

    remove_filter( 'dashboard_glance_items', [ 'AMP_Validated_URL_Post_Type', 'filter_dashboard_glance_items' ] );

    However, I’d like to look into what is causing the slow SQL execution in this case, so I’d also be grateful for any additional information you could provide:

    – How long does the query actually take to execute in your case?
    – Are you able to run SQL queries directly against the database, for example via WP-CLI’s db query command?
    If yes, can you run the above query by pretending the EXPLAIN keyword? This will gives us details about how the database server goes about resolving this query.
    As an example, here’s what it does on my machine: https://share.getcloudapp.com/8LuPo5yp

    Seeing this would be hugely helpful, because I suspect there might be an indexing issue on your server.

    Thanks for helping us get to the bottom of this!

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @collins1980 Release v1.5.2 is currently planned for today 10am PDT, provided no unexpected surprises come up in the mean time.

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @janvitos I’m sorry, the command should have been the following:

    
    AMP_Options_Manager::update_option( 'amp_css_transient_monitor_disable_caching', true );
    

    Once you’ve tried this and could confirm the change on the Site Health page, please observe the latency. If the performance didn’t improve, please roll back to v1.4.4 for now. I’ll see if I can contact you to schedule a call tomorrow then.

    Note: We’re working on a fix that should be pushed soon as v1.5.2, but that assumes we’ve correctly identified the issue, which is not fully confirmed yet.

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @janvitos Thanks for all the additional information, that really helps get a better picture of the issue.

    From the Site Health debug information, I can see the following:

    amp_css_transient_caching_disabled: true
    amp_css_transient_caching_threshold: 50 transients per day
    amp_css_transient_caching_sampling_range: 14 days
    amp_css_transient_caching_transient_count: 172

    With the new plugin release, we added a mechanism to detect when the CSS stylesheet cache we have is too volatile, to avoid filling up users’ database with thousands of transients when they don’t serve any use. This can happen when the CSS contains randomized or generated data, so that each new request has slightly different CSS than the one before.

    In the above debug log, amp_css_transient_caching_disabled is true, meaning that this detection was actually triggered on your site, and that hence the CSS stylesheet caching was disabled.

    The added latency for your site with this version could come from the fact that this caching is disabled and all stylesheets have to be reparsed on every single page request.

    However, as we don’t yet have much real-world data about what values to expect, it could well be that our threshold is too low right now.

    I would be very grateful if you could try the following to get some confirmation.

    Can you please set the threshold to a high value for now, by adding the following code to a plugin or your theme’s functions.php file:

    
    add_filter( 'amp_css_transient_monitoring_threshold', 1000 );
    

    And then reset the disabling of the CSS stylesheet cache by running the following code once:

    
    AMP_Options_Manager::update_option( Option::DISABLE_CSS_TRANSIENT_CACHING, true );
    

    You can do this for example with WP-CLI’s wp shell command, or by pasting it into a plugin or your theme’s functions.php file and removing it again.

    After this, when you go back to the Tools -> Site Health screen, the Info page should display these changes at the bottom, with amp_css_transient_caching_disabled showing false and amp_css_transient_caching_threshold showing 1000 transients per day.

    Please let me know if you don’t know where to do the above, and I’ll prepare a separate plugin to install instead.

    Thank you very much!

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @janvitos I’d like to investigate this further and would love to have more details about your site.

    If you can, please provide the URL to an example page that is affected, details about your server environment and anything else that could help us detect a possible cause for the slowdown.

    For the server environment information, the easiest way is to go to Tools / Site Health in your admin backend, and copy the information from the “Info” screen. There should be a “Copy site information to clipboard” button on that page.

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @macken Version 1.5.1 should fix your issue. Please update the plugin to that version and confirm whether the issue is fixed for you or not.

    (It would still be a good idea to nag your hosting provider about the libxml version, though)

    Thank you!

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @kishanunjia Version 1.5.1 should fix your issue. Please update the plugin to that version and confirm whether the issue is fixed for you or not.

    In case you added the 'amp_enable_ssr ' filter I mentioned above, remember to remove it again to re-enable the serverside rendering optimization.

    Thank you!

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @kishanunjia I suspect that this is caused by the use of the amp_post_template_metadata filter.

    Can you please check whether and how you are using this filter?

    Forum: Plugins
    In reply to: [AMP] Error images
    Plugin Contributor Alain Schlesser

    (@schlessera)

    @escael Where did you see the above error? Was that in the AMP validator?

    I would love to get more contextual information to see if this is a bug we need to fix.

    Plugin Contributor Alain Schlesser

    (@schlessera)

    Your libxml version is indeed too low, and it is lower than what it should be for the PHP version you’re running.

    I’ll look into whether I can get around the requirement for the libxml version we need.

    In the mean-time, I would recommend talking to your hosting provider to find out whether they can update the version of libxml that is being used by PHP. This would not only fix the error above, but also generally improve DOM handling for your PHP version and make it more secure.

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @kishanu
    SSR should be on by default on AMP pages. To verify, take a look at the page source of an AMP page, and you should see the transformed="self;v=1" attribute on the <html> element.

    ( screenshot: https://share.getcloudapp.com/nOuNyywl )

    Plugin Contributor Alain Schlesser

    (@schlessera)

    @kishanunjia There seems to be an error with the new serverside rendering component of version 1.5.0.

    To help us debug, I would be grateful if you could send me the current contents of the transients in your wp_options table that start with _transient_amp_remote_request_. There should be 2 of them.

    As a quick work-around, you can disable serverside rendering by adding the following filter in a plugin or your theme:

    add_filter( 'amp_enable_ssr', __return_false );

Viewing 15 replies - 1 through 15 (of 32 total)