0

I recently updated my Magento to 1.9.3.8.

Now, I have a HTTP ERROR 500 in a specific case.

I got an error when the following three conditions are met:

  1. URL : base_url/checkout/cart OR base_url/checkout/onepage
  2. Compiler state is enabled
  3. User is logged

I have nothing into Magento log (system.log or exception.log). Nothing else into server logs (/var/log/httpd/error_log) or (mysite/logs/error_log).

My observations

After some deep research in the magento code, I think the error is in includes / src / __ checkout.php.

I can solve it with a bad trick. Update lib/Varien/autoload.php at line 105

static public function registerScope($code)
    {
        if($code != "checkout")
        {
            self::$_scope = $code;
            if (defined('COMPILER_INCLUDE_PATH')) {
                @include_once COMPILER_INCLUDE_PATH . DIRECTORY_SEPARATOR . self::SCOPE_FILE_PREFIX.$code.'.php';
            }
        }
        else
        {
            //DO NOTHING
        }
    }

Someone else has the same error ? Or a real solution ?

I found nothing about this error and I don't understand why I have it. I never modify Magento core checkout files.

If this question is reporting to an already open subject, my apologize, I didn't find it.

  • if its 500 error, then you can check it in server error.log file. The issue will be there. – Shyam Krishna Sreekumar Mar 13 '18 at 9:55
  • it can also be due to permission error. – Shyam Krishna Sreekumar Mar 13 '18 at 9:57
  • @ShyamKrishnaSreekumar About Log : I already check file and there are nothing about errors. When I clean the logs, reload page, the log is still empty. I follow instructions from stackoverflow.com/questions/4731364/…. But still empty. About permission : I migrate all my website to my development server, I update permission of all files to 777. And still have the same error. – hemir Mar 13 '18 at 10:13
  • @hemir can you disable Compiler state ! and try – Sam Mar 13 '18 at 11:12
  • @Sam like I answered to your answer, I know without compiler, it works but that was not the subject of my question. I will keep my compiler enable to improve performance. I have this bug when the three conditions are met and compiler enable is one of them. – hemir Mar 13 '18 at 12:34
0

I'm getting the same issue following an update to 1.9.4.0 from 1.9.3.4

As you've reported there are no related errors messages being reported in either magento logs or server error logs.

Did you ever find a solution to this other than the obvious step of turning off the compiler?

(Your suggested code mod works insofar as it ignores compiled files for checkout pages. But as you said - you've already established that the error occurs when the compiler is activated. So it's just a workaround really that depends on modifying core code - and as you suggest - therefore not a great long term solution.)

  • Sorry to be so late but I have not found a better solution. Since my last update, I have not investigated – hemir Apr 24 at 8:30
0

Not a final solution, but still.

Copy Autoload.php file from lib/Varien/Autoload.php to the app/code/local/Varien/Autoload.php

And add your changes to this file.
I.e.: replace registerScope function with this code:

static public function registerScope($code)
{
    if($code != "checkout")
    {
        self::$_scope = $code;
        if (defined('COMPILER_INCLUDE_PATH')) {
            @include_once COMPILER_INCLUDE_PATH . DIRECTORY_SEPARATOR . self::SCOPE_FILE_PREFIX.$code.'.php';
        }
    }
    else
    {
        //DO NOTHING
    }
}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.