NicolaPez
NicolaPez

Reputation: 587

Symfony 3.4 bug php json during install

During symfony install with

symfony new my_project 3.4

I have this error:

PHP Notice: Use of undefined constant JSON_ERROR_DEPTH - assumed 'JSON_ERROR_DEPTH' in phar:///usr/local/bin/symfony/vendor/guzzlehttp/guzzle/src/Utils.php on line 140 PHP Notice: Use of undefined constant JSON_ERROR_STATE_MISMATCH - assumed 'JSON_ERROR_STATE_MISMATCH' in phar:///usr/local/bin/symfony/vendor/guzzlehttp/guzzle/src/Utils.php on line 140 PHP Notice: Use of undefined constant JSON_ERROR_CTRL_CHAR - assumed 'JSON_ERROR_CTRL_CHAR' in phar:///usr/local/bin/symfony/vendor/guzzlehttp/guzzle/src/Utils.php on line 140 PHP Notice: Use of undefined constant JSON_ERROR_SYNTAX - assumed 'JSON_ERROR_SYNTAX' in phar:///usr/local/bin/symfony/vendor/guzzlehttp/guzzle/src/Utils.php on line 140 PHP Notice: Use of undefined constant JSON_ERROR_UTF8 - assumed 'JSON_ERROR_UTF8' in phar:///usr/local/bin/symfony/vendor/guzzlehttp/guzzle/src/Utils.php on line 140 PHP Fatal error: Call to undefined function json_decode() in phar:///usr/local/bin/symfony/vendor/guzzlehttp/guzzle/src/Utils.php on line 142

My PHP is:

PHP 5.6.30-10+deb.sury.org~trusty+2 (cli) Copyright (c) 1997-2016 The PHP Group Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies

Do you know how to help me?

Upvotes: 1

Views: 149

Answers (1)

fgamess
fgamess

Reputation: 1324

Try php -m in a terminal to see if php5.6-json is correctly loaded

Then php --ri json | grep version if you want to check the module version

Upvotes: 0

Related Questions