Http error 500 after deploying a slim3 app

So I got my app fully working on local server, but when I upload it to a server, I am getting a http error 500. Thing is I can’t access the command line tool so i had to upload the whole vendors folder. Could this be the possible source of my problem. I tested every step the app makes on production and it works until returning the response return $this->view->render($response, 'auth/login.twig');. I am lost and I already wasted a lot of time searching for the fix so I am asking if someone maybe encountered such a problem and succeeded upon fixing it. Thanks in advance.

If you are getting a 500 code error, look in your server’s error log as it will provide more details about the error.

Dumb mistake, but the server was using php in version 5.6.30, and extension Twig-View requires php in version 7. Thanks to SVL for letting me know.

FYI, Twig-View does not require PHP 7, it will accept >=5.5.0. Twig View requires Twig. Twig’s version 1.x requires PHP >=5.3.3 and Twig version 2.x requires PHP ^7.0.

So in your case, the thing to do would be to add a config platform entry to your composer.json file locally. In there you would specify the PHP version you are building against so that you will get components installed automatically that match your server.

    "config": {
        "platform": {
            "php": "5.6.30"
        }
    }

Oh, thanks for info :slight_smile: Will test it aswell.