Forum Replies Created

Viewing 7 replies - 1 through 7 (of 7 total)
  • Thread Starter a.c

    (@ac-1)

    Hi @kushnamdev,

    Just wanted to check on the status of this issue. Is there a fix planned for the next plugin release or perhaps a work-around I can implement on my end?

    Is there any additional information I can provide to assist?

    Thank you,
    -AC

    Thread Starter a.c

    (@ac-1)

    Hi @kushnamdev,

    Yes, I am using Super Page Cache version 5.0.9.

    Thank you,
    -AC

    • This reply was modified 1 year, 3 months ago by a.c.

    Glad it’s working, @zachwtx — all credit goes to @explorador20 for the workaround. As others have mentioned, it’s worth noting the 502 issue is intermittent and occurring on WPE and PHP 7.2 specifically.

    Production Update:
    I deployed the @explorador20 workaround on my production install running PHP 7.2 / WP 5.0.3 / AI1EC 2.5.36 and everything *seems* to be working as expected.

    Hi @great-taste

    Note: below instructions assume plugin version 2.5.36, WP Engine PHP 7.2

    1. Login to wp-admin of respective site
    2. In /lib/bootstrap/loader.php below line 124 $cache_file = $this->_get_cache_file_path( $path ); on a new line, add $cache_file = str_replace('.php', '.tmp', $cache_file);

    Lines 124 and 125 respectively:

    
    $cache_file = $this->_get_cache_file_path( $path );
    $cache_file = str_replace('.php', '.tmp', $cache_file);
    

    3. In /lib/bootstrap/loader.php replace line 153 $cached = ( require $cache_file ); with $cached = eval( str_replace( '<?php ', '', file_get_contents( $cache_file ) ) );
    4. In wp-admin, refresh the page. An error message should appear at the top of the screen: Generated class map is invalid: false. Please delete lib/bootstrap/loader-map.php (if it exists), make sure lib/bootstrap/ is writable by the web server, and enable debug mode by setting AI1EC_DEBUG to true (then back to false when done).
    5. Delete lib/bootstrap/loader-map.php if it exists
    6. Enable debug mode: Open wp-config.php and add define('AI1EC_DEBUG', true); somewhere above if ( !defined('ABSPATH') ).
    7. In wp-admin, click the Try to Reactivate button in the error message.
    8. After the page refreshes, verify that lib/bootstrap/loader-map.tmp was created. Optionally verify it has correct permissions of 664
    9. In wp-config.php, change define('AI1EC_DEBUG', true); to define('AI1EC_DEBUG', false); or simply delete the line of code.
    10. The issue should be resolved. Note you will have to repeat the above steps if another plugin update is released and installed without implementing this fix in some capacity.

    Best,
    -A

    @great-taste

    You are correct, the loader.php file is located in the /lib/bootstrap/ directory. You can confirm by following the interim fix instructions.

    @explorador20

    Thanks for this fix.

    Did your loader-map.php file ever have permissions of 600?

    I’m curious if WP Engine implemented a fix on their end addressing the permissions issue for generated .php files: I have the plugin installed on 5 different WP Engine + WP 5.0.3 + PHP 7.2 sites and the permissions for loader-map.php are all 664. The plugin is now currently working as expected without implementing the fix (the plugin was previously causing 502s).

    Thanks,
    -A

    Hello,

    I am still experiencing the 502 error on WP Engine.

    Plugin Version 2.5.36, PHP 7.2, WP 5.0.2.

    My WP Engine support tech investigated on his end and concluded that the issue is related to the plugin causing “server-side segmentation faults”, but wasn’t able to provide additional information. The tech noted that the 502 error has been popping up with this plugin as well as other plugins.

    He tried increasing the install’s memory limit to 2GB, but it did not resolve the issue either.

Viewing 7 replies - 1 through 7 (of 7 total)